March 31, 2006 at 12:28 pm
update table1 set val = ? where id = ?; select @@ERROR, @@ROWCOUNT
This is how I invoke the lookup from the vbscript:
errorCodeArray = DTSLookups("mylookup").Execute(val1, val2)
I also have a step to handle the "On Failure" workflow.
Let's say for some reason the update statement in the lookup fails. As a result, my "On Failure" workflow
will be executed. However, in my failure task, I can't seem to get the correct value of the sql error code from the @@ERROR. It gives me a 0.
Can someone show me how to capture the @@ERROR from the failed sql statement in DTSLookups?
any help is appreciated.
Newbie.
April 3, 2006 at 8:00 am
This was removed by the editor as SPAM
April 4, 2006 at 2:56 pm
Try assigning the results of the @@ERROR query to a global variable that the 'on failure' step can read to get the value.
Greg
Greg
April 5, 2006 at 3:31 pm
Thank you very much for your response.
But I don't see an option for me to assign @@ERROR to a global variable from within Lookup.
Viewing 4 posts - 1 through 3 (of 3 total)
You must be logged in to reply to this topic. Login to reply