What's the best way to monitor a table from a java bean? Is it possible to detect new entries into the table dynamically without polling (re-querying) the table at timed intervals?
Three answers:
?
2008-06-04 07:16:50 UTC
It is not possible to detect new entries in a table without polling. If you do not want to touch the table (query the table), you can create another table with a single column.
Write a trigger for the "after insert" event of first table and set the flag.
Through the program you query the second table and reset the flag.
According to the flag, you can know whether new entries are added or not.
Hope this helps.
2008-06-04 07:17:22 UTC
Even I got this type of problem in my java Swing Application ................... & I got a solution through action listener I just added action listener to every section of row & column in table (eg. Like in excel section A , section B….) so that when ever client or user enter some data through form section or table……….. Action listener reads up content if statement is true he add data into the table…
I hope using this your problem will be solve :) bye
2014-12-11 00:16:37 UTC
challenging aspect. research with search engines like google. that may help!
ⓘ
This content was originally posted on Y! Answers, a Q&A website that shut down in 2021.