Sleep Command for PL/SQL
DBAsupport.com Forums - Powered by vBulletin
Results 1 to 4 of 4

Thread: Sleep Command for PL/SQL

  1. #1
    Join Date
    Jan 2001
    Posts
    515
    Is there a sleep type command for PL/SQL? I want to be able to pause my program for 5 minutes and then continue on. Any ideas?

  2. #2
    Join Date
    Sep 2001
    Location
    NJ, USA
    Posts
    1,287
    DBMS_LOCK.SLEEP (seconds IN NUMBER);

    http://download-east.oracle.com/otnd...l6a.htm#998467

  3. #3
    Join Date
    Dec 2000
    Location
    Ljubljana, Slovenia
    Posts
    4,439
    It is good to be aware of some nasty bugs regarding DBMS_LOCK.SLEEP, particulary if you want to have relatively accurate sleeping intervals or if you want to sleep for a longer period of time (sey for more than half an hour). Those bugs are described at the "BUG Warning" of the following article:

    http://www.jlcomp.demon.co.uk/faq/sleep.html

    Those bugs were present in all release up to 8i (If I remember correctly I last checked and reported them to Oracle as bugs on 8.1.7, I haven't took my time to test if they have been resolved on 9i).
    Jurij Modic
    ASCII a stupid question, get a stupid ANSI
    24 hours in a day .... 24 beer in a case .... coincidence?

  4. #4
    Join Date
    Sep 2001
    Location
    NJ, USA
    Posts
    1,287
    Thanks Jury a lot.
    I didn't now about this problem.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  


Click Here to Expand Forum to Full Width