From: Paul S. <p.s...@gm...> - 2012-02-14 13:00:05
|
Hi, I've been discussing this a while ago and now I really need to move forward with this. I need to be able to select the RETURN columns in a drillthrough mdx (especially multiple measures) in olap4j. the mondrian.olap.DrillThrough already supports the syntax for RETURN but it seems like its completely ignored by mondrian. basically i need to be able to execute something like: DRILLTHROUGH MAXROWS 5 SELECT ({[Gender].[F]} * {[Marital Status].[M]}) ON COLUMNS FROM [Sales] RETURN [Measures].[Profit Growth], [Measures].[Customer Count], [Gender].[Gender] so my issues are: 1) At the moment mondrian seems to execute this query but then ignore the return list completely. 2) Also when i have multiple measures in the return list i get a parser exception, although this should be possible according to SSAS (http://msdn.microsoft.com/en-us/library/ms345125%28v=sql.90%29.aspx) I know that tab fields is deprecated but I think it would be a good idea to implement this in a similar fashion When the drill through SQL is generated and there is a list of RETURN columns, translate the members in that list to column names and put those in the SQL select. Maybe it would be enough to add to MondrianOlap4jStatement. java line 93 : cell.drillThroughInternal() the following for the tabfields parameter: convertToTabFields(drillthrough.getReturnList()) now in that method we only need to convert the measures / levels into sql I understand we can just use the level key and for measures I'm not so sure. I'm happy to implement this if I can get a few pointers! Thanks! -Paul |