View Single Post
  #1  
Old December 10th, 2008, 12:05 PM posted to microsoft.public.access.tablesdbdesign
Tom
external usenet poster
 
Posts: 1,359
Default dcount syntax help

I have a databse with a table called Expenses. In that table I have a field
calles Vendors which is a text field and a field called Cost which is a
currency field.
I need to count the number of times that for example something was purchaed
from Walmart so I used the syntax
=dcount("[Vendor]","Expenses","[Vendor]='Walmart'") and that works

my problem is with multiple conditions
I need to count the number of times the vendor was walmart and the cost was
more than $400.00

I tried
=dcount("[Vendor]",'Expenses",'[Vendor='Walmart' AND [Cost]'$400.00'') and
all I get is an error any suggestions would be most appreciated . Thanks is
advance

Tom