Solved

ORACLE JOB

Posted on 2013-12-18
7
489 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
  • 4
  • 2
7 Comments
 
LVL 13

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 13

Accepted Solution

by:
Alexander Eßer [Alex140181] earned 200 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
Do You Know the 4 Main Threat Actor Types?

Do you know the main threat actor types? Most attackers fall into one of four categories, each with their own favored tactics, techniques, and procedures.

 
LVL 13

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 13

Expert Comment

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

Cheers,
Alex
0

Featured Post

Why You Should Analyze Threat Actor TTPs

After years of analyzing threat actor behavior, it’s become clear that at any given time there are specific tactics, techniques, and procedures (TTPs) that are particularly prevalent. By analyzing and understanding these TTPs, you can dramatically enhance your security program.

Join & Write a Comment

Suggested Solutions

Title # Comments Views Activity
query help 18 51
oracle rollup query 3 37
query returning everything 11 68
Oracle -- identify blocking session 24 22
This post first appeared at Oracleinaction  (http://oracleinaction.com/undo-and-redo-in-oracle/)by Anju Garg (Myself). I  will demonstrate that undo for DML’s is stored both in undo tablespace and online redo logs. Then, we will analyze the reaso…
I'd like to talk about something that is near and dear to my heart: build systems. Without them, building software is all about compiling locally, with software versions everywhere. It can be a mess. Today we are going to discuss building a small di…
Video by: Steve
Using examples as well as descriptions, step through each of the common simple join types, explaining differences in syntax, differences in expected outputs and showing how the queries run along with the actual outputs based upon a simple set of dem…
This tutorial covers a step-by-step guide to install VisualVM launcher in eclipse.

758 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

Need Help in Real-Time?

Connect with top rated Experts

17 Experts available now in Live!

Get 1:1 Help Now