Results 1 to 2 of 2
  1. #1
    Join Date
    Mar 2004

    Unanswered: summing by date on a subform

    I am still working on a form that displays timekeeping information. My challenge is this: I have a form that contains a subform where a user will enter timekeeping information. The data fields are:

    [PIN] (this is the pk)

    I want to have a subtotal of hours by date display on the form so that as they are entering time, they can get a running total of the hours.

    I added a sum[(Hours]) field to the footer of the subform and display it on my main form which works nicely, but I would like to somehow display this by date. So, if the record selected on the subform has a date value of 8/17/04, then the hours summed up would be for only 8/17/04. I think I need an IIf statement of some kind, but do not know the syntax.

    Any advise is greatly appreciated.

    Thank you.

  2. #2
    Join Date
    Sep 2003
    SELECT SUM([Hours]) AS SumOfHours FROM InsertTableNameHere WHERE ([Date]=#DateTxtGoesHere#);
    Back to Access ... ADO is not the way to go for speed ...

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts