Welcome to SPN

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

Sign Up Now!

Date format conversions

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

  1. MarkusJohn

    MarkusJohn
    Expand Collapse
    Guest

    I need an expanded date format for my report. --> September 2006

    In my table dates are stored in tt.mm.yy format.
    I want to display in the report groups of months.

    How can I convert all same months and year dates into the format mm.yy?

    I alreade wrote month ([date1]) in the query but this results only the
    month number.

    Thanks for any help!
     
  2. Loading...


  3. Rick Brandt

    Rick Brandt
    Expand Collapse
    Guest

    "MarkusJohn" <john.m@gmx.net> wrote in message
    news:1149345487.241035.319060@g10g2000cwb.googlegroups.com...
    >I need an expanded date format for my report. --> September 2006
    >
    > In my table dates are stored in tt.mm.yy format.
    > I want to display in the report groups of months.
    >
    > How can I convert all same months and year dates into the format mm.yy?
    >
    > I alreade wrote month ([date1]) in the query but this results only the
    > month number.
    >
    > Thanks for any help!


    Dates are always *stored* exactly the same. Formatting is strictly a display
    issue.

    On your report's TextBox use a format property of...

    mmmm yyyy

    --
    Rick Brandt, Microsoft Access MVP
    Email (as appropriate) to...
    RBrandt at Hunter dot com
     
  4. John Vinson

    John Vinson
    Expand Collapse
    Guest

    On 3 Jun 2006 07:38:07 -0700, "MarkusJohn" <john.m@gmx.net> wrote:

    >I need an expanded date format for my report. --> September 2006
    >
    >In my table dates are stored in tt.mm.yy format.


    Not unless you have them stored in a Text field. A Date/Time field is
    actually stored as a number (a count of days and fractions of a day
    from midnight, December 30, 1899); the format is JUST for display
    purposes.

    >I want to display in the report groups of months.


    You can set the Format property of a report Textbox to mmmm yyyy. If
    you wish to *group by* the month, you'll need to base the Report on a
    Query with a calculated field converting the date into a text string:

    ShowMonth: Format([datefield], "yyyymm")

    Use this field for your Sorting and Grouping property of the Report
    (you needn't show it on the report); it will sort chronologically.

    John W. Vinson[MVP]
     

Share This Page