jasonsalas
IS-IT--Management
Hi everyone,
Just a quick query...I've been meaning to pass multiple parameter values in a stored procedure ("queries" in Access) with the following syntax:
Dim SQL, objConn, objRS
SQL = "spStory"
Set objConn = Server.CreateObject("ADODB.Connection"
objConn.Open "dsn=DSN;uid=USERNAME;pwd=PASSWORD;"
Set objRS = Server.CreateObject("ADODB.Recordset"
objRS.Open SQL,objConn
...where "spStory" takes a number of values from a previous page to generate a detail page based on various criteria, such as AUTHOR, DATE, and TOPIC(s).
I can do this with a single parameters, using the following:
SQL = "spStory '" & Request.QueryString("ArticleID" & "'"
...but I'd like to incorporate more values. If I concatenate more REQUEST.QUERYSTRING statements, the whole thing comes out as one long string, which doesn't produce anything at all.
How are parameters delimited in this fashion? Commas? Semi-colons?
Thanks!
Just a quick query...I've been meaning to pass multiple parameter values in a stored procedure ("queries" in Access) with the following syntax:
Dim SQL, objConn, objRS
SQL = "spStory"
Set objConn = Server.CreateObject("ADODB.Connection"
objConn.Open "dsn=DSN;uid=USERNAME;pwd=PASSWORD;"
Set objRS = Server.CreateObject("ADODB.Recordset"
objRS.Open SQL,objConn
...where "spStory" takes a number of values from a previous page to generate a detail page based on various criteria, such as AUTHOR, DATE, and TOPIC(s).
I can do this with a single parameters, using the following:
SQL = "spStory '" & Request.QueryString("ArticleID" & "'"
...but I'd like to incorporate more values. If I concatenate more REQUEST.QUERYSTRING statements, the whole thing comes out as one long string, which doesn't produce anything at all.
How are parameters delimited in this fashion? Commas? Semi-colons?
Thanks!