Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Updateable result sets dont work correctly with quoted fields [JDBC166] #210

Closed
firebird-automations opened this issue Nov 11, 2010 · 3 comments

Comments

@firebird-automations
Copy link

Submitted by: Steffen Heil (firebirdsql.org_partner.sh-solutions.de)

Assigned to: Roman Rokytskyy (rrokytskyy)

When using updateable result setis with queries that contain quoted field names, an exception is thrown:

...
Statement statement = connection.createStatement(
ResultSet.TYPE_SCROLL_INSENSITIVE, ResultSet.CONCUR_UPDATABLE );
ResultSet data = statement.executeQuery( "select id, \"SHARED\" from
some$table" );
while ( data.next() ) {
data.updateInt( 2, f(data.getInt( 2 ) ) );
data.updateRow();
}
data.close();
statement.close();
...

Results in:

Exception in thread "main" org.firebirdsql.jdbc.FBSQLException: GDS
Exception. 335544569. Dynamic SQL Error
SQL error code = -104
Token unknown - line 4, column 2
SHARED
at
org.firebirdsql.jdbc.FBRowUpdater.executeStatement(FBRowUpdater.java:612)
at
org.firebirdsql.jdbc.FBRowUpdater.updateRow(FBRowUpdater.java:416)
at
org.firebirdsql.jdbc.AbstractResultSet.updateRow(AbstractResultSet.java:2500
)
...
at org.firebirdsql.gds.GDSException: Dynamic SQL Error
SQL error code = -104
Token unknown - line 4, column 2
SHARED
at
org.firebirdsql.gds.impl.wire.AbstractJavaGDSImpl.readStatusVector(AbstractJ
avaGDSImpl.java:2169)
at
org.firebirdsql.gds.impl.wire.AbstractJavaGDSImpl.receiveResponse(AbstractJa
vaGDSImpl.java:2119)
at
org.firebirdsql.gds.impl.wire.AbstractJavaGDSImpl.iscDsqlPrepare(AbstractJav
aGDSImpl.java:1529)
at
org.firebirdsql.gds.impl.GDSHelper.prepareStatement(GDSHelper.java:189)
at
org.firebirdsql.jdbc.FBRowUpdater.executeStatement(FBRowUpdater.java:573)
at
org.firebirdsql.jdbc.FBRowUpdater.updateRow(FBRowUpdater.java:416)
at
org.firebirdsql.jdbc.AbstractResultSet.updateRow(AbstractResultSet.java:2500
)
...

Commits: 788336e

@firebird-automations
Copy link
Author

Modified by: Roman Rokytskyy (rrokytskyy)

Version: Jaybird 2.1.6 [ 10285 ]

Version: Jaybird 2.1.3 [ 10252 ]

Version: Jaybird 2.1.5 [ 10284 ]

Version: Jaybird 2.1.4 [ 10283 ]

Version: Jaybird 2.2 [ 10053 ]

Version: Jaybird 2.1 [ 10050 ]

Fix Version: Jaybird 2.2 [ 10053 ]

timeestimate: 0 [ 0 ]

timeoriginalestimate: 0 [ 0 ]

@firebird-automations
Copy link
Author

Modified by: Roman Rokytskyy (rrokytskyy)

status: Open [ 1 ] => Resolved [ 5 ]

resolution: Fixed [ 1 ]

@firebird-automations
Copy link
Author

Modified by: @mrotteveel

status: Resolved [ 5 ] => Closed [ 6 ]

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment