[Dbix-class] using distinct and literal SQL in select list does not work

BUCHMULLER Norbert norbi.lists at nix.hu
Thu Oct 16 08:08:06 BST 2008


On Wed, 15 Oct 2008 23:42:43 +0200 Hartmaier Alexander
<Alexander.Hartmaier at t-systems.at> wrote:

> And again confusion because dbic's as doesn't do a sql as...
> dbic's as is to name the column for a
> $row->get_column('your_colname_specified_by_as') call, it doesn't
> insert 'as' into the sql query. To do that look at the dbic docs.

Yes, I know that, and I didn't confuse it. Please read carefully my
original post. (It was Marc who suggested using the 'as' attribute of
DBIC as he misunderstood my problem, then I explained why it does
not help in my case.)

In fact, I looked at the DBIC docs many times, and did exactly what they
recommended (ie. putting the SQL 'AS' in literal SQL, as explained in
http://search.cpan.org/~ash/DBIx-Class-0.08010/lib/DBIx/Class/ResultSet.pm#as),
and *that* lead to the problem I reported.

norbi



More information about the DBIx-Class mailing list