M
M
masterwen2020-04-30 13:46:12
PHP
masterwen, 2020-04-30 13:46:12

How to subtract value in bd via php?

1.) There are two different tables in the table for example BD_clon and BD_lolin
Lines in BD_lolin are deleted after the time expires with this code

$db->Query (" DELETE FROM db_sell WHERE date_del >' $da' ");

and I need that when deleting a row in the BD_clon table, the value in the bazaa column is subtracted

Answer the question

In order to leave comments, you need to log in

1 answer(s)
A
Andrey, 2020-04-30
@AndryG

Write a post delete trigger, where you can change the value of a field in a different table with a query. Without a table structure, you won't get a more specific answer.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question