Question
I am trying to use the $AND variable inside a search statement but cannot get it to properly retrieve the results. The search works when I use one variable but I do not know how/where to add the &AND statement to search on the second variable and the first variable and return the results. Here is what I am using(with hardcoded conditional):
***Click Edit below to view the query statement***
%SEARCH{ "[R]esourceContinent.*(value\=).*Africa" type="regex" web="Reporters", -TWiki, -Main, -Trash"
scope="text" casesensitive="off" regex="on" nonoise="on" nototal="on" nosearch="on"
format="$formfield(ResourceName)"
<div class='WebsBodyLink'><a href='%SCRIPTURLPATH{view}%/$web/WebHome'>
<em></em></a></div>, <nop>)\"}%
But when I try to add a second variable to search with it returns no results although it should return 1.
Thanks in advance!
Environment
--
ZachGrieshop - 16 Oct 2007
Answer
If you answer a question - or have a question you asked answered by someone - please remember to edit the page and set the status to answered. The status is in a drop-down list below the edit box.
Did you try
";" as the AND separator? Taking your example:
%SEARCH{
"FORM\:FIELD.*[R]esourceContinent.*value\=.*Africa;FORM\:FIELD.*OtherFieldvalue\=.*Anything"
type="regex"
web="Reporters"
scope="text"
regex="on"
nonoise="on"
format="$formfield(ResourceName)"
}%
See
VarSEARCH and
FormattedSearch.
--
PeterThoeny - 16 Oct 2007