Dates (Full Version)

All Forums >> [Web Development] >> ASP and Database



Message


TAMAJAMA -> Dates (3/9/2001 17:22:00)

Spooky and friends; You have got to be sick of hearing questions about date fields, but even after looking through previous posts, I was unable to find any information on this specific problem. Here's my code.
fp_sQry="SELECT * FROM ALLTESTS WHERE (((ALLTESTS.TESTDATE) Between Date() And DateAdd(""m"",-3,Date())))"
No default is set up. (I don't think I need a default)
It is bringing up this error when displayed in my browser: Database Results Error
Description: [Microsoft][ODBC Microsoft Access Driver] Too few parameters. Expected 1.
Number: -2147217904 (0x80040E10)
Source: Microsoft OLE DB Provider for ODBC Drivers

I did not do this page using the DRW. I pulled it from my SQL view in my Access query which is working fine in my database. I tested it in a new page with the DRW as a custom query and it verifies the connection. I am assuming my code is incorrect somewhere. I will continue to work with it, but I feel like I'm at a dead end here. I've tried all of the ways I know of. Any help is greatly appreciated.
Thanks!!!!





Spooky -> RE: Dates (3/9/2001 23:26:00)

Try this one :

"SELECT * FROM ALLTESTS WHERE (((ALLTESTS.TESTDATE) Between Date() And DateAdd('m',-3,Date())))"


------------------
Spooky
"I am Spooky of Borg. Prepare to be assimilated, babycakes!"
Subscribe to OutFront News
Database / DRW Q & A
The Spooky Login!





TAMAJAMA -> RE: Dates (3/13/2001 15:44:00)

Spooky,
That worked perfectly, THANKS! Your login system works great by the way!!! Once I dug in and looked at how it all worked together I was a little humbled at how much these ASP pages can do that I have NO knowledge of. I'm learning though.

------------------
Don't treat me any differently than you would the queen





Spooky -> RE: Dates (3/13/2001 16:02:00)

Everyones been there at one stage or another. Curiousity is one of the requirements when coding, otherwise youd never ever consider trying to find how it works, or find a better way.
For everything else theres frontpage....




Page: [1]

Valid CSS!




Forum Software © ASPPlayground.NET Advanced Edition 2.4.5 ANSI
4.736328E-02