Home » SQL & PL/SQL » SQL & PL/SQL » Polling table for new data
Polling table for new data [message #214728] Wed, 17 January 2007 15:59 Go to next message
Messages: 3
Registered: January 2007
Location: Netherlands
Junior Member
Hi everybody

Does anyone know how i can poll a table for new data (since the last poll) using the DBMS_SCHEDULER package? I know this package allows me to execute a procedure periodically, but i still dont know how i can indentify new records in the table and process them one by one. I added a timestamp field to the table so i can compare it to the timestamp of the last poll. I thought of declaring a cursor based on the following select statement:

select ...
from table
where timestamp_field > last_poll_timestamp

But i dont know if i can reference this last_poll_timestamp from the procedure i want to execute as a job.

Could someone please help me with this. My grade depends on it!!!!


Kim (the flying dutchman)

Re: Polling table for new data [message #214742 is a reply to message #214728] Wed, 17 January 2007 19:37 Go to previous message
Messages: 3727
Registered: October 2005
Location: Melbourne, Australia
Senior Member
Don't know whether there is an easier way, but you could probably pick it out of the DBA_JOBS view.

A completely different solution - search for Change Data Capture in the Oracle manuals.

Ross Leishman
Previous Topic: Getting Consecutive Numbers
Next Topic: PL-SQL Trigger ..... Help needed
Goto Forum:

Current Time: Thu Aug 17 12:24:13 CDT 2017

Total time taken to generate the page: 0.14879 seconds