Win a copy of The Little Book of Impediments (e-book only) this week in the Agile and Other Processes forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

ODBC configuration.help

 
henry akoma
Greenhorn
Posts: 21
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi,
i have tried configuring my ODBC, but bcos their are so many option(user DSN, System DSN, File DSN, etc) and so many things in the ADD button, i am really confused as per which to use and each time i try any option my program gives an error.

i dont know if this is the best forum for me to ask for a step by step ODBC configuration assistance, but i will appreciate it if someone helps me out. i just want to write a simple transaction program and i have been on it for too long.

i already have used the code
but another problem i have is where to specify as my url
does the program create the data source for me or do i create it by another means .

please i need help in this area.
thanks for your cooperation
[ September 22, 2005: Message edited by: Bear Bibeault ]
 
Dave Salter
Ranch Hand
Posts: 293
Java Mac OS X Netbeans IDE
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You are better off creating a system dsn. That is accessible by all users and all applications on your system. Create this in the ODBCAdmin app in the control panel and call it something like "MyDSN".

Your URL to access it will then by jdbc dbc:MyDSN

You have to get a connection to the database by doing something like:

Connection connection = DriverManager.getConnection(url);
 
Tom Blough
Ranch Hand
Posts: 263
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Henry,

What database are you using? With that information we can give much more specific instructions.

Cheers,
 
henry akoma
Greenhorn
Posts: 21
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
thanks for your contribution.

i am actually new to database technology, so i dont know if i can be specific about the database i am using but i will try to paint a good scenario of what i am doing.

i have written a program using the oracle sotware(sql).i have saved it as C:\sql\coffees.sql. i now want to use java to both retrieve data and modify data in that file.

another huddle i need to cross now is to determine which driver to choose from in the ADD button of the System DSN window.

is this infomation enough, if not i am ready to answer any questions. thanks.
 
henry akoma
Greenhorn
Posts: 21
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hey guys, thank you so much, i have finally gotten a good run of the program.
i appreciate your contributions
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic