I have an ASP page with a recordset and a grid. I have form variables being posted from another page. I am taking those values and trying to set the recordset SQL text before the recordset is opened and display results in the grid. <BR><BR>Sub rsResults_onbeforeopen()<BR> Dim sSQL <BR> sSQL = "SELECT tblAsbuiltServer.HouseNumber, tblAsbuiltServer.StreetPreDir, tblAsbuiltServer.StreetName, "_<BR> & "tblAsbuiltServer.StreetType, tblAsbuiltServer.StreetPostDir, tblCities.City, tblState.StateAbbreviation, "_ <BR> & "tblAsbuiltServer.StreetCode, tblAsbuiltServer.MapNumber, tblAsbuiltServer.DateScanned, "_<BR> & "tblAsbuiltServer.FileName FROM tblAsbuiltServer " _<BR> & "INNER JOIN (tblState INNER JOIN tblCities ON tblState.State_ID = tblCities.State_ID) ON tblAsbuiltServer.CityID = tblCities.City_ID " _<BR> & "WHERE "<BR><BR>Select Case Request.Form ("lstSelect")<BR> Case "SL"<BR> If Request.Form ("txtHouse1") &#060;&#062; "" then<BR> sSQL = sSQL & sAnd & "HouseNumber LIKE &#039%" & Request.Form ("txtHouse1") & "%&#039"<BR> sAnd = " AND " <BR> End if<BR> If Request.Form ("txtHouse1") = "" then<BR> sSQL = sSQL & sAnd & "HouseNumber IS NOT NULL"<BR> sAnd = " AND "<BR> End if<BR> If Request.Form ("txtHouse1") = "" then<BR> sSQL = sSQL & sAnd & "HouseNumber &#060;&#062; &#039X&#039"<BR> sAnd = " AND " <BR> End if<BR> If Request.Form ("txtStreet1") &#060;&#062; "" then<BR> sSQL = sSQL & sAnd & "StreetName LIKE &#039%" & Request.Form ("txtStreet1") & "%&#039"<BR> sAnd = " AND "<BR> End if<BR> If Request.Form ("lstCity1") &#060;&#062; "" then<BR> sSQL = sSQL & sAnd & "CityID = " & Request.Form ("lstCity1") <BR> sAnd = " AND "<BR> End if<BR> If Request.Form ("lstState") &#060;&#062; "" then<BR> sSQL = sSQL & sAnd & "StateID = " & Request.Form ("lstState")<BR> sAnd = " AND "<BR> End if<BR> If Request.Form ("txtMapNumber") &#060;&#062; "" then<BR> sSQL = sSQL & sAnd & "MapNumber LIKE &#039%" & Request.Form ("txtMapNumber") & "%&#039"<BR> End if<BR> sSQL = Trim(sSQL) & ";"<BR> rsResults.setSQLText(sSQL)<BR>End Select<BR>End Sub<BR><BR>The recordset properties are set to automatically open, and it has the basic SQL statement that I used in sSQL above. The problem with this is that when I page through the results in the grid I only get one page with "true" results. The first page shows the correct results as set with the SQL text from my code. However, if I try to page through it goes back to the original recordset properties SQL statement. <BR><BR>I have tried to disable the automatic open and open the recordset using rsResults.open (), and then I get an error in the recordset.asp(acting like it is already open). I have also tried to test for if the recordset is open then close and then I get an ODBC error or a blank screen. I have also tried Session Variables instead of Form Variables. <BR><BR>Any help would be appreciated. Even suggestions for other methods or places I might look.<BR><BR>THANKS!!