Home > database >  Consult ace: stored procedures in the SQL analyzer run normally, PB is executed in the lock table ca
Consult ace: stored procedures in the SQL analyzer run normally, PB is executed in the lock table ca

Time:10-04

Stored procedure:
1. Insert into A1
2. Update A1
The middle also have affairs, after an insert commit;

Stored procedures in the SQL analyzer run normally, and soon. But in PB call, if small amount of data is no problem, but when there are large amounts of data,
When performing the update, insert: no problem, but in execution stops here not bottom go to, the database lock table.

CodePudding user response:

It is best not to call a stored procedure to complete the task, you can use the trigger, generally stored procedure doesn't INSERT and UPDATE the statement, in view of the temporary table, otherwise the transfer process in the program to complete the task will be to some strange situation

CodePudding user response:

reference 1st floor xiongxiao response:
it is best not to call a stored procedure to complete the task, you can use the trigger, generally stored procedure doesn't INSERT and UPDATE the statement, in view of the temporary table, otherwise the transfer process in the program to complete the task will be to some strange situation


I do in the system a lot of use stored procedures to implement insert to update the business tables, etc., also can appear strange situation?
Now find some strange phenomenon of loss of data, don't know about this?
  • Related