Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Only display the current month

Status
Not open for further replies.

jrkrish

Technical User
Jan 21, 2002
11
0
0
US
snapshot dates (as of date is the member) is one of the shared dimension in the MSAS. When we use that in the CAR report, I want ONLY the most recent "as of date" to display when I open the report. How should I do that? Is there a formula I can write..
 
If you just want the current calendar month, then
Code:
Month({your.date) = Month(currentdate)

[yinyang] Madawc Williams (East Anglia, UK) [yinyang]
 
Typically you'd group by the member, and then use maximum({table.date},{table.member}).

-k
 
Thanks Madwac and Syna for your suggestions. Actually both of the suggestions are not working. Let me explain in detail for the better understanding of the problem. OLAP cube is MSAS and reporting tool BO OLAP XI(OLAPI). I have a shared dimension in the snapshot date and members will be one date in each month. Every the cube will get updated and for example today I can see the snapshot date member as 9/25/2005 in the member selector (only one date in each month you can see, bcos it is snapshot) (of the reporting tool)and tomorrow I will be seeing 9/26/2005 as a snapshot date for this month. When the top management folks open the report they have to manually select the date from the member selector and display the report. They want to see only the latest date and qty information for that date in the report when they open it. This should be automated something like this.

Alloc avail
snapshot date Products Business units qty qty

9/26/20005 xxxxx xxxxxxx 2500 456

Please suggest me the best possible ways to achieve this..

Thanks.
 
As synapsevampire said, you should be able to do it using Maximum Date within a a suitable group. Either a summary total or a running total.

Right-click on a field and choose Insert to get a choice of Running Total or Summary. Or else use the Field Explorer, the icon that is a grid-like box, to add running totals.

Running totals allow you to do clever things with grouping and formulas. They also accumulate for each line, hence the name. The disadvantage is that they are working out at the same time as the Crystal report formats the line. You cannot test for their values until after the details have been printed. You can show them in the group footer but not the group header, where they will be zero if you are resetting them for each group.

Summary totals are cruder, but are based directly on the data. This means that they can be shown in the header. They can also be used to sort groups, or to suppress them. Suppress a group if it has less than three members, say. They default to 'Grand Total', but also can be for a group.

[yinyang] Madawc Williams (East Anglia, UK) [yinyang]
[yinyang] Windows XP & Crystal 10 [yinyang]
 
Sorry if I have misled you. But as I mentioned in my previous thread, I am using OLAPI tool for the report not the CR.
 
If you are prepared to do the work on the MSAS side then make the snapshot date the default member of that dimension. Then make OLAPI use the default member in that report.
 
As OliverS says, you can use the default member option in the member selector.
The other way would be to prompt for that member using the parameters options available. This way you can select when you view the report as to which period you actually want to show
 
Which makes me think of another possibility.

Assuming you can pass the parameters from csp, then you could write some cunning CSP that resolves the parameters at the point they access the report. You would need a custom management console to generate the parameter values so I don't know how easily that would fit in with your system.

I have a feeling that it is possible to pass parameters through either the session cookie or the query string in the URL. (Note that that is from a vague memory of a conversation with some Crystal people a couple of years ago so could be wrong). Now what I can't remember is whether you could also pass parameter values through the command line to CAPro, that would be nice as it gives you a thick client solution as well (with some judicious scripting).
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top