Skip to main content

I created a Pivot field, and for some reason, the calculation is displaying wrong only for the month of September.

 

The calculation for the date is as follows:

DATE(IF NOT ISNULL( DATEPARSE ( "MMM yyyy", [Pivot Field Names] ) ) THEN DATEPARSE ( "MMM yyyy", [Pivot Field Names] )  ELSEIF NOT ISNULL ( DATEPARSE ( "'Sept' yyyy", [Pivot Field Names] ) ) THEN DATEPARSE ( "'Sept' yyyy", [Pivot Field Names] )  END)

 

The Pivot details are as follows:

Calculation from a pivot field displays the wrong date for only one monthI've tried remaking the calculation to see if there was a glitch, however, the same results appeared again, with the field "Sept 2022" being turned into 1/1/2022.

 

I appreciate any advice/help on resolving the matter.

1 risposta
  1. 7 ott 2022, 16:58

    @kirby hunter​ not sure what you are trying to achieve here but your calc field will not work like that. DATEPARSE() is a datafunction to convert the string formatted date to an actual date. So DATEPARSE('DateFormat', PivotFIeldNames) where Dateformat is how your field values are coming so if it Sep 2022 then DateFormat should be like

    DATEPARSE('MMM yyyy', PivotFieldValues) you cannot give "'Sep' yyyy" which will not work I believe. Share some sample data or .twbx file to have a closer look and also your expected output.

0/9000