I have a question related to the Delete and Update Query.
The folowing table is given:
Expand|Select|Wrap|Line Numbers
- ContractID CarID Count Weight Earnings
1 2 0.5 10 100
1 2 0.5 12 120
1 5 0.33 14 150
1 5 0.67 24 250
As you see the point of the table is to see how each car of each contract is divided. My aim is to merge those data with the same ContractID and CarID. From the example above it should result:
1 2 1 22 220
1 5 1 38 400
I was thinking to solve the problem in two steps:
1. Update Query (Sum all Count, Weight and Earnings with the same ContractID and CarID together and enter them in those fields):
1 2 1 22 220
1 2 1 22 220
1 5 1 38 400
1 5 1 38 400
2. Delete double entries (not the problem here)
So how to do the first step? Or is there another way to solve this problem?
I would be deeply grateful for any help. Thanks in advance.
BR,
Dete Vi Jete