Home » RDBMS Server » Server Administration » DBMS_JOB failure (Oracle 9.2.0.1.0)
DBMS_JOB failure [message #356591] Fri, 31 October 2008 06:16 Go to next message
sweetkhaliq
Messages: 200
Registered: April 2006
Senior Member

Dear i have make a job to update table from remote computer database that will be run after every 10 seconds . So i have write this procudeure

CREATE OR REPLACE PROCEDURE update_attendance IS
    hr_date date := null;
    server_date date := null;
BEGIN
  select max(time_in) into hr_date from attendance@hr;
    select max(time_in) into server_date from attendance;
    if hr_date > server_date then
       insert into attendance 
       select * from attendance@hr a where a.time_in > server_date;
       commit;
    end if;
END update_attendance;


and i have made this job.

declare
  v_job number:=55;
begin
  dbms_job.SUBMIT(v_job,'update_attendance;',sysdate+10/86400,'sysdate+10/86400');
  dbms_output.put_line(v_job);
 
end;

when i run this job manually with this query
execute dbms_job.RUN(52);

Then only one time it updates the destination table but after this every time it fails.

Please tell me what is the problem.

thanks and regards
Re: DBMS_JOB failure [message #356603 is a reply to message #356591] Fri, 31 October 2008 08:00 Go to previous messageGo to next message
Michel Cadot
Messages: 68718
Registered: March 2007
Location: Saint-Maur, France, https...
Senior Member
Account Moderator
Have a look at alert.log, it will tell you why it fails (if it is really scheduled).

Regards
Michel
Re: DBMS_JOB failure [message #356680 is a reply to message #356603] Fri, 31 October 2008 23:15 Go to previous messageGo to next message
sweetkhaliq
Messages: 200
Registered: April 2006
Senior Member

Thanks for reply
In which directore i can see the alert.log file.
Re: DBMS_JOB failure [message #356681 is a reply to message #356680] Fri, 31 October 2008 23:21 Go to previous messageGo to next message
sweetkhaliq
Messages: 200
Registered: April 2006
Senior Member

I have checked in installed oracle folder there is no file like alert.log.
Re: DBMS_JOB failure [message #356690 is a reply to message #356680] Sat, 01 November 2008 02:32 Go to previous messageGo to next message
Michel Cadot
Messages: 68718
Registered: March 2007
Location: Saint-Maur, France, https...
Senior Member
Account Moderator
It is in the directory given by the parameter background_dump_dest.

Regards
Michel
Re: DBMS_JOB failure [message #356723 is a reply to message #356690] Sat, 01 November 2008 07:02 Go to previous messageGo to next message
sweetkhaliq
Messages: 200
Registered: April 2006
Senior Member

Still unable to solve the problem.
Re: DBMS_JOB failure [message #356731 is a reply to message #356723] Sat, 01 November 2008 10:55 Go to previous message
Michel Cadot
Messages: 68718
Registered: March 2007
Location: Saint-Maur, France, https...
Senior Member
Account Moderator
As you don't add more information we can't give more help.
For instance, you didn't define what "but after this every time it fails" means.

Regards
Michel
Previous Topic: drop table error
Next Topic: Help upgrading database
Goto Forum:
  


Current Time: Tue Dec 03 01:42:17 CST 2024