Hi Rob,
thanks for taking the time, here's the code again.
Craig
SELECT subID, org, LEFT(describe,86) AS intro, name1, addrs,
town, cat,
catsub
FROM subs
WHERE ((cat = MMColParam AND catsub = MMSub) OR (org LIKE
MMLtr%) OR (org
LIKE %MMFreet% OR name1 LIKE '%MMFreet%' OR town LIKE
'%MMFreet%') AND
show=-1)
ORDER BY org
<%
Dim rsDir
Dim rsDir_cmd
Dim rsDir_numRows
Set rsDir_cmd = Server.CreateObject ("ADODB.Command")
rsDir_cmd.ActiveConnection = MM_connNorth_STRING
rsDir_cmd.CommandText = "SELECT subID, org, LEFT(describe,86)
AS intro,
name1, addrs, town, cat, catsub FROM subs WHERE ((cat = ? AND
catsub = ?) OR
(org LIKE ?) OR (org LIKE ? OR name1 LIKE '%MMFreet%' OR town
LIKE
'%MMFreet%') AND show=-1) ORDER BY org"
rsDir_cmd.Prepared = true
rsDir_cmd.Parameters.Append
rsDir_cmd.CreateParameter("param1", 5, 1, -1,
rsDir__MMColParam) ' adDouble
rsDir_cmd.Parameters.Append
rsDir_cmd.CreateParameter("param2", 5, 1, -1,
rsDir__MMSub) ' adDouble
rsDir_cmd.Parameters.Append
rsDir_cmd.CreateParameter("param3", 200, 1, 255,
rsDir__MMLtr + "%") ' adVarChar
rsDir_cmd.Parameters.Append
rsDir_cmd.CreateParameter("param4", 200, 1, 255,
"%" + rsDir__MMFreet + "%") ' adVarChar
Set rsDir = rsDir_cmd.Execute
rsDir_numRows = 0
%>
"RobGT" <rob@lighthouseuk.removeme.net> wrote in
message
news:e8glgn$8i9$1@forums.macromedia.com...
> Hi Craig,
> Can you post your latest SQL (include the whole
recordset) code again here
> please - I have lost the original post from my
newsreader.
>
> Cheers,
> Rob
>
http://robgt.com/ [Tutorials and
Extensions]
> Firebox stuff:
http://robgt.com/firebox
> Skype stuff:
http://robgt.com/skype
> Dell stuff:
http://robgt.com/dell
> SatNav stuff:
http://robgt.com/satnav
>
>