I have a procedure in PLSQL that picks 5000 records from a table and inserts in another table.
The JMS queue then picks the data from the queue and processes them. When the queue is empty, I run the procedure again to pick another 5000 records.
Is there a way in plsql to automate this? Whenever the count of the queue table is 0, it executes the procedure again.