[thelist] ASP/TSQL/UID

Chris Marsh chris at webbtech.co.uk
Wed Oct 2 11:12:01 CDT 2002


Dear all

I am having a peculiar problem executing some SQL through an ASP script.
The statement is:

strSQL = "SELECT agendasinfo_text, agendasinfo_isheading FROM
agendasinfo WHERE agendasinfo_agenda_id = '" & Request.QueryString("id")
& "'"

Response.Write this to a web page, and I have:

SELECT agendasinfo_text, agendasinfo_isheading FROM agendasinfo WHERE
agendasinfo_agenda_id = '{1A2B6434-F383-4F18-A25D-C5F2FBBCB433}'

Copy this and paste to Query Analyser and I get the expected (and
required) output. However, run it from the ASP script...

If Not objRS.BOF And objRS.EOF Then
	While Not objRS.EOF
		...
	Wend
End If

...and it doesn't make it past the initial condition, as the recordset
contains no data. From what I've said, am I making a stupid error, or is
there more to it?

Many thanks in advance.

Regards

Chris Marsh





More information about the thelist mailing list