Hi, Is there delay function in Oracle? Thanks
dbms_lock.sleep
Jeff Hunter marist89@yahoo.com http://marist89.blogspot.com/ "I pledge to stop eating sharks fin soup and will not do so under any circumstances."
How I can Use this Package ? Any Example ! Jani
Code: connect internal set serveroutput on begin dbms_output.enable(20000); dbms_lock.sleep(30); dbms_output.put_line('Hmm had a nice nap'); end; /
connect internal set serveroutput on begin dbms_output.enable(20000); dbms_lock.sleep(30); dbms_output.put_line('Hmm had a nice nap'); end; /
Originally posted by Jani How I can Use this Package ? Any Example ! Jani DECLARE X DATE; BEGIN SELECT SYSDATE INTO X FROM DUAL; DBMS_LOCK.SLEEP(12); END; / Oracle will wait for 12 seconds.
I recommend you the following book: Oracle Built-in Packages by Feuerstein, Steven Paperback. O'Reilly & Associates, US, UK, 199804. ISBN: 1565923758.
When using DBMS_LOCK.SLEEP one must be aware of the bug that is present in *all* Oracle editions so far, AFAIK even in 9.0.1. The bug is described at the end of the following article: http://www.jlcomp.demon.co.uk/faq/sleep.html
Jurij Modic ASCII a stupid question, get a stupid ANSI 24 hours in a day .... 24 beer in a case .... coincidence?
Wow, you've really researched the sleep function!! Thanks for the link! Orcale Corp. should pay you for your effords!
Forum Rules
Bookmarks