[Dbix-class] DBIx HAVING and COUNT error
Len Jaffe
lenjaffe at jaffesystems.com
Tue Sep 6 17:34:08 GMT 2016
On Tue, Sep 6, 2016 at 5:01 AM, Dagfinn Ilmari Mannsåker <ilmari at ilmari.org>
wrote:
> Len Jaffe <lenjaffe at jaffesystems.com> writes:
>
> > On Sun, Sep 4, 2016 at 11:13 PM, Rajeev Prasad <rp.neuli at yahoo.com>
> wrote:
> >> having => { 'count 1' => $tCount },
> > having => { 'count(1)' => $tCount },
>
> That breaks if you enable name quoting, as the hash keys are interpreted
> as column names. You can use the arrayrefref syntax for arbitrary SQL
> with placeholders:
>
> having => \['count(1) = ?', $tCount ],
>
Yup. My point however was the lack of valid 'count' syntax in the having
has key/value.
--
Len Jaffe - Information Technology Smoke Jumper - lenjaffe at jaffesystems.com
614-404-4214 @LenJaffe <https://www.twitter.com/lenJaffe>
www.lenjaffe.com
Host of Code Jam Columbus <http://www.meetup.com/techlifecolumbus/> -
@CodeJamCMH <https://www.twitter.com/CodeJamCMH>
Curator of Advent Planet <http://www.lenjaffe.com/AdventPlanet/> - An
Aggregation of Online Advent Calendars.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.scsys.co.uk/pipermail/dbix-class/attachments/20160906/cc93fd6b/attachment.htm>
More information about the DBIx-Class
mailing list