The Solution
Nov. 2nd, 2004 11:13 amIf you were waiting on tenterhooks for me to figure out what the problem was with the script in the last post, it was one of those "Well, duh!" things. I had two nested SQL queries, and while I was focused on the second query because that was throwing the error, the problem was that the first query had 0 results, so of course the second query wouldn't create a recordset object because there were no criteria from the first query results to use. Adding an IF NOT .. ELSE .. END IF statement around it and moving the objRS2.Close statement inside the IF statement cleared up that problem.
Telophase's List of ASP Coding Errors to Check For So Far:
-- Typos
-- Parentheses and quotation marks in the correct order
-- ELSE statement actually present in IF .. ELSE .. END IF statements
-- Function and subroutine results go into variable with same name as function or subroutine
-- Using "&_" to join separate lines in SQL statements
new-- Nested SQL queries
I like that I almost always make the same errors. I've got a mental list of about ten things I screw up on in PHP and what their results are, and 95% of the time, checking for them results in the script working.
Telophase's List of ASP Coding Errors to Check For So Far:
-- Typos
-- Parentheses and quotation marks in the correct order
-- ELSE statement actually present in IF .. ELSE .. END IF statements
-- Function and subroutine results go into variable with same name as function or subroutine
-- Using "&_" to join separate lines in SQL statements
new-- Nested SQL queries
I like that I almost always make the same errors. I've got a mental list of about ten things I screw up on in PHP and what their results are, and 95% of the time, checking for them results in the script working.