Per replicare tanti blocchi
codice:
(T1,(clragsoc,clkeys), 'pizzeria')AS t
in base a quante parole sono presenti nella ricerca dovresti fare così:
codice:
<%
testo = trim(request.form("testo"))
if inStr(testo," ") > 0 then
elementiTesto = split(testo," ")
for i = 0 to uBound(elementiTesto)
stringa = stringa & "(T1,(clragsoc,clkeys), '" & replace(elementiTesto(i),"'","''") & "')AS t "
if i < uBound(elementiTesto) then stringa = stringa & "OR "
next
else
stringa = "(T1,(clragsoc,clkeys), '" & replace(testo,"'","''") & "')AS t "
end if
query = "SELECT T1.clid, T1.clragsoc ,T1.clattivita , t.Rank " &_
"FROM T1 AS T1 " &_
"INNER JOIN " &_
"CONTAINSTABLE" &_
"" & stringa &_
"ON T1.clid = t.[Key] " &_
"ORDER BY t.Rank desc"
%>
Ovviamente è un esempio.