Subject Re: [Firebird-Java] Firebird 3 migration issue with Statement.RETURN_GENERATED_KEYS
Author Felipe Jaekel
Thanks for the quick and detailed feedback.

I actually don't use the semi-collon at the end of the statements, in this case it was an attempt to see if it would make any difference.

I'm glad that the problem is solved and I would like to test the snapshot.

Em sex, 30 de nov de 2018 às 12:43, Mark Rotteveel mark@... [Firebird-Java] <Firebird-Java@yahoogroups.com> escreveu:
 

On 30-11-2018 15:17, Mark Rotteveel mark@... [Firebird-Java]
wrote:
> I have managed to reproduce the problem, it seems to be a bug in Jaybird
> 3. For some reason the returning clause is not correctly detected by the
> grammar, leading Jaybird to unconditionally add the RETURNING
> <column-list> itself. Given it is now possible to alias columns in the
> RETURNING list, the Firebird parser only chokes when it gets to the
> first column in that list (yielding token unknown "ID" instead of token
> unknown RETURNING).

Interestingly, Jaybird 2.2 has the same error in the grammar, but
apparently the differences between ANTLR 3.4 and 4.7 cause ANTLR 3.4 to
make a best effort and still correctly identify the returning clause.

In any case, this will be fixed in Jaybird 3.0.6:
http://tracker.firebirdsql.org/browse/JDBC-566

Let me know if you want to have a snapshot version to test the fix.

Mark
--
Mark Rotteveel