Re: Abstract Search question

[prev] [thread] [next] [Date index for 2004/12/22]

From: Andrew Hartford
Subject: Re: Abstract Search question
Date: 15:16 on 22 Dec 2004
On Wednesday 22 December 2004 02:41 am, Peter Speltz wrote:
> To clarify, i'm talking about being able to write statement like this:
> my @objs = $class->search_where( { A => 'tom',
>                                    B => 'huck',
>                                    C => 'jim' } ,
>                                   { logic => [ 'AND', 'OR'] } );
>  and this would generate the:
> WHERE A = ? and (B = ? or C = ?) .
>
> So every time you need 'logic' you shift one off if size > 1 or use the one

Thanks for the reply Peter! That would be a nice way to express that. I'm 
going to ping the author on this and see what he says.

I was expecting to be able to use the normal syntax where items in a hash are 
and'ed together, and supply a special string for the key of the nested or'ed 
expression. Like this:

{ A => 'tom', NEST => [{B => 'huck'}, {C => 'jim'}] } # NEST is keyword so the 
arrayref isn't interpreted as a modified parameter expression.

Andy

(message missing)

Abstract Search question
Andrew Hartford 23:13 on 21 Dec 2004

Re: Abstract Search question
Peter Speltz 07:22 on 22 Dec 2004

Re: Abstract Search question
Peter Speltz 07:41 on 22 Dec 2004

Re: Abstract Search question
Andrew Hartford 15:16 on 22 Dec 2004

Re: Abstract Search question
Andrew Hartford 18:46 on 22 Dec 2004

Re: Abstract Search question
Peter Speltz 18:56 on 22 Dec 2004

Re: Abstract Search question
Andrew Hartford 15:21 on 23 Dec 2004

Re: Abstract Search question
Tim Bunce 16:39 on 23 Dec 2004

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