Minggu, 08 September 2013

Re: [MS_AccessPros] Error 3061 Too Few Parameters

 

Duane,
I have tried different variations (=, <,>) that should change the data but nothing is having any impact.  It appears that entire WHERE section of the statement is just being ignored, but not throwing any error message.


On Sun, Sep 8, 2013 at 2:00 PM, Duane Hookom <duanehookom@hotmail.com> wrote:
 

I believe you are missing the delimiters around your date value

 strSQL = "SELECT * FROM [diagnosis] WHERE (CDate(StartDate))>#" & DateOfVisit & "#"

Duane Hookom MVP
MS Access

________________________________
> To: MS_Access_Professionals@yahoogroups.com
> From: patty.mapes@gmail.com
> Date: Sun, 8 Sep 2013 12:09:31 -0400

> Subject: [MS_AccessPros] Error 3061 Too Few Parameters
>
>
>
> I have the following code, failing on the last line:
>
>
> DateOfVisit = CDate(Forms!Select_Diagnosis![VisitList])
>
>
> Set db = CurrentDb
> Set rs = db.OpenRecordset(Domain)
> 'select all events
>
> strSQL = "SELECT * FROM [diagnosis] WHERE (CDate(StartDate))>" &
> DateOfVisit
>
>
> If someone can see my error, I will be very grateful.
>
> Thank you,
>
> Patty
> --
> Patricia Mapes




--
Patricia Mapes

__._,_.___
Reply via web post Reply to sender Reply to group Start a New Topic Messages in this topic (6)
Recent Activity:
.

__,_._,___

Tidak ada komentar:

Posting Komentar