T
trigger
Guest
I dont know how to explain because my english its bad, so im going to try:
There's a company named "A" that their objective its to go to restaurants and sell products (fish, meat, seafood...), but these products are from a "big company" that has no comercial department, and hires companies like "A" to sell its products, paying about 10% of what they sell... So the "A" company has its sellers (each seller its atribuited to a few clients) to go to restaurants and make an appointment of the products the restaurant wants and send it to the "big company", the "big company" at the end of the month sends a report (in ms-excel format) of what the "A" company have sold and the ammount of ?Comission? %.
In order to get the data from excel i made an importation with the following fields:
selling table
Product Reference
Client Code
Invoice Number
Date
Value
Quantity
I've inserted all data about produts, clients and sellers in other tables
The problem seems to be in when i change the seller attribuited to a client, the database changes all records in the "selling table" instead of changing records from the day i've changed the employe...
Tables relationship between clients and sellers its w/out refer. integrity
Clients Sellers
Client Code /---------- Seller code
Client Name / Seller name
Adress / Comission of seller
Seller <-------/ .....
etc...
If u cant understand i try can explain better but my english its very weak
Tks..
There's a company named "A" that their objective its to go to restaurants and sell products (fish, meat, seafood...), but these products are from a "big company" that has no comercial department, and hires companies like "A" to sell its products, paying about 10% of what they sell... So the "A" company has its sellers (each seller its atribuited to a few clients) to go to restaurants and make an appointment of the products the restaurant wants and send it to the "big company", the "big company" at the end of the month sends a report (in ms-excel format) of what the "A" company have sold and the ammount of ?Comission? %.
In order to get the data from excel i made an importation with the following fields:
selling table
Product Reference
Client Code
Invoice Number
Date
Value
Quantity
I've inserted all data about produts, clients and sellers in other tables
The problem seems to be in when i change the seller attribuited to a client, the database changes all records in the "selling table" instead of changing records from the day i've changed the employe...
Tables relationship between clients and sellers its w/out refer. integrity
Clients Sellers
Client Code /---------- Seller code
Client Name / Seller name
Adress / Comission of seller
Seller <-------/ .....
etc...
If u cant understand i try can explain better but my english its very weak
Tks..