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 |
|
cube
Starting Member
1 Post |
Posted - 2001-06-03 : 09:02:10
|
| Sorry, I'm beginner, so, a question is:I tryed to run the following code in MS SQL Server Query Analyser:---------USE db_usersIF EXISTS (SELECT * FROM sysobjects WHERE name='spStartSessionChecking' AND type='P')DROP PROCEDURE spStartSessionCheckingGOCREATE PROCEDURE spStartSessionCheckingAS EXEC sp_add_job @job_name='jbSessionChecking' EXEC sp_add_jobstep @job_name='jbSessionChecking', @subsystem = 'TSQL', @command = 'exec spCheckUsersSessions' EXEC sp_add_jobschedule @job_name='jbSessionChecking', @freq_type = 4, @freq_interval = 1, @freq_subday_type = 0x4, @freq_subday_interval = 10 GOIF EXISTS (SELECT * FROM sysobjects WHERE name='spEndSessionChecking' AND type='P')DROP PROCEDURE spEndSessionCheckingGOCREATE PROCEDURE spEndSessionCheckingAS EXEC sp_delete_job @job_name='jbSessionChecking' GO-----------So, returned errors:Cannot add rows to sysdepends for the current stored procedure because it depends on the missing object 'sp_add_job'. The stored procedure will still be created.Cannot add rows to sysdepends for the current stored procedure because it depends on the missing object 'sp_add_jobstep'. The stored procedure will still be created.Cannot add rows to sysdepends for the current stored procedure because it depends on the missing object 'sp_add_jobschedule'. The stored procedure will still be created.Cannot add rows to sysdepends for the current stored procedure because it depends on the missing object 'sp_delete_job'. The stored procedure will still be created.What's wrong and how to do this correctly?Thanks |
|
|
|
|
|