Hi, This is normal for a relational database, your test case will not work with most databases (PostgreSQL for example, and most others). It might work with MySQL because this database is a bit weird in this respect. For example the following test case will give a similar error message for most databases:
drop table if exists test; create table test(id int, name varchar(255)); insert into test values(1, 'hello'); insert into test values(1, 'world'); select * from test group by id; Regards, Thomas On Fri, Nov 2, 2012 at 8:45 AM, Noel Grandin <[email protected]> wrote: > can you create a self-contained test case? > > > On 2012-11-01 18:39, Ciaran wrote: > >> Hi all, >> >> I've having trouble running the following query on H2: >> >> SELECT * from table1 GROUP BY t >> >> It returns with the error: >> Column "TABLE1.ID" must be in the GROUP BY list; SQL statement: >> SELECT * from table1 GROUP BY t [90016-166] 90016/90016 (Help) >> >> Stranger still another table, table2, that's virtually identical to >> table1, doesn't exhibit this problem. >> >> I read the HELP on error 90016 and search this group but I'm no closed to >> a solution. >> >> Any pointers much appreciated. >> >> Thanks, >> ct >> -- >> You received this message because you are subscribed to the Google Groups >> "H2 Database" group. >> To view this discussion on the web visit https://groups.google.com/d/** >> msg/h2-database/-/xmnXtx37rpIJ<https://groups.google.com/d/msg/h2-database/-/xmnXtx37rpIJ> >> **. >> To post to this group, send email to [email protected]. >> To unsubscribe from this group, send email to h2-database+unsubscribe@** >> googlegroups.com <h2-database%[email protected]>. >> For more options, visit this group at http://groups.google.com/** >> group/h2-database?hl=en<http://groups.google.com/group/h2-database?hl=en> >> . >> > > -- > You received this message because you are subscribed to the Google Groups > "H2 Database" group. > To post to this group, send email to [email protected]. > To unsubscribe from this group, send email to h2-database+unsubscribe@** > googlegroups.com <h2-database%[email protected]>. > For more options, visit this group at http://groups.google.com/** > group/h2-database?hl=en <http://groups.google.com/group/h2-database?hl=en> > . > > -- You received this message because you are subscribed to the Google Groups "H2 Database" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/h2-database?hl=en.
