• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Dynamically create ODBC source

 
Chad Clites
Ranch Hand
Posts: 134
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I am having difficulty finding the right Google query, so hopefully someone can steer me in the right direction. I am using a database to populate an excel file. Using JDBC:ODBC I am able to read and write from the excel file (and boy did it feel good to get that figured out), I can also create a workbook of n size from a single worksheet(almost as satisfying).

The workbook is built from a relatively simple form, with each subsequent page being a copy of the form, with different information. I can create an ODBC source from the original worksheet using the Administrative Tools in Windows which is fine if my workbook only ends up with one sheet. But if I end up with another sheet, I need to be able to declare that as an ODBC source on the fly. So I think what I am looking for is "create dynamic ODBC source", but that doesn't seem to be returning anything helpful.

Or do I need to just create a default workbook as an ODBC source, add as many sheets to it as will be needed, and then just access each sheet?
 
Paul Clapham
Sheriff
Posts: 21554
33
Eclipse IDE Firefox Browser MySQL Database
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I tried "java odbc without dsn" and this was the first link that Google gave me.

Later: actually reading that link I notice the comment about the code being broken. I suspect it would work better with backslashes instead of slashes separating directory names in that Windows path.
[ July 26, 2006: Message edited by: Paul Clapham ]
 
Chad Clites
Ranch Hand
Posts: 134
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thank you. That worked just fine, as-is and with backslashes both.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic