Hello everyone, I'm a bit new to SQL DB administration and I have a doubt when generating a trigger to update a table field. I detail more below.
I have these 3 Tables:
And I need to make a Trigger that updates the [Total Product] field every time there is a new Order of a certain employee is inserted.
It complicates me the fact that the field that I have to update is related to two more tables.
In addition to that I must do a gorup by query to be able to obtain the total number of products sold.