This topic is locked

Update Third Table

2/13/2015 9:36:25 AM
PHPRunner General questions
A
alina70 author

Hi there are 3 tables
Table 1

piatto (index auto incremental)

descrizione

Last Date

Total
Table 2

Menu (index auto incremental)

Data Menu
Tabel 3

Menu ( === linked to table 2)

Piatto (=== linked to table 1)
Scope1: Update LAST DATE of TABLE1 with DATA MENU of the PIATTO in (table3)

Scope2: Update TOTAL of TABLE1 of the PIATTO (table3) with TOTAL=TOTAL+1
In this way I should know WHEN I used a Piatto in a Menu....
How can I do to solve this problem??
Thank you

Sergey Kornilov admin 2/14/2015

I'm trying to decipher what are you saying but not having much luck. Could you rephrase your question to make it easier to understand?
When do you need to run those update queries?

A
alina70 author 2/16/2015



I'm trying to decipher what are you saying but not having much luck. Could you rephrase your question to make it easier to understand?
When do you need to run those update queries?


Sorry but the problem is my bad english... Do you speak italian?
I need to run the update queries in PIATTI TABLE when I add or update a MENU and so I add a dish (piatto) in detail menu.

In those moment the DATE in (master table Menu) must update the date in "piatti table".
After I'd like to run a batch that reads all rows in the menu details and update the "piatti table" with correct date.
Can you help me?