Ming Lei wrote:
That's because the GROUP BY clause is not supported by DBD::CSV. Please look in the documentation for SQL::Parser to see a list of the (fairly limited) SQL that DBD::CSV supports.I am using CSV under DBI. A select statement with "group by" always gives me error:
It works fine with "group by" clause removed. Looks like CSV does not support group by.
Correct, as specified in the documentation.
Many other DBDs support it. If you're on windows, try DBD::ODBC with the text driver to access your CSV files directly, otherwise you'll need to dump your data into an rdbms. Alternatively, you could accomplish the same effects as a GROUP BY by using several combined queries and/or some perl manipulation.Is there a way that I can do "group by" with CSV or DBD?
--
Jeff
