views:

6

answers:

1

i have oracle 10g express edition installed and i want to know how to create a system dsn for it.so that i can connect database to my java programs

A: 

We've found that JDBC (more info) is the best way to connect to an Oracle database from Java, but if you prefer to use ODBC, these instructions from the Oracle website should get you there.

  1. Click Start > Programs > Administrative Tools > Data Sources (ODBC) to open the ODBC Data Source Administrator.
  2. Click the System DSN tab and click Add. The Create New Data Source dialog box opens.
  3. In the Create New Data Source dialog box, select the Oracle driver.
  4. Click Finish to open the Oracle ODBC Driver Configuration dialog box.
  5. In the Oracle ODBC Driver Configuration dialog box, enter a Data Source Name (this can be any name), select the appropriate TNS Service Name from the drop down list, and enter the User ID for the schema.
  6. Click Test Connection to open the Oracle ODBC Driver Connect dialog box.
  7. In the Oracle ODBC Driver Connect dialog box, enter the password for the schema and click OK.
  8. You should see a "Testing Connection" message indicating the connection is successful.
  9. Click OK to close the Testing Connection message.
  10. Click OK to close the Oracle ODBC Driver Configuration dialog box.
  11. Verify that the system data source is added in the ODBC Data Source Administrator and click OK to close the ODBC Data Source Administrator.

If you go to the original link, they have screenshots too, but also a lot more information since they are part of the setup of a different product.

Colin Pickard