Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Sum of columns
Message
 
 
To
10/05/2007 22:32:23
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Title:
Miscellaneous
Thread ID:
01224403
Message ID:
01224419
Views:
21
>Thank for your prompt reply.
>
>The results expected as:
>
>newtable also contains 3 fields
>
>order  late1x late2x  type
>
>11111  5     1      CL
>
>33333  11    5      PL
>
>44444  8     4      ML
>55555  9     3      ML
I haven't tried your SQL, but from what I saw it is written exactly right except for the columns order, e.g. you may want

select Order, sum(Late1) as Late1X, sum(Late2) as Late2X, Type from YouTable ;
group by Order, Type into table NewTable

What exactly is not working here? I don't see a problem.
If it's not broken, fix it until it is.


My Blog
Previous
Reply
Map
View

Click here to load this message in the networking platform