aggregation builder

Hi all,
My problem are What should to do? if want to build aggregation builder with “If-Condition”? and another one is DateDiff in aggregation Builder seem not working.

Thank you

CHANANRA