Home > Back-end >  Amadeus excuse me how to use a transaction to perform a new statement, a modified statement, a store
Amadeus excuse me how to use a transaction to perform a new statement, a modified statement, a store

Time:09-28

Now my project has been forming, the business logic can be configured, which stored procedures, such as audit performed audit operations is a sign of general update to revise the audit and audit, the audit time, this write to death in the program, through configuration, after when performing audit sign immediately to execute the stored procedure, here's the thing:
The original code, the two operations are respectively AstaClientDataSet to perform, no transaction encapsulation, now I want to use transaction execution, tried to use SendParamterizedQueries, but don't know how to get the stored procedure output parameter values (found value hasn't changed, inside a stored procedure parameter value should be changed, the stored procedure must be true, has to verify), separately used as long as AstaClientDataSet. After ExecSql AstaClientDataSet. Params (' name ') can take to asString,
PS: SendParamterizedQueries can get abnormal information, can not get the output parameter values, do not let me change the output parameter values to exception information (the multiple storage process, call I go to change, want to die), don't let me to review code into a stored procedure (this process multiple storage, call I go to change, want to die),
I want to be able to use these two operating transaction encapsulation, and after execution of stored procedure output parameter values

CodePudding user response:

Declare @ code varchar (20)
The exec p_xxx @ outValue=https://bbs.csdn.net/topics/@code output
Select @ code as code

Three sentences together execution result set