プログラム側でタイムアウト設定したけど、どうやって試そう…って時用。
SQL Server
-- hh:mm:ss
WAITFOR DELAY '00:00:30';
Oracle
Oracle 12c まで
先にDBMS_LOCK権限を付与
CONN / AS SYSDBA
GRANT EXECUTE ON DBMS_LOCK TO ユーザー名 ;
-- 10秒
DBMS_LOCK.SLEEP(10);
-- 0.5秒
DBMS_LOCK.SLEEP(0.5);
Oracle 18c 以降
権限付与必要なし
-- 10秒
DBMS_SESSION.SLEEP(10);
MySQL
-- 10秒
SELECT SLEEP(10);
PostgreSQL
-- 10秒
SELECT pg_sleep(10);