Home > database >  How do the mysql in the transaction using an if... The else...
How do the mysql in the transaction using an if... The else...

Time:09-20

Start the transaction;
The begin.
Select @ a:=squareNumber from squareNum where ` number `=2;
If @ a=4
Then
Insert into squareNum values (4, 16);
The else
The rollback.
End the if;
Commit;


How to write why will not take effect?

CodePudding user response:

I guess is a function of the stored procedure, you want to know
  • Related