[thelist] Arrgggggg

Norman Beresford Norman at pigfe.freeserve.co.uk
Thu Jun 29 08:24:23 CDT 2000


Hi all

Got another one of those oh so frustrating hairpulling problems which I'd
love someone to help me with.

I'm generating the following SQL query from the following ASP

SELECT * FROM productTable WHERE productID = 354 OR productVarient = 354
Order by productColour;

ItemRef = mainProductID
SQLText = "SELECT * FROM productTable WHERE productID = " & ItemRef & " OR
productVarient = " & ItemRef & " Order by productColour;"
response.write SQLText & "<BR>"
Set oRs = Server.CreateObject("ADODB.RecordSet")
oRs.Open SQLText, "kusun1", adOpenStatic,,adCmdText
response.write "Number of records returned = " & oRs.RecordCount & "<BR>"
oRs.MoveFirst

Now the problem is that while the query in Access returns 5 records the
oRs.RecordCount gives me "1", has anyone got any ideas?

Any help will be more then gratefully received

Norman







More information about the thelist mailing list