Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

DSum with two criteria

Status
Not open for further replies.

Fireman1143

IS-IT--Management
Mar 5, 2002
51
US
I am trying to write a DSum ststement to track days off for employees. I have the following:
DSum("[VSCount]","tblVacSickEmp","[VSEmpID]="& [Me].[EmplID]

My second criteria is to be >=[Me].[AnnivesaryDate] but I am having a problem adding it to the above. Suggestions?

Thanks,
Fireman1143
 
How are ya Fireman1143 . . .

Perhaps this:
Code:
[blue]DSum("[VSCount]","tblVacSickEmp","[VSEmpID]=" & [Me].[EmplID] & " AND [Date]>=# " & [Me].[AnnivesaryDate] & "#")[/blue]

Calvin.gif
See Ya! . . . . . .
 

Thank you very much, TheAceMan1

I worked on the syntax for two days and you had it posted for me within 20 minutes!

The only mod I had to make was removing the [Me]. as I had that wrong in my post. Have a Happ and Safe New Year,

Fireman1143
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top