Monday, February 16, 2009

Using Toad with Oracle Instantclient 10.2.0.4.

1. Install the Oracle instant client from here. Make sure you download version 10.2.0.4 and not any of the 11.x.x.x versions, they didn't work with my version of Toad. (9.1)

2. Extract the zip somewhere. Say C:\instantclient

3. Add this directory to the PATH environmental variable. To do this, right click on My Computer, go to the Advanced tab, and click 'Environment Variables'. Under System variables, find Path. Select it, and click edit, and add to the end. (Example: %SystemRoot%\system32;%SystemRoot%;%SystemRoot%\System32\Wbem;C:\instantclient)

4. In the same window, under 'User variables for …', Click the New button. Call the variable 'TNS_ADMIN' and point to your instant client directory. (C:\instantclient)

5. Create a file called 'TNSNAMES.ORA' in your instant client installation directory. In this file designate the connection parameters for your database. Mine looked something like this:

BYMS_DEV =
(DESCRIPTION =
(ADDRESS = (PROTOCOL = TCP)(HOST = 10.0.0.11)(PORT = 1526))
(CONNECT_DATA =
(SERVER = DEDICATED)
(SID = DEV)
)
)

6. You can also create a sqlnet.ora file but its not neccesary.

7. Restart your computer and fire up toad.


You can use other clients like Oracle Sqldeveloper as well.

--
Done on Windows XP & Toad 9.1

Sunday, February 15, 2009

Windows not Windows?

If this isn't enough to make you ditch Vista I don't know what is.. Lets hope Windows 7 is a least "Windows".. ;-)

A typical Vista error:


Monday, January 5, 2009

Install & Use Oracle SQL Developer 1.5.x on a Mac
To install Oracle SQL Developer on a Mac is as easy as installing any application on a Mac. Just unzip the downloaded archive (download it from here), and drag the file to your applications folder. SQL Developer is a great SQL tool for the mac, but there are quite a few things I didn't like with its default settings, so here's what I changed:

1. Line Terminator – If you work like me in a Windows dominant office, you'll be sure to change your line terminator from “Platform Default” to “Windows”. This will insure that your newline caracters you add also show up on a Windows, Linux and Mac computer so you can't go wrong with that setting.

2. Fontsize – On my Macbook pro 15” the fontsize is way too small for me. To do this go to Tools -> Preferences -> Code Editor -> Fonts. I changed mine from the default 12 to 15 on Monospaced.




3. Colors – Coming from Toad, the default SQL Developer text color's are downright ugly. I liked the Toad color scheme, so I changed mine to the same colors. To do this go to Tools -> Preferences -> Code Editor -> Syntax Colors. Change the following colors:
  • Default Keyword –> Blue. Also turn off Bold.
  • Default Comment –> Green.
  • Default String –> Red.
  • Default Number –> Dark red.
  • Selected Text – Foreground -> Black. Background –> Light Grey.
You can even save your new scheme as “Toad” ;-) Your colors will then go from this first image to the second one.. :-)


Another few changes I have made is to the accelerators.You can find them under Tools -> Preferences ->Accelerators.
1. Popup Describe – I made this F4. (The same as Toad)
2. Execute Statement – I made mine Cmd+Enter and CTRL+Enter.
Done!