SQL Clone
SQLServerCentral is supported by Redgate
 
Log in  ::  Register  ::  Not logged in
 
 
 


SQL JOBS Not Functioning


SQL JOBS Not Functioning

Author
Message
OnlyOneRJ
OnlyOneRJ
Old Hand
Old Hand (346 reputation)Old Hand (346 reputation)Old Hand (346 reputation)Old Hand (346 reputation)Old Hand (346 reputation)Old Hand (346 reputation)Old Hand (346 reputation)Old Hand (346 reputation)

Group: General Forum Members
Points: 346 Visits: 690
SQL JOBS Not Functioning w00t

I have Stored procedure & that stored procedure needs to be executed on 20 Databases daily,
Currently i am doing it manually..

I tried setting the Jobs on SQL but it only executes the SP for One database & not for all DB's.... w00t

how do i set the JOBS one after one..
I mean...

1st the SP for one DB will be executed & only after that the SP should get executed of rthe second DB & so on....Crazy somehow i am not getting the exact steps or i may be missing something.. please help me

************************************
Every Dog has a Tail !!!!! :-D
John Mitchell-245523
John Mitchell-245523
SSChampion
SSChampion (14K reputation)SSChampion (14K reputation)SSChampion (14K reputation)SSChampion (14K reputation)SSChampion (14K reputation)SSChampion (14K reputation)SSChampion (14K reputation)SSChampion (14K reputation)

Group: General Forum Members
Points: 14214 Visits: 15967
Something like this?

EXEC DB1.dbo.MySP 
EXEC DB2.dbo.MySP
EXEC DB3.dbo.MySP
EXEC DB4.dbo.MySP
EXEC DB5.dbo.MySP
EXEC DB6.dbo.MySP
EXEC DB7.dbo.MySP
EXEC DB8.dbo.MySP
EXEC DB9.dbo.MySP
EXEC DB10.dbo.MySP
EXEC DB11.dbo.MySP
EXEC DB12.dbo.MySP
EXEC DB13.dbo.MySP
EXEC DB14.dbo.MySP
EXEC DB15.dbo.MySP
EXEC DB16.dbo.MySP
EXEC DB17.dbo.MySP
EXEC DB18.dbo.MySP
EXEC DB19.dbo.MySP
EXEC DB20.dbo.MySP



John
OnlyOneRJ
OnlyOneRJ
Old Hand
Old Hand (346 reputation)Old Hand (346 reputation)Old Hand (346 reputation)Old Hand (346 reputation)Old Hand (346 reputation)Old Hand (346 reputation)Old Hand (346 reputation)Old Hand (346 reputation)

Group: General Forum Members
Points: 346 Visits: 690
Yes John, same to same :-)

************************************
Every Dog has a Tail !!!!! :-D
OnlyOneRJ
OnlyOneRJ
Old Hand
Old Hand (346 reputation)Old Hand (346 reputation)Old Hand (346 reputation)Old Hand (346 reputation)Old Hand (346 reputation)Old Hand (346 reputation)Old Hand (346 reputation)Old Hand (346 reputation)

Group: General Forum Members
Points: 346 Visits: 690
john, where did u gow00t

************************************
Every Dog has a Tail !!!!! :-D
John Mitchell-245523
John Mitchell-245523
SSChampion
SSChampion (14K reputation)SSChampion (14K reputation)SSChampion (14K reputation)SSChampion (14K reputation)SSChampion (14K reputation)SSChampion (14K reputation)SSChampion (14K reputation)SSChampion (14K reputation)

Group: General Forum Members
Points: 14214 Visits: 15967
I didn't go anywhere. What is your question?

John
OnlyOneRJ
OnlyOneRJ
Old Hand
Old Hand (346 reputation)Old Hand (346 reputation)Old Hand (346 reputation)Old Hand (346 reputation)Old Hand (346 reputation)Old Hand (346 reputation)Old Hand (346 reputation)Old Hand (346 reputation)

Group: General Forum Members
Points: 346 Visits: 690
how do i set the JOBS one after one..
I mean...

1st the SP for one DB will be executed & only after that the SP should get executed of rthe second DB & so on....

Is this possible to perform the above activity in One Single Job???

************************************
Every Dog has a Tail !!!!! :-D
anthony.green
anthony.green
SSChampion
SSChampion (10K reputation)SSChampion (10K reputation)SSChampion (10K reputation)SSChampion (10K reputation)SSChampion (10K reputation)SSChampion (10K reputation)SSChampion (10K reputation)SSChampion (10K reputation)

Group: General Forum Members
Points: 10112 Visits: 6340
Does the same procedure exist in all 20 databases and does it need any special paramateres to run?



Want an answer fast? Try here
How to post data/code for the best help - Jeff Moden
When a question, really isn't a question - Jeff Smith
Need a string splitter, try this - Jeff Moden
How to post performance problems - Gail Shaw
CrossTabs-Part1 & Part2 - Jeff Moden
SQL Server Backup, Integrity Check, and Index and Statistics Maintenance - Ola Hallengren
Managing Transaction Logs - Gail Shaw
Troubleshooting SQL Server: A Guide for the Accidental DBA - Jonathan Kehayias and Ted Krueger


John Mitchell-245523
John Mitchell-245523
SSChampion
SSChampion (14K reputation)SSChampion (14K reputation)SSChampion (14K reputation)SSChampion (14K reputation)SSChampion (14K reputation)SSChampion (14K reputation)SSChampion (14K reputation)SSChampion (14K reputation)

Group: General Forum Members
Points: 14214 Visits: 15967
Not only can you do it one single job, you can do it in one single job step, in the way I suggested above.

John
OnlyOneRJ
OnlyOneRJ
Old Hand
Old Hand (346 reputation)Old Hand (346 reputation)Old Hand (346 reputation)Old Hand (346 reputation)Old Hand (346 reputation)Old Hand (346 reputation)Old Hand (346 reputation)Old Hand (346 reputation)

Group: General Forum Members
Points: 346 Visits: 690
Yes the procedure is same for all database, but John can u let me know the steps by step about setting the jobs?

************************************
Every Dog has a Tail !!!!! :-D
John Mitchell-245523
John Mitchell-245523
SSChampion
SSChampion (14K reputation)SSChampion (14K reputation)SSChampion (14K reputation)SSChampion (14K reputation)SSChampion (14K reputation)SSChampion (14K reputation)SSChampion (14K reputation)SSChampion (14K reputation)

Group: General Forum Members
Points: 14214 Visits: 15967
(1) Modify the code I posted so that it fits your environment
(2) Create a new job
(3) Copy and paste the code into the "Command" field
(4) Schedule the job to run with the desired frequency and at the desired times

Clearly you're struggling with something, but remember I'm not standing behind you and I can't see your screen, so if there's anything you don't understand, please be very specific about what it is.

John
Go


Permissions

You can't post new topics.
You can't post topic replies.
You can't post new polls.
You can't post replies to polls.
You can't edit your own topics.
You can't delete your own topics.
You can't edit other topics.
You can't delete other topics.
You can't edit your own posts.
You can't edit other posts.
You can't delete your own posts.
You can't delete other posts.
You can't post events.
You can't edit your own events.
You can't edit other events.
You can't delete your own events.
You can't delete other events.
You can't send private messages.
You can't send emails.
You can read topics.
You can't vote in polls.
You can't upload attachments.
You can download attachments.
You can't post HTML code.
You can't edit HTML code.
You can't post IFCode.
You can't post JavaScript.
You can post emoticons.
You can't post or upload images.

Select a forum

































































































































































SQLServerCentral


Search