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.

 All Forums
 SQL Server 2000 Forums
 SQL Server Development (2000)
 Progress of a MS Stored Procedure

Author  Topic 

AskSQLTeam
Ask SQLTeam Question

0 Posts

Posted - 2004-06-08 : 07:55:51
Peter writes "From VB I would like to provide feedback to users that the SP is running and provide a guage or other feedback. The SP takes about 2 mins to run. There does not seem to be a system stored procedure for monitoring a submitted SP.

Any advise would be appreciated.

Thanks"

AndrewMurphy
Master Smack Fu Yak Hacker

2916 Posts

Posted - 2004-06-08 : 08:05:23
UNLESS the SP has sub-steps within it....at which you can create a log-entry notifying the progress of the SP....which can then be reported upon by the online application....

I think you're gonna be screwed....
Go to Top of Page

Knarf180
Starting Member

42 Posts

Posted - 2004-06-08 : 09:36:05
Heh, welcome to my life. I have SP that take over 10 minutes to run. All the user gets is an hour glass and a coffee break.
Go to Top of Page

X002548
Not Just a Number

15586 Posts

Posted - 2004-06-08 : 10:46:10
echo out statements to a flat file with getdate() to identify where the processing problems are..


Select @Log_Id = IsNull(Max(IsNull(Log_Id,0)),0) + 1 From Tax_Load_Log

SET @var = RTrim(Convert(Char(20),@Log_Id)) + '|U|'+RTrim(Convert(char(50),GetDate(),109))+'|Starting Quarterly Load Process'
SET @cmd = 'echo ' + '"|' + @var + '|"' + ' > d:\Data\Tax\log_out.txt'
SET @Command_string = 'EXEC master..xp_cmdshell ''' + @cmd + ''', NO_OUTPUT'

Exec(@Command_String)


I the load the messages to a table on exit of the sproc



Brett

8-)
Go to Top of Page
   

- Advertisement -