Hi,
I have an issue (with sql generated by a 3rd party library - mondrian)
which does not work in h2. The second query (below) does not work, I assume
that it should be valid,
Thanks for any help,
Mike
drop table x if exists;
create table x (date date) ;
insert into x (date) values('2011-12-31');
insert into x (date) values('2012-01-01');
insert into x (date) values('2012-01-03');
SELECT
YEAR(date) as year
FROM x
GROUP BY YEAR(date)
ORDER BY
YEAR(date) ASC;
SELECT
YEAR(date) as year
FROM x
GROUP BY YEAR(date)
ORDER BY
CASE WHEN YEAR(date) IS NULL THEN 1 ELSE 0 END,
YEAR(date) ASC;
--
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.