This is my code to build the recordset...
<%
Dim rsResults
Dim rsResults_numRows
Set rsResults = Server.CreateObject("ADODB.Recordset")
rsResults.ActiveConnection = MM_GenKAccess_STRING
rsResults.Source = "SELECT GenKStock.OrderNo, GenKStock.SingleArtist,
GenKStock.SoftHard, GenKStock.Category, GenKStock.Type,
GenKStock.Label, GenKStock.Description, GenKStock.Manuf,
GenKTitles.ItemNumber, GenKTitles.Title, GenKTitles.Artist,
GenKTitles.mp3Files FROM GenKStock INNER JOIN GenKTitles ON
GenKStock.OrderNo = GenKTitles.ItemNumber WHERE ( " &
ReplaceThis("GenKTitles.Title") & " LIKE '%' + '" +
ReplaceThis(rsResults__T) + "' + '%') AND (GenKTitles.Artist LIKE
'%' + '" + Replace(rsResults__A, "'", "''") + "' + '%') AND
(GenKStock.Category LIKE '" + Replace(rsResults__C, "'", "''") + "')
AND (GenKStock.Manuf LIKE '" + Replace(rsResults__M, "'", "''") + "')
AND (GenKStock.Type LIKE '" + Replace(rsResults__TY, "'", "''") + "')
AND (GenKStock.SingleArtist LIKE '" + Replace(rsResults__SA, "'",
"''") + "') ORDER BY " + Replace(rsResults__sql_orderby, "'", "''")
+ ""
rsResults.CursorType = 0
rsResults.CursorLocation = 2
rsResults.LockType = 1
rsResults.Open()
rsResults_numRows = 0
%>
Then, down in the HTML I have this code: SQL = <%=rsResults.Source%>
Which gives me this: SQL = SELECT GenKStock.OrderNo,
GenKStock.SingleArtist, GenKStock.SoftHard, GenKStock.Category,
GenKStock.Type, GenKStock.Label, GenKStock.Description,
GenKStock.Manuf, GenKTitles.ItemNumber, GenKTitles.Title,
GenKTitles.Artist, GenKTitles.mp3Files FROM GenKStock INNER JOIN
GenKTitles ON GenKStock.OrderNo = GenKTitles.ItemNumber WHERE (
GENKTITLES.TITLE LIKE '%' + 'AINT' + '%') AND (GenKTitles.Artist LIKE
'%' + '%' + '%') AND (GenKStock.Category LIKE '%') AND
(GenKStock.Manuf LIKE '%') AND (GenKStock.Type LIKE '%') AND
(GenKStock.SingleArtist LIKE '%') ORDER BY OrderNo ASC
Response.write SQL gives me nothing because there is no variable
named SQL. This is response.write SQL: <%=Response.Write(SQL)%>
(gives me no results) Sorry if I don't understand what you want.