Yikes this is driving me crazy
ASP, VBScript, IIS 6, Access
I have a page that inserts into two tables. One table is
ClientsW and the
other is Eligibility, they are related by the Casenum field
that is the
primary key in both tables and they are linked.
I have one recordset that inserts into the ClientsW table
called rsClients.
I have another recordset that inserts into the Eligibility
table called
rsEligibility. After the insert I requery the ClientsW table
and set the
Session variable to the autonumber that is in the CASENUM
field like so:
rsEligibility.Update
rsClients.Update
rsClients.Requery
Session("UserID")=rsClients("CASENUM")
response.redirect "done1.asp"
Then I redirect to another page. On that page I set up two
recordsets to
pull from the two tables that information was just inserted
into. The
Session ID seems to work for the rsClients recordset and
pulls from the
ClientsW table, but the second recordset, rsEligibility that
pulls out of
the Eligibility table doesn't pull anything! It is in there,
but I can't
get it out. Again, this works in IIS 5, but not IIS 6. What
do I have to
do to get the information to pull from the Eligibility table
according to
the Casenum field which is the same in the ClientsW table? Is
there any
help out there?
<%@LANGUAGE="VBSCRIPT"%>
<!--#include file="Connections/connNewdatabase.asp" -->
<%
Dim rsClients__svuserid
rsClients__svuserid = "0"
if (Session("UserID") <> "") then rsClients__svuserid =
Session("UserID")
%>
<%
set rsClients = Server.CreateObject("ADODB.Recordset")
rsClients.ActiveConnection = MM_connNewdatabase_STRING
rsClients.Source = "SELECT * FROM CLIENTSW WHERE CASENUM=" +
Replace(rsClients__svuserid, "'", "''") + " ORDER BY CASENUM"
rsClients.CursorType = 0
rsClients.CursorLocation = 2
rsClients.LockType = 3
rsClients.Open()
rsClients_numRows = 0
%>
<%
Dim rsEligibility__svuserid
rsEligibility_svuserid="0"
if(Session("UserID")<>"") then rsEligibility__svuserid
= Session("UserID")
%>
<%
set rsEligibility = Server.CreateObject("ADODB.Recordset")
rsEligibility.ActiveConnection = MM_connNewdatabase_STRING
rsEligibility.Source = "SELECT * FROM ELIGIBILITY WHERE
CASENUM=" +
Replace(rsEligibility__svuserid, "'", "''") + " ORDER BY
Casenum"
rsEligibility.CursorType = 0
rsEligibility.CursorLocation = 2
rsEligibility.LockType = 3
rsEligibility.Open()
rsEligibility_numRows = 0
%>