0

I am trying to generate a dataset for reporting in our wave analytics (Einstein Analytics) app. The source for this data will be an object in salesforce however I need to transform this data for the purpose of our reporting. I need to transform it as follows -

A record in my target object has the following fields - Start Date, End Date, Total Amount. I need this data transformed in such a manner that this one record is expanded into as many records as the no. of days between start date and end date while the amount is pro rated.

For Example - 1 Existing Record - {Start Date : 1st Aug 2017; End Date : 5th Aug 2017; Total Amount : 50}

After the transformation, I should get 5 records each for 1 date in the date range like -

  • Record 1 {Start Date : 1st Aug 2017; End Date : 1st Aug 2017; Total Amount : 10}
  • Record 2 {Start Date : 2nd Aug 2017; End Date : 2nd Aug 2017; Total Amount : 10}

  • Record 3 {Start Date : 3rd Aug 2017; End Date : 3rd Aug 2017; Total Amount : 10}

  • Record 4 {Start Date : 4th Aug 2017; End Date : 4th Aug 2017; Total Amount : 10}
  • Record 5 {Start Date : 5th Aug 2017; End Date : 5th Aug 2017; Total Amount : 10}

Is such a data transformation even possible in wave ?

2 Answers 2

0

You can do this using compute function of data flow or bucket field of recipes by definition.As of my knowledge, i am unfamiliar with bucket field but you can achieve this by compute function of dataflow if you have a saql query that can achieve this

1
  • Actually such a transformation is not feasible on the analytics platform. We confirmed this with the product specialist @ SF. We ended up running this transformation externally and then pushing the data into the analytics app.
    – Vic
    Nov 11, 2017 at 8:27
0

If your still looking and considering above example.

create a compute expression calculate the date difference between startdate and enddate. and divide it with the amount so you individual amount.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .