Hi,
here is a newbie to Cognos and to the community here.
I'm trying to run a fairly simple SQL Query in Cognos but it fails.
SELECT COUNT(*) AS n_rows, LAST_DAY(DATETIME_COLUMN), MONTH(DATETIME_COLUMN), YEAR(DATETIME_COLUMN) FROM MY_TABLE GROUP BY LAST_DAY(DATETIME_COLUMN), MONTH(DATETIME_COLUMN), YEAR(DATETIME_COLUMN)
Any tip/help is greatly appreciated.
Cheers,
Bora
What's the error you get?
Is the SQL used as a 'Native' SQL or 'Cognos' or 'pass-through' SQL?
If it is used as a Native SQL what's the database? SQL Server does not have any LAST_DAY function but MySQL and Oracle have. The more information you provide in your 1st question, the faster you will get the answer.