16 lines
438 B
MySQL
16 lines
438 B
MySQL
|
DELIMITER $$
|
||
|
CREATE OR REPLACE DEFINER=`root`@`localhost` TRIGGER `vn`.`accountReconciliation_beforeInsert`
|
||
|
BEFORE INSERT ON `accountReconciliation`
|
||
|
FOR EACH ROW
|
||
|
|
||
|
SET NEW.calculatedCode = REPLACE(
|
||
|
REPLACE(
|
||
|
REPLACE(
|
||
|
REPLACE(
|
||
|
CONCAT(NEW.supplierAccountFk,NEW.operationDated,NEW.amount,NEW.concept,NEW.debitCredit)
|
||
|
,' ','')
|
||
|
,":",'')
|
||
|
,'-','')
|
||
|
,'.','')$$
|
||
|
DELIMITER ;
|