stay in loop for a particular time
697349Oct 7 2009 — edited Oct 7 2009Hi all,
i have a problem in my procedure which iam creating for a simple timer.
the following is the code:
CREATE OR REPLACE PROCEDURE plp_sample_timer(al_minutes IN NUMBER)
AS
ld_sysdate TIMESTAMP DEFAULT systimestamp;
ld_exit_time TIMESTAMP;
BEGIN
ld_exit_time:=ld_sysdate+(al_minutes/60);
dbms_output.put_line(ld_sysdate);dbms_output.put_line(al_minutes/60);
dbms_output.put_line(ld_exit_time);
END;
The input to my procedure will be the time in minutes.
I need to write a loop in my code such that the loop continues for the no.of minutes from current time and exits after the time input in minutes.
also i need to return the start time and end time as a concatenated string...the problem is my exit time calculation itself is going wrong..pls help me out.