JDBC-ODBC Bridge and SQLSvr7
1 posts in topic
Flat View  Flat View
TOPIC ACTIONS:
 

Posted By:   Cord_Awtry
Posted On:   Monday, February 25, 2002 05:38 PM

Question... I have a SQLSvr7 DB I'm trying to access using the JDBC-ODBC bridge. The table I'm accessing has a set of columns or varying types, but the issues resolves around a pair of them. Two of the columns are varchar(128)... the first populated with the data, the second all NULL. When I access the data, it works beautifully getting the 1st column, but then when I call getString() for the 2nd column, I get: java.sql.SQLException: [Microsoft][ODBC SQL Server Driver]Invalid Descriptor Index Anyone have any ideas? Better yet, can anyone suggest a better JDBC driver that won't cost me an arm an a leg? I'm doing a small web project and can't justify paying large sums for a good driver. I'm running the developer edi   More>>

Question...
I have a SQLSvr7 DB I'm trying to access using the JDBC-ODBC bridge. The table I'm accessing has a set of columns or varying types, but the issues resolves around a pair of them.

Two of the columns are varchar(128)... the first populated with the data, the second all NULL. When I access the data, it works beautifully getting the 1st column, but then when I call getString() for the 2nd column, I get:

java.sql.SQLException: [Microsoft][ODBC SQL Server Driver]Invalid Descriptor Index


Anyone have any ideas? Better yet, can anyone suggest a better JDBC driver that won't cost me an arm an a leg? I'm doing a small web project and can't justify paying large sums for a good driver. I'm running the developer edition of JRun right now which has a driver, but seems to be limited to one connection at a time.

Thanks in advance...


Cord Awtry

   <<Less

Re: JDBC-ODBC Bridge and SQLSvr7

Posted By:   zaichao_Gui  
Posted On:   Monday, February 25, 2002 11:35 PM


//ok:
String s1 = rs.getString(1);
String s2 = rs.getString(2);
//error:
String s2 = rs.getString(2);
String s1 = rs.getString(1);
About | Sitemap | Contact