B
BlockNinja
I have a process that does an ODBC Pass Through to a Sybase server in order
to run a generalized stored procedure which runs certain commands and then
prints a result back to you. It looks something like so:
exec
sysstoredprocs..trs_command(@cmd='ctm_transfer',@from_name='table',@host='destinationip',@to_name='table')
Basically it does several utility functions like running predefined sequel
statements against a table, merging several tables into one,
copying/renaming/deleting tables, running a table through a sql filter and
outputting the results to a new table, etc all through a standard interface.
In order to get any output on if the process failed or not, I have to turn
"Log Messages" to yes. Then when the stored proc runs it sends the output to
the table Admin00, Admin01, etc.
The question is this, I have a process that is going out and doing several
operations in order, but the process looks like it runs asynchronously. When
I run the query I don't seem to get the results before the next operation
begins, and 2 things have to be addressed:
1) I don't want to overload the server with queued commands, folks in IT
will come after me with pitchforks.
2) There are dependencies in the process. i.e. I have to filter table1 into
table2 before I can filter table2 into table3.
How might I be able to know when the first query has finished so that I can
loop a DoEvents until it's actually done before going to the next?
to run a generalized stored procedure which runs certain commands and then
prints a result back to you. It looks something like so:
exec
sysstoredprocs..trs_command(@cmd='ctm_transfer',@from_name='table',@host='destinationip',@to_name='table')
Basically it does several utility functions like running predefined sequel
statements against a table, merging several tables into one,
copying/renaming/deleting tables, running a table through a sql filter and
outputting the results to a new table, etc all through a standard interface.
In order to get any output on if the process failed or not, I have to turn
"Log Messages" to yes. Then when the stored proc runs it sends the output to
the table Admin00, Admin01, etc.
The question is this, I have a process that is going out and doing several
operations in order, but the process looks like it runs asynchronously. When
I run the query I don't seem to get the results before the next operation
begins, and 2 things have to be addressed:
1) I don't want to overload the server with queued commands, folks in IT
will come after me with pitchforks.
2) There are dependencies in the process. i.e. I have to filter table1 into
table2 before I can filter table2 into table3.
How might I be able to know when the first query has finished so that I can
loop a DoEvents until it's actually done before going to the next?