<% ' made change to query to not pull up any sold houses 7/31/01 ' Property of and written by Adam Ford --> ' UPDATES ' 07.10.02 acf changed query to include the status name for displaying in "Edit A House" list dim intCTID dim bolSecure bolSecure = true if request.cookies("HomeVestorsOfTampaBay")("Level") > 2 Then intCTID = request.cookies("HomeVestorsOfTampaBay")("CTID") else bolSecure = false end if ' Create the SQL statement if bolSecure then strSQL = "SELECT Statuses.Name AS STatus, * FROM Statuses RIGHT JOIN Houses ON Statuses.SID = Houses.SID WHERE CTID=" & intCTID & ";" else strSQL = "SELECT Contacts.Name, Statuses.Name AS Status, * FROM Statuses RIGHT JOIN (Houses LEFT JOIN Contacts ON Houses.CTID = Contacts.CTID) ON Statuses.SID = Houses.SID WHERE (((Houses.SoldDate)>=DateAdd('d',-1,Date()) Or (Houses.SoldDate) Is Null)) ORDER BY Houses.CTID;" end if ' Open a recordset set objRS = objDBConn.execute(strSQL) bolSecure = empty intCTID = empty %>