On Wed, 12 Feb 2014 17:19:08 +0100
Tonton <[email protected]> wrote:

> hello
> 
> i write this in my sub
> 
> my $count_DossiersClos = database('asav')->quick_count(
>             'DossierClos',
>             {DateCloture =>{ 'lt' => "2013-12-01
> 00:00:01"},DateCloture => { 'gt' => "2013-11-01 00:00:01"}});
>                 return $count_DossiersClos;
> 
> but the query just use the last  Date cloture and in mysql.log i read

Yeah - it's a hashref and you're using the same key name twice, that
will never work.

I believe you can say:

{ 
    DateCloture => {
        gt => '2013-11-01 00:00:01',
        lt => '2013-12-01 00:00:01',
    },
}


Cheers

Dave P


-- 
David Precious ("bigpresh") <[email protected]>
http://www.preshweb.co.uk/     www.preshweb.co.uk/twitter
www.preshweb.co.uk/linkedin    www.preshweb.co.uk/facebook
www.preshweb.co.uk/cpan        www.preshweb.co.uk/github


_______________________________________________
dancer-users mailing list
[email protected]
http://lists.preshweb.co.uk/mailman/listinfo/dancer-users

Reply via email to