Rich Shepard <[email protected]> wrote: > The closest I've come so far is: > sqlite> select sic, sic_desc, state, count(*) from Companies group by sic; > The 'group by' phrase returns one row per group, which is what I want as > long as the group is a compound of industry number and state
Just throw more columns into GROUP BY clause: select sic, sic_desc, state, count(*) from Companies group by sic, sic_desc, state; -- Igor Tandetnik _______________________________________________ sqlite-users mailing list [email protected] http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

