Question

Do you know if there is a way to use a data listener on a select query with jaybird.

For example I've got a query like

select count (*) from my_table where my_statut='x'

the result give me 50.

My application change the field my_statut to 'y' for one row, is there a way to catch the new result with a value/data... change listener in java?

Thanks for your help.

Simon

Was it helpful?

Solution

It is possible via trigger and event api. Take a look CHAPTER 8 of this manual http://www.firebirdsql.org/file/documentation/drivers_documentation/Jaybird_2_1_JDBC_driver_manual.pdf

OTHER TIPS

No, this is not possible. Once a resultset is created by a query it is fixed and will not change (except for changes made by the program itself to a CONCUR_UPDATABLE resultset), also - depending on the exact transaction configuration - you can't see any changes made in other transactions.

If your application needs to be aware of changes, you could look into the events mechanism provided by Firebird and Jaybird.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top