[ic] search query
Philip S. Hempel
interchange-users@icdevgroup.org
Thu May 22 17:56:00 2003
On Thu, 2003-05-22 at 17:40, Philip S. Hempel wrote:
> On Thu, 2003-05-22 at 15:38, Stefan Hornburg wrote:
> > On 22 May 2003 14:56:56 -0400
> > "Philip S. Hempel" <pshempel@linuxhardcore.com> wrote:
> >
> > > I am trying to get a search to function like the sql query below does
> > >
> > > SELECT `page` FROM `tree` WHERE 1 AND `mgroup` = 'Products' AND
> > > `msort` = '0' AND `page` != ' '
> > >
<snip>
> > > [loop
> > > search="
> > > fi=tree
> > > st=db
> > > tf=sort
> > > ac=0
> > > ac=0
> > > co=yes
> > >
> > > sf=page
> > > op=ne
> > > se= <<- this is where I am lost how do you describe null or empty?
> > >
> > > sf=msort
> > > se=0
> > > op=rm
> > >
> > > sf=mgroup
> > > se=Products
> > >
> > > "]
> > >
> > > ====
> > >
> > > The goal is to not return on field "page" being empty.
> >
> > What about op=rm se=\S ?
> >
>
> For some reason it only returns a few areas that have data in them. I
> would have to think that there are non-white space characters in the
> fields that are not returned.
>
> If there was a term to just say something like the user tags do in using
> the if statement i.e. if-loop-field do something it would be a little
> easier.
> > >
<snip>
> >
> > http://www.icdevgroup.org/i/dev/docfly.html?mv_arg=icdatabase06%2e04
Now tell me why both
op=rm
se=\W
or se=\S
return the same results.
Now using se=\A (match only on the beginning of a string) works giving
me the results I am looking for.
I thought that \A required a string to process and never thought of
using it till now.
So what is the deal with the match, is it a default to match anything at
the beginning then?
Thanks, and appreciate your tolerance with my ignorance of regular
expressions. These things I have yet to get down pat.
--
Philip S. Hempel
debian/rules
http://linuxhardcore.com/