4 Replies Latest reply on Jun 14, 2014 4:15 AM by MorkAfur

    Simple Data Display Question

    MorkAfur

      Title

      Simple Data Display Question

      Post

           I have a sub-summary report where the calculation field is the one below to give me breaks at the year and month:

           Year (field ) & "/" & Right ("0" & Month (field); 2)

           ----

           So, for example, the report might have sub-summary headings like 2014/05.

           Fine so far. It works.

            

           But, what if instead of displaying the break date as "2014/05", I want to display it as "May, 2014"?

           If I try to update calculation, then the the sub-summary no longer works as expected.

           If I try go to the Data Formatting area in the inspector, nothing is available when I select this field.

           I have this calculation field resolving to a Number. Changing the return type to a date just gives me a "?" in the report.

           ----

           There is probably an easy way to format the date independently of the calculation but I haven't found it. I didn't see anything useful under the main Format menu, for example.

           Thanks in advance,

        • 1. Re: Simple Data Display Question
          philmodjunk

               In your expression, you have:

               Year (field ) & "/" & Right ("0" & Month (field); 2)

               Where field is apparently a date field. If you put that field on your sub summary layout part, you can specify data formatting to get the data display that you describe. you can keep the above calculation field and specify it in your sort order and sub summary layout part to use for grouping your records and use the original date field for display purposes.

          • 2. Re: Simple Data Display Question
            MorkAfur

                 Thanks Phil. Works fine.

                 Yeah, I guess I was a little confused - I thought the calculation field needed to be in the subsummary part for it to work.

                 Upon reflection, no reason why it should since all the grouping happens outside the report.

                 Really appreciate your reply.

                 - m

                 :)

            • 3. Re: Simple Data Display Question
              philmodjunk

                   Here's an alternative method for compute the Year and month for such sorting:

                   Field - Day ( Field ) + 1

                   select date as the result type. This computes the date for the first day of the month for all dates in field that fall in the same month and year. This field could be used both for sub summary grouping and also for "MonthName, Year" display using data formatting.

              • 4. Re: Simple Data Display Question
                MorkAfur

                     Thanks Phil. I've saved this excellent tip for future use.

                     Appreciate your follow up.

                     - m