Welcome to SPN

Register and Join the most happening forum of Sikh community & intellectuals from around the world.

Sign Up Now!

Displaying Max Date on a Report

Discussion in 'Information Technology' started by DV, Jul 28, 2006.

  1. DV

    DV
    Expand Collapse
    Guest

    How do I display a max date on a report on a group header. The report is
    based on a query that returns multiple dates for the the header value. I
    would even like to display both the min and max date value on the report.
     
  2. Loading...

    Similar Threads Forum Date
    Heritage Canadian art gallery displaying Sikh Maharaja Ranjit Singh’s throne History of Sikhism Nov 27, 2010
    General Max Arthur Macauliffe History of Sikhism Sep 4, 2013
    SciTech Mammals pick offspring’s sex to maximize number of grandchildren, study shows Breaking News Jul 11, 2013
    Events Year 2013 is centennial to honour max arthur macauliffe History of Sikhism May 8, 2013
    Sikhi To The Max developers Information Technology Mar 26, 2013

  3. Ofer Cohen

    Ofer Cohen
    Expand Collapse
    Guest

    You can use this in the control source of the field
    Max Date

    =DMax("[DateFieldName]","[QueryName]")

    And, Min date
    =DMin("[DateFieldName]","[QueryName]")

    --
    Good Luck
    BS"D


    "DV" wrote:

    > How do I display a max date on a report on a group header. The report is
    > based on a query that returns multiple dates for the the header value. I
    > would even like to display both the min and max date value on the report.
     
  4. DV

    DV
    Expand Collapse
    Guest

    Thanks, that worked. Can I add a grouping to match the report? Right now
    it's returning the max date for the entire query.

    "Ofer Cohen" wrote:

    > You can use this in the control source of the field
    > Max Date
    >
    > =DMax("[DateFieldName]","[QueryName]")
    >
    > And, Min date
    > =DMin("[DateFieldName]","[QueryName]")
    >
    > --
    > Good Luck
    > BS"D
    >
    >
    > "DV" wrote:
    >
    > > How do I display a max date on a report on a group header. The report is
    > > based on a query that returns multiple dates for the the header value. I
    > > would even like to display both the min and max date value on the report.
     
  5. Ofer Cohen

    Ofer Cohen
    Expand Collapse
    Guest

    Yes, you'll need to pass the group number as a criteria

    If the Group field is text, then
    =DMax("[DateFieldName]","[QueryName]","[GroupNumberInQuery] = '" &
    [GroupNumber] & "'")

    If the Group field is number, then
    =DMax("[DateFieldName]","[QueryName]","[GroupNumberInQuery] = " &
    [GroupNumber])


    --
    Good Luck
    BS"D


    "DV" wrote:

    > Thanks, that worked. Can I add a grouping to match the report? Right now
    > it's returning the max date for the entire query.
    >
    > "Ofer Cohen" wrote:
    >
    > > You can use this in the control source of the field
    > > Max Date
    > >
    > > =DMax("[DateFieldName]","[QueryName]")
    > >
    > > And, Min date
    > > =DMin("[DateFieldName]","[QueryName]")
    > >
    > > --
    > > Good Luck
    > > BS"D
    > >
    > >
    > > "DV" wrote:
    > >
    > > > How do I display a max date on a report on a group header. The report is
    > > > based on a query that returns multiple dates for the the header value. I
    > > > would even like to display both the min and max date value on the report.
     

Share This Page