Trouble in calculated column over date range

sandipsatale

New Member
Joined
Feb 26, 2014
Messages
3
I have two date columns in one table

Coolumn Hears : Activity|City|Start_Date|End_Date

Row 1 : A1|C1|01/01/2014|05/01/2014

Row 2 : A1|C1|06/01/2014|07/01/2014

Row 3: A2|C2|06/01/2014|07/01/2014

Row 4: A3|C3|03/01/2014|04/01/2014

Expected output like - If user selects date range 02/01/2014 to 07/01/2014

Column Header

City | #StartCount| #EndCount

Row 1 : C1 | 1 | 2

Row 2 : C2 | 1 | 1

Row 2 : C3 | 1 | 1

Here #StartCount is
- Need to grouped by City.
- Its Count of Distinct Activity
- It should consider date boundries as : All activity for which start date 'greater or equeal(>=)' Input Start date and (less than '<') End Date

Here #EndCount is
- Need to grouped by City.
- Its Count of Distinct Activity
- It should consider date boundries as : All activity for which Ends date 'Less or equeal(<=)' Input End date and (Greater than '>') End Date

Could you please suggest me expression to be used for such case.
Calculated measure or dax can be used..
 

Excel Facts

Which lookup functions find a value equal or greater than the lookup value?
MATCH uses -1 to find larger value (lookup table must be sorted ZA). XLOOKUP uses 1 to find values greater and does not need to be sorted.

Forum statistics

Threads
1,223,986
Messages
6,175,788
Members
452,670
Latest member
nogarth

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top