Q: SQL Group By? 
Author Message
 Q: SQL Group By?

Please, can someone tell me how to use GROUP BY for a subset of characters
in a field? What I mean is illustrated below:

Field1      Field2
-------     -------
Red_A       12
Red_B       3
Blue        1
Black       7

I would like to summarize this data on three lines such as:

Group       SUM
-------     -------
Red         15
Blue        1
Black       7

It would be most useful if you could answer this via e-mail and usenet if
you can help. Thanks for your help.

Norman Parker

--



Mon, 10 Apr 2000 03:00:00 GMT
 
 [ 1 post ] 

 Relevant Pages 

1. SQL 7.0 OLE DB Qs. Help!

2. Enabling TCP/IP server protocol BUG in SQL2K and SQL Server 6.5 native driver Qs

3. Rolling Up a Group (or, Grouping a Group)

4. Remapping/Copying SQL Logins from NT Local Groups to Domain Global Groups

5. SQL 7 Group Security and Predefined NT Groups

6. How to get only the first row by GROUP in a SQL SELECT with GROUP BY

7. SQL statement grouping by a field , and ordering within a group

8. applying snapshot manually 2 Qs

9. 2 Qs: Column statistics & selectivity

10. VB4EE/NT4/SS6.5 Security Qs

11. Multi Server Administration Qs

12. newbie qs; examining databases and tables


 
Powered by phpBB® Forum Software