#4 MDX for [Membername].Levels(2) is not unparsed by toMdx()

closed-fixed
nobody
None
5
2008-03-17
2007-06-30
Hans Baier
No

When parsing an mdx query like
"SELECT {[Measures].[Risikowert]} ON COLUMNS,
Descendants([Ursachenkategorie], [Ursachenkategorie].Levels(2.0)) ON ROWS FROM [BcsOrIm]"

, the part Levels(2.0) is not unparsed.

To fix it, I added a case clause like that

switch (syntacticType) {
@@ -135,6 +135,15 @@
sb.append(function);
break;

+ case TypeMethod:
+ sb.append(args[0].toMdx());
+ sb.append(".");
+ sb.append(function);
+ sb.append("(");
+ sb.append(args[1].toMdx());
+ sb.append(")");
+ break;
+
default :
System.out.println("unexpected FunCall syntatic type");

That does the trick.

Discussion

  • Hans Baier
    Hans Baier
    2007-06-30

    Logged In: YES
    user_id=1666622
    Originator: YES

    P.S.: The patch refers to the file src/java/com/tonbeller/jpivot/olap/mdxparse/FunCall.java

     
  • Andreas Voss
    Andreas Voss
    2008-03-17

    • status: open --> closed-fixed