Monday, November 29, 2010

jQuery Mobile | jQuery Mobile

jQuery Mobile | jQuery Mobile

Friday, November 19, 2010

Reset Mysql Root Password, windows

start at command prompt

net stop mysql

mysqladmin --skip-grant-tables

mysql -u root


mysql> use mysql;
mysql> UPDATE user SET Password = PASSWORD ('isi_password_baru') WHERE User='root';
mysql> FLUSH PRIVILEGES; 
mysql> quit;

net start mysql

Saturday, November 13, 2010

ORACLE FASTER NOT IN QUERY

Alternate to not in query
select table1.field1 from table1 where table1.field1 not in
(select table2.field1 from table2);
1st Rank using outer join:
SELECT table1.field1
FROM table1, table2
WHERE table1.field1 = table2.field1(+) and
table1.field1 is null;
2nd Rank using not exists:
SELECT table1.field1
FROM table1
WHERE NOT EXISTS (SELECT table2.field1 FROM table2 WHERE table1.field1 = table2.field1)
Enhanced by Zemanta

Friday, August 27, 2010

Oracle Makes Commitments to Customers, Developers and Users of MySQL

Oracle Makes Commitments to Customers, Developers and Users of MySQL

Thursday, August 12, 2010

Change database mode to archive mode

SQL> shutdown immediate
SQL> startup mount
SQL> alter database archivelog;
SQL> alter database open;

Friday, July 30, 2010

ORA-00314: log 4 of thread 1, expected sequence# doesn't match ORA-00312: online log 4 thread 1: '\REDO04.LOG'

SQL>STARTUP MOUNT; 
SQL>RECOVER DATABASE UNTIL CANCEL;
SQL>ALTER DATABASE OPEN RESETLOGS;
SQL>SHUTDOWN;  
SQL>STARTUP; 

ORA-00214: controlfile inconsistent

From: "Milla G" <[Email Address Removed]
Subject: Re: ora-00214(urgent)
Date: Wed, 29 Jan 2003 08:00:38 +0000

1. If the database is still up, do a shutdown abort now.

2. Edit the init.ora file for this instance (or config.ora in an ifile
configuration).

Find the CONTROL_FILES parameter and modify it to include
just ONE copy of the control file that you have reasons to
believe is up-to-date. For example, if you only have two
mirrored copies X and Y of the control file:

CONTROL_FILES = (X, Y)

and you know you have accidentally overwritten X with an old
copy, make

CONTROL_FILES = (Y)

If you are not sure about it, choose any one of the control file
copies and remove or comment out all the other copies from the
CONTROL_FILES parameter.

3. Start up the database in restricted mode.

STARTUP RESTRICT

If the database comes up fine, move on to Step 4.

If instead you get ORA-1122, ORA-1110, and ORA-1207, go back to
Step 2 and make the CONTROL_FILES parameter point to another one
of the mirrored copies. If you have already tried each and
every one of the mirrored copies unsuccessfully, you must create
a new control file for the database. See the Solution Reference
to PR entry 1012929.6 ("How to Recreate the Control File").

If you get ORA-1113 and ORA-1110 pointing to one of the datafiles,
it means the copy of the control file you picked is good, but
the referenced datafile must be recovered before the database can be
opened. Try issuing a RECOVER DATABASE command and applying the
logs you are prompted for. You may have to resort to the online
logs to complete media recovery. For further details, see the
Solution Reference to PR entry 1012943.6 on ORA-1113. Once the
datafile is recovered, issue an ALTER DATABASE OPEN.

4. Shut the database down (normal or immediate).

5. Make all copies of the control file consistent.

Copy the good mirrored copy of the control file that you just used
to bring the database up onto all other copies, as originally listed
in the CONTROL_FILES parameter of your init.ora file (or config.ora
in an ifile configuration).

6. Restore the CONTROL_FILES parameter to its original value.

Edit the init.ora file for this instance (or config.ora in an ifile
configuration) to make the CONTROL_FILES parameter include
all mirrored copies of the control file again.

7. Start up the database.

Thursday, July 29, 2010

package body V$SESSION table or view not exist

select NVL(TERMINAL,'UNKNOWN) from V$SESSION where SID = 1;

you can have result from above snippet at sqlplus, but it shows error ORA-00942: table or view does not exist when you access from package body

View name : V_$SESSION
Public synonym known as : V$SESSION

Solution :
connect sys/[password]@[SID] as sysdba

GRANT SELECT ON V_$SESSION TO [username];

OR

GRANT SELECT ANY DICTIONARY TO [username];

Thursday, July 22, 2010

Fail to connect to oracle with error startup or shutdown initiating process

- Check initSID.ora files at each folder, at ORACLE_HOME/database/admin or pfile
- reconnect using sqlplus if ora-12514, check environment variable and look at lsnrctl services does service_name is correct re arrange listener.ora put global_dbname at first
- fail during startup with ora-01113 and ora-01110 from sqlplus use recover datafile 'path corrupt data'; then recover database or shutdown database and startup again
- check select status from v$instance; it should be mounted
- ORA-01109 database not open. manual way : alter database open;


Thursday, April 15, 2010

Biar Gak Lupa - Bikin Symlink

ln -s < destination > < linkname >

Sunday, April 11, 2010

Dynamic Tree Menu,jquery,dynatree,json,php

This is how i made dynamic menu, data is retrieve from oracle database generated by usermenu.php, with json as data output using standard php json_encode. Result menu data is setup relate to user login id so output will be differ depends on login id.


Output usermenu.php JSON data :

Thursday, March 11, 2010

BIAR GAK LUPA 1 - guest vmware cannot ssh from bridge network adapter

env :
host winXP
guest ubuntu hardy

Problem :
vmguest gak bisa di ssh melalui bridge network dengan host

Solved :
- port 22 konflik dengan IPv6, env yang digunakan IPv4 : disable ipv6 melalui konfigurasi sshd_config comment ListenAddress ::, activate ListenAddress 0.0.0.0

- Jika menggunakan /etc/host.allow daftarkan IP host di file tersebut

Regards,
REV


Reblog this post [with Zemanta]

Sunday, March 7, 2010

Install (Set up) Secure SSH on Ubuntu � Init

Install (Set up) Secure SSH on Ubuntu � Init

Create local repositories Ubuntu

1. create folder for deb files
example : sudo mkdir /opt/repos/debs
2. create package list using dpkg
sudo dpkg-scanpackages debs /dev/null | gzip -9c > repos/Packages.gz
3. edit apt source list
sudo vim /etc/apt/source.list
4. add line
debs file:/opt/repos ./
5. update apt-get
apt-get update

Wednesday, February 17, 2010

Shrinking Oracle Temp tablespace

Oh My Goodness! Look at the size of my temporary table space! Or... how to shrink temporary tablespaces in Oracle.

Yes I ran a query to see how big my temporary tablespace is:

ORA-01034: ORACLE not available for Oracle 10g

ORA-01034: ORACLE not available for Oracle 10g
Cause : Oracle Failed to initiate startup on windows 2003

Answer :
- Check all initiate variable is correct especially ORACLE SID
- simple restart might do
- try to clean windows event viewer from computer management
- startup manual
1. start sqlplus/nolog
2. connect system/password as sysdba
3. shutdown/startup

Monday, February 15, 2010

AvaxHome RSS: - powered by FeedBurner

AvaxHome RSS: - powered by FeedBurner

Sunday, February 14, 2010

PHP Session Variable Value Lost Internet Explorer




PHPImage via Wikipedia
Recently i met a condition in PHP where session variable value is lost, since the variable is used for storing login session id so user must login again if that value is lost, this issue only happen with Internet Explorer not with other browser.

Saturday, February 13, 2010

YouTube - President Obama Explains the Smart Grid and Economic Recovery

Wednesday, February 10, 2010

JavaScript - Cookies

JavaScript - Cookies

Part 2: Pass values and Call each others (PHP, HTML, Javascript)

Part 2: Pass values and Call each others (PHP, HTML, Javascript)

Set/Get Cookie using PHP and JavaScript

Set/Get Cookie using PHP and JavaScript

YouTube - Alanis Morissette - Uninvited

YouTube - Alanis Morissette - Uninvited

jQuery - Wikipedia, the free encyclopedia

jQuery: The Write Less, Do More, JavaScript Li...Image by Yandle via Flickr
jQuery - Wikipedia, the free encyclopedia: "jQuery is a lightweight cross-browser JavaScript library that emphasizes interaction between JavaScript and HTML. It was released in January 2006 at BarCamp NYC by John Resig. Used at about 20% of the 10,000 biggest websites, jQuery is the most popular JavaScript library in use today.[1]

Yii - Wikipedia, the free encyclopedia

The logo of Wikipedia.Image via Wikipedia
Yii - Wikipedia, the free encyclopedia: "Yii
From Wikipedia, the free encyclopedia

The Yii project started in order to fix some drawbacks of the PRADO framework (winner of the Zend PHP 5 coding contest). For example, PRADO was slow when handling complex pages, had a steep learning curve and many controls were difficult to customize, while Yii is much easier and more efficient."
Reblog this post [with Zemanta]