Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

ORACLE JOB

Posted on 2013-12-18
7
Medium Priority
?
500 Views
Last Modified: 2013-12-18
Hi,
I created Stored Procedure that need to run every 15 minutes.
I tested with SQL, works fine...
begin
update_sad_header('BG','TR');
end;

I tested as well: update_sad_header('KG','AF'); and works fine...
Can someone help me to create JOB with those two parameters (arguments)?

Thank you
0
Comment
Question by:andrejaTJ
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 4
  • 2
7 Comments
 
LVL 14

Expert Comment

by:Alexander Eßer [Alex140181]
ID: 39726102
classic DBMS_JOB would look like this:

begin
  sys.dbms_job.submit(job => :job,
                      what => 'update_sad_header(''KG'',''AF'');',
                      next_date => sysdate,
                      interval => 'sysdate + 15/1440');
  commit;
end;

Open in new window


This starts the job immediately.
0
 

Author Comment

by:andrejaTJ
ID: 39726133
Thank you Alex,
I'm getting error:

[Err] ORA-01008: not all variables bound

This is not creating job :(
Best,
Andreja
0
 
LVL 14

Accepted Solution

by:
Alexander Eßer [Alex140181] earned 800 total points
ID: 39726252
Sorry, my bad ;-)

declare
l_job binary_integer;
begin
  sys.dbms_job.submit(job => l_job,
                      what => 'update_sad_header(''KG'',''AF'');',
                      next_date => sysdate,
                      interval => 'sysdate + 15/1440');
  commit;
end;

Open in new window

0
What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

 
LVL 14

Expert Comment

by:Alexander Eßer [Alex140181]
ID: 39726449
Thanks for accepting my comment as the solutions, BUT why do I get that "B" penalty?!
0
 

Author Comment

by:andrejaTJ
ID: 39726481
Sorry...
How I can change the grade?!
Best,
0
 
LVL 14

Expert Comment

by:Alexander Eßer [Alex140181]
ID: 39726503
Thanks a lot ;-)

Cheers,
Alex
0

Featured Post

What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Shell script to create broker configuration file using current broker Configuration, solely for purpose of backup on Linux. Script may need to be modified depending on OS-installation. Please deploy and verify the script in a test environment.
An alternative to the "For XML" way of pivoting and concatenating result sets into strings, and an easy introduction to "common table expressions" (CTEs). Being someone who is always looking for alternatives to "work your data", I came across this …
This video explains what a user managed backup is and shows how to take one, providing a couple of simple example scripts.
This tutorial will introduce the viewer to VisualVM for the Java platform application. This video explains an example program and covers the Overview, Monitor, and Heap Dump tabs.

604 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question