# How to use transforms for Serial Differencing Aggregation

**URL:** <https://discuss.elastic.co/t/how-to-use-transforms-for-serial-differencing-aggregation/222135>\
**Category:** Elasticsearch\
**Created:** [March 4, 2020, 6:00pm UTC](https://discuss.elastic.co/t/how-to-use-transforms-for-serial-differencing-aggregation/222135 "2020-03-04T18:00:56Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![tusharumbarkar](https://avatars.discourse-cdn.com/v4/letter/t/8e7dd6/32.png) [@tusharumbarkar](https://discuss.elastic.co/u/tusharumbarkar)\
**Post date:** [March 4, 2020, 6:00pm UTC](https://discuss.elastic.co/t/how-to-use-transforms-for-serial-differencing-aggregation/222135/1 "2020-03-04T18:00:56Z")

</div>

I am trying to create new index using transforms (with the Serial Differencing Aggregation)

Got below error -

{  
"statusCode": 400,  
"error": "Bad Request",  
"message": "[status\_exception] Unsupported aggregation type [date\_histogram]",  
"cause": [  
"Unsupported aggregation type [date\_histogram]"  
]  
}

Any other way of doing this ?

 ![transform_error](https://us1.discourse-cdn.com/elastic/original/3X/6/4/64ecd7ec06dd37eee2653f9f92328554ddf8343b.png)

---

<div class="post-metadata">

**Author:** ![Hendrik\_Muhs](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/hendrik_muhs/32/25802_2.png) [@Hendrik\_Muhs](https://discuss.elastic.co/u/Hendrik_Muhs)\
**Post date:** [March 5, 2020, 8:15am UTC](https://discuss.elastic.co/t/how-to-use-transforms-for-serial-differencing-aggregation/222135/2 "2020-03-05T08:15:27Z")

</div>

Hi,

date\_histogram is not support as aggregation in transform yet but only as part of `group_by`. In your config in the screenshot you specify date\_histogram twice, however the definition is `group_by` is all you need.

More problematic regarding support is `serial_diff`, which is a pipeline aggregation. Pipeline aggregations do not fit with the paging logic we internally use in transform. The necessary previous bucket might be in the previous page and therefore inaccessible for the current page. In this usecase this might be solvable, but for other pipeline aggregation its not that easy. We might work on a solution for this, but I do not see this anytime soon, because of complex problems.

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [April 2, 2020, 8:15am UTC](https://discuss.elastic.co/t/how-to-use-transforms-for-serial-differencing-aggregation/222135/3 "2020-04-02T08:15:30Z")

</div>

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.
