Good morning, I had the need to create a stock control, but I had never used a trigger.
I have 3 tables COMPRA
ABASTECIMENTO
and MOVIMENTO_ESTOQUE
Table MOVIMENTO_ESTOQUE
:
I would like that when I make a purchase I would write all the data except the COD_ABASTECIMENTO
and the TIPO
I would write a C
credit and when I make a purchase all the data except COD_COMPRA
and% COD_ITEMCOMPRA
and TIPO
was written D
of debit, how would I create this trigger to control the stock?