1 Reply Latest reply on Dec 13, 2017 12:35 PM by syama tunuguntla

    the month function not available on non-aggregate data source- odbc on spark

    syama tunuguntla

      HI

       

      i have a field YYYY-MM-DD data type and i need the functionality of trending like showing data by quarters/months etc. so just used DATE function to convert it date field and tableau recognized the new field as well but still it does not show quarters/months once i use the drop down on the new field.

       

      i get this error message- the function not available on non-aggregate data source . the aggregate could be any thing ex:month(datefield)

       

      Thanks in advance

      ST

        • 1. Re: the month function not available on non-aggregate data source- odbc on spark
          syama tunuguntla

          well it looks like there is a support issue for a lot of date aggregate function in Databricks/spark with Hadoop Parquet table format.

           

          so the fix/hack that worked are

           

          1. use extract not live connection

          2. it makes sense to have a live connection if you are using the spark environment. so the fix was extract years, months and write a formula to calculate quarters and use them. working good how i wanted.

           

          a 3rd option is have separate fields in db itself like quarters.

           

          my fix for now is use option 2. when db fields are created then use them.

           

          thanks

          st