Hello all,

I have a table foo (id INTEGER, tid INTEGER, optype INTEGER),
and I have some data into foo:
id      id2     optype
---------------------
1       2       10
2       2       10
3       2       10
4       2       10
5       2       10
6       2       20
7       2       10
8       2       20
9       2       20
10      2       10

I need a query that returns results like:
1,2,3,4,5
6
7
8,9
10

(divided by optype and sorted by id)

If I use a simple:
SELECT group_concat(id) FROM rsql_mvcc WHERE transactionID=2 GROUP BY  
OPTYPE;

I obtain:
1,2,3,4,5,7,10
6,8,9

I would really appreciate any help.
Thanks a lot.
-- 
Marco Bambini
http://www.sqlabs.com
http://www.creolabs.com/payshield/





_______________________________________________
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Reply via email to