![]() | |
![]() |
| | Thread Tools | Display Modes |
#1
| |||
| |||
|
#2
| |||
| |||
|
|
I have two dimensions: "CRM Date" ( Time Dimension down to the day ) and "CRM Client Opportunity". If a client opportunity is "active", it gets an entry of certain values for that day. I want to determine how long each opportunity has been active at any point in time. Ex: Opp 1 started on Nov. 10 and ends on Nov 20. If I select Nov 15, the opporunity has been active for 5 days. If I select Nov, the results shuold be 0 since the opporuntiy is not active at the end of november. I can't seem to isolate the set of data I want to use. I tried cross joining all the opportunites with the ClosingPeriod, but then I always get a duration of 1 since there is only one day. I also thought of using VBA to subtract the first date from the current date. But I can't seem to isolate the value of the "first date" to plug into a vba function. It's also getting very slow: TopCount( NonEmptyCrossJoin( {Descendants([CRM Client Opportunity].CurrentMember, [CRM Client Opportunity].[Opportunity Description],LEAVES )}, {Descendants([CRM Date].AllMembers, [CRM Date].[Day] )} ) , 1 ) .Item(0).Item(1) Any ideas??? |
![]() |
| Thread Tools | |
| Display Modes | |
| |