Re: count_search_where deleting its parameters ?

[prev] [thread] [next] [Date index for 2005/01/08]

From: merlyn (Randal L. Schwartz)
Subject: Re: count_search_where deleting its parameters ?
Date: 07:27 on 08 Jan 2005
>>>>> "Gabor" == Gabor Szabo <gabor@xxxx.xxx.xx> writes:

Gabor>     age <= 80 AND age >= 20 AND city = Jerusalem

Gabor> In SQL::Abstract I can do this by
Gabor> $sql = SQL::Abstract->new(logic => 'and');

Gabor> print $sql->where([
Gabor>      age  => {'<=', 80},
Gabor>      age  => {'=>', 20},
Gabor>      city => 'Jerusalem',
Gabor>      ]), "\n";

I solved this by using a hash with funny keys:

where({
  age => {'>=', 20},
  ' age' => {'<=', 80},
  city => 'Jerusalem',
});

Yeah, it's hacky, but it works fine.

        -- 
        Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777 0095
<merlyn@xxxxxxxxxx.xxx> <URL:http://www.stonehenge.com/merlyn/>
Perl/Unix/security consulting, Technical writing, Comedy, etc. etc.
See PerlTraining.Stonehenge.com for onsite and open-enrollment Perl training!

count_search_where deleting its parameters ?
Gabor Szabo 07:03 on 08 Jan 2005

Re: count_search_where deleting its parameters ?
merlyn (Randal L. Schwartz) 07:27 on 08 Jan 2005

Generated at 12:15 on 16 Jan 2005 by mariachi v0.52