Skip to Main Content

Java Database Connectivity (JDBC)

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

JDBC ORA-17006 JDeveloper

843854Apr 8 2003 — edited Apr 10 2003
I have a query like:
rset = st.executeQuery(select emp_id, emp_no, emp_name, location ...");

I then have parse a resultset like so:

String foo = rset.getString(1);
String boo = rset.getString("emp_no");

I can obtain a value with the first string (foo), when I getString with an integer, but when I call getString with a "string" (like boo) it fails and gives me ORA-17006 Invalid Column Name.

However when I run the SQL in an editor, it runs fine and returns results.

Running JDK 1.3, Oracle 8.1 and using JDeveloper 9.3 & OC4J.

I can run this in JBuilder 6 with out any errors.

Anyone have any tips?
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on May 8 2003
Added on Apr 8 2003
14 comments
2,395 views