i need help in a query formula in access 2010

i wrote this code
Winter2011: DSum("sum","invoicesandinvoiceszikuilist1q","customer=" & [customerid] & " AND orderdate> #09/01/10# AND <=#03/31/11#")

and all the field names are right but when i add this part from " AND orderdate> ,,,, and i run this query the all column written "error"  but i can't figure out what is the problem with this
bill201Asked:
Who is Participating?
 
kingjelyConnect With a Mentor Commented:

Try this

AND orderdate between '#09/01/10#' AND '#03/31/11#' ")

0
 
bill201Author Commented:
it's worked (but i don't has to use the apostrophes
juse like this Winter2011: DSum("sum","invoicesandinvoiceszikuilist1q","customer=" & [customerid] & "  AND orderdate between #09/01/10# AND #03/31/11# ")
0
 
kingjelyCommented:
Ahh okay cool,

sometimes you need the ' ' depends how the date is stored.

Glad to help,
Thanks for the grade :)
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.