This won't mean anything to 99% of you, but I finally cracked a problem with our SQL queries to the catalog at work. We've parameterized them using ADO Command objects to help stop SQL injection attacks, and were having a bitch of a time connecting to the catalog with some SELECT queries, which would fail with an "Invalid use of default parameter" error.
Turns out the problem lies in sending a parameter without a value. When working in classic ASP, VBscript automagically puts in a
special null called DBnull in those cases, which causes
SQL Server (eta: Oracle, in this case, actually) to freak out. You have to
explicitly rename it to null (strVariable = null). Solution found
here.
I had no clue there were different types of nulls. I mean, it's a
null!
(Most of you, if you read all the way through that, are now thoroughly confused, but maybe it'll eventually help someone who's Googling the problem. :D)