Limiting returned record from SQL query in Oracle -


To check an Oracle DB table for checking every X second, one of the apps I care about to see if any new data is to be processed (1)

other real time app is popular).

Our new customer business process forces this table to populate this table with a lot of records at the same time (say at 10 000), but only a few times in a day. Next time my app checks if there is anything to take action on it, which faces 10 000 records and tries to take action on it

It is not very well engineered And it's not enough enough yet. The next time it will pick up the other 50 (or whatever) etc., the number of quick fixes will be limited to the number of records from Oracle.

How can I restrict the number of records recorded in Oracle SQL? Order matters!

  In order from select_dts, where date and gt; By order of = to_date ('20001010000', 'YYYYMMDDhh24mi'));  

 select  from (select c. * Cool_table to c * date and Gt; = To_date ('200901010000', 'YYYMMD DHH 24MB') Order by seq_nr, entry_data) where rownum & lt; 50  

You need to make sure that order is done before filing Ronam (otherwise it will first get 50 rows, then order them)


Comments