Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Seperating records
Message
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Title:
Seperating records
Miscellaneous
Thread ID:
00314974
Message ID:
00314974
Views:
61
Hello,
I have a table which contains the following fields:
order_id
rep1_id
rep2_id
rep3_id
com1_pct
com2_pct
com3_pct
How can I use a sql statement to reorganize the table which contains:
order_id
sale_id
commission
so if rep1, rep2,rep3 are unique, the record will become 3 records and teh commission will be com1_pct, com2_pct and com3_pct, if rep1,rep2 and rep3 are same, the record will be still one record but commission will be the sum of the com1_pct, com2_pct and com3_pct.
thanks
sherry
Next
Reply
Map
View

Click here to load this message in the networking platform