Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
| Author |
Topic |
|
cccmtx
Starting Member
4 Posts |
Posted - 2012-09-14 : 12:46:24
|
| Hi folks, i have a question regarding Stored Procedures.Can I Schedule Stored Procedure execution without use of SQLServerAgent?Thanks,Mike |
|
|
chadmat
The Chadinator
1974 Posts |
Posted - 2012-09-14 : 12:54:01
|
| You could probably use windows task scheduler and a script of some kind.-Chad |
 |
|
|
xhostx
Constraint Violating Yak Guru
277 Posts |
Posted - 2012-09-14 : 14:02:03
|
you can create a .SQL file first (which will include you SP).create a .bat file with the following command(isql/osql/sqlcmd -ddbase -User -Pass -iYour.SQLFile -n ). Then go to Task SCheduler create a new scheduled Task and specify the .bat file to be called automatically. you also need to set the execution time for this Task and make sure it is under a User that belongs to Administrators groups.Note thatisql/osql/sqlcmd is up to which version of SQL you are using.--------------------------Joins are what RDBMS's do for a living |
 |
|
|
cccmtx
Starting Member
4 Posts |
Posted - 2012-09-16 : 03:58:47
|
| Thank's for you help xhostx, I'm using SQL 2008. |
 |
|
|
visakh16
Very Important crosS Applying yaK Herder
52326 Posts |
Posted - 2012-09-16 : 12:37:32
|
quote: Originally posted by cccmtx Hi folks, i have a question regarding Stored Procedures.Can I Schedule Stored Procedure execution without use of SQLServerAgent?Thanks,Mike
you cancall it from batch file------------------------------------------------------------------------------------------------------SQL Server MVPhttp://visakhm.blogspot.com/ |
 |
|
|
cccmtx
Starting Member
4 Posts |
Posted - 2012-09-17 : 12:51:28
|
| that's great, one other thing, how do i create it? |
 |
|
|
visakh16
Very Important crosS Applying yaK Herder
52326 Posts |
Posted - 2012-09-17 : 13:03:01
|
| you can create in any editor by typing commands and saving as .bat------------------------------------------------------------------------------------------------------SQL Server MVPhttp://visakhm.blogspot.com/ |
 |
|
|
|
|
|