Quantcast
Channel: SCN : Discussion List - SAP BusinessObjects Web Intelligence
Viewing all articles
Browse latest Browse all 5402

How to calculate counts from different dates into 1 date

$
0
0

Hi,

 

I have a scenario below

 

IDTypeCountryDate
123AP1PUS1/1/2009
123A1AWO

4/4/2010

123A2

AUS6/6/2011
123A3AUS8/8/2011

 

So, the logic I need to display is -

 

If, Type = P AND Country=US then count 1 where ID has 123AP1

else If Type = A AND Country=US then count 1 more where ID has 123AP1 on date 1/1/2009 (i.e. on Type P date)

 

So, result should show

 

IDTypeCountryDateCount
123AP1PUS

1/1/2009

3
123A1AWO4/4/20100
123A2AUS6/6/2011
123A3AUS8/8/2011

Viewing all articles
Browse latest Browse all 5402

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>