I got the following error while testing some code:
SQLException: Invalid column index
What exactly does that mean?
Is there an online document explaining what all the Oracle error codes and statements?
Advertisement
Answer
If that’s a SQLException thrown by Java, it’s most likely because you are trying to get or set a value from a ResultSet, but the index you are using isn’t within the range.
For example, you might be trying to get the column at index 3 from the result set, but you only have two columns being returned from the SQL query.