View Full Version : Can someone verify this line of code?

01-04-2007, 11:31 PM
Hello all. I have a line of code that is giving me an error, although the results are still working fine.

Here is the error:

ADODB.Command error '800a0bb9'

Arguments are of the wrong type, are out of acceptable range, or are in conflict with one another.

/rpts/pm/pm_bl_gen.asp, line 28

"SELECT Count (*) AS Total_Gen FROM tbl_wo WHERE (tbl_wo.RequestDate Between #10/1/" & cFY3 & "# And #10/31/" & cFY3 & "#) AND (tbl_wo.WoType = 'PMBC')"

I know is has something to do with the concantenation of the MM/DD/ with the variable of the year, but I am confused on the correction.

BTW, this is an Access DB.

Thanks in advance,


01-05-2007, 03:27 PM
I have to say, everytime i've come across that error, it's becuase I've forgotten to include my adovbs.inc file or my conn.open was pointing to the wrong strSQL, etc...

Otherwise, break up your query, search for 1 thing, then 2 and keep going until you find the error.

Good luck

01-05-2007, 03:44 PM
You know, you were right. See, this file was an <!--Include--> file, and the parent document is the one that had the connection string. So, I was testing just by going directly to this page. Although, it now let me know that I do have a syntax issue with my dates. ;o)

Thank you so much for your insight.


01-05-2007, 05:02 PM
No problem, done it many times myself.