OLAP Universe MDX functions

Hello experts,
We have a requirement to apply a filter based on report run date in comparison with date objects as follows:
(Report Run Data - 90 days) < System Completion date < Report Run Date
Any any one help me how we can implement this in Conditions at OLAP Universe.
Regards,
Ravi Kumar Garre

Hi,
Here is a document whic lists lost of example.
OLAP universes best practices
[http://www.sdn.sap.com/irj/boc/go/portal/prtroot/docs/library/uuid/c0a45246-ce76-2b10-e688-f5c8206203eb?quicklink=index&overridelayout=true]
Regards,
Bashir Awan

Similar Messages

  • BO XI 3.1 Sp2 OLAP Universe - MDX Function

    Hi all,
    How i tuse MDX Functions in OLAP Universe ?
    Iam getting parse ok in Universe . getting error in while creating webi report

    Hi... i´ve seen that this is a typical question but i think it´s still not solved... I need to use the sentence showed but despite using measures using another dimension. I mean i want to create a new dimension which tell me if it has values or not so i want to create another one and use the function IIF and the sentence more or less like that:
    IIF(ISEMPTY(.[D7LE0EX5IUP5U83WHERK13M48]), 1, 0)</EXPRESSION> - it works
    May i use this sentence with dimension/characteristic values or it only works for measures ? Some idea of how to achieve what i´m looking for ?
    Thanks in advance.
    SAP BW 7.02 SP06
    BO XI 3.1 FP 3.5
    J.Casas

  • Create new object (measure) with IIF function on BW Olap universe:mdx error

    hello
    i have a universe based on a BEX query
    i want to create a new object (a measure) with the IIF(,,) function
    i created the following select:
    <EXPRESSION>IIF(@Select(Currency Type\CurrencyTypeCode)="10",@Select(Key Figures\RevenueGlobalCurrency),@Select(Key Figures\RevenueLocalCurrency))</EXPRESSION>
    defined as number
    where
    CurrencyTypeCode is a dimension (character format)
    RevenueGlobalCurrency and RevenueLocalCurrency are measure (number format)
    i always have a parse which is OK but
    when i want to  use the object on a webi report i always have an MDX error : ...invalid MDX with .... (WIS 10901)
    and advise ?
    Thanks

    Hi Didier,
    Thanks a lot for your help.
    Now it works : i do not understand why
    i explain:
    the correct syntaxe of my new measure is :
    <EXPRESSION>([Measures].[4FVLHG7OAJMNY9WC06X6JLOZQ], [0CURTYPE].[10])</EXPRESSION>
    it does not works with my "L01 currency type" BO dimension
    ([0CURTYPE].[LEVEL01])
    when i had :
    -my universe is based on a BW BEX query
    -my universe has been automaticaly generated with the assistant
    -the Currency Type Class was define as below:
           - 1 BO dimension object : L01 Currency Type =>
    [0CURTYPE].[LEVEL01]
           - 3 BO detail objects : L01 Currency Type techName =>
    [0CURTYPE].[LEVEL01].[TECH_NAME]
                                              L01 Currency Type Key =>
    [0CURTYPE].[LEVEL01].[[20CURTYPE]].[Value]
                                             L01 Currency Type Long Name =>
    [0CURTYPE].[LEVEL01].[[40CURTYPE]].[Value]
    i always had a wrong mdx syntax error on the webi report
    i updated the class with the follow
         - 1 BO dimension object : L01 Currency Type =>
    [0CURTYPE].[LEVEL01] (idem)
           - 3 BO detail objects : L01 Currency Type techName =>
    [0CURTYPE].[LEVEL01].[TECH_NAME]  (idem)
                                              L01 Currency Type Key =>
    [0CURTYPE].[LEVEL01].[NAME] (updated)
                                             L01 Currency Type Long Name =>
    [0CURTYPE].[LEVEL01].[DESCRIPTION] (updated)
    then it was working
    Then i tried to reproduce from scratch and now it also works with the previous version of the class.
    I do not understand anything
    Is there something like a cache file of the MDX query (in RSRT, cache mode is set to inactive for the bex query) ?
    ps: this is the same if a use webi under infoview (java) or webi rich client...
    Edited by: Frederic Nez on Jan 19, 2010 6:35 PM
    (edit : there is mistake in the post : objects are always between [] even if it is not dispay => change objects to code mode)

  • How create filter in olap universe with MDX LIKE Function

    Hi all
    I need to create a filter in a olap universe with the LIKE MDX function.
    Problem:
    There is a dimension with account numbers whit 10 digits like this: 5683492703 and i need to create a filter whit all account numbers whit the number 7 in the sixth position in a olap universe.
    How to do this?
    Thanks all

    Try like this :
    <FILTER KEY="[Level Object Definition]">
         <CONDITION OPERATORCONDITION="Like">
              <CONSTANT CAPTION="_____7*"/>
         </CONDITION>
    </FILTER>
    Not sure if it is _ or ? to represent a single character. Try ? in place of _ if the above code doesn't work.
    Regards

  • How to use parallel period function in olap universe?

    Hi all
    I want to create a ratio with the measure of the last year with the function parallel period in a universe olap. What is the syntaxis for do this ? Thanks

    Hi Didier.
    Thanks for reply
    I have a olap universe and i create a new object with this sentence:
    <EXPRESSION>ParallelPeriod([0CALMONTH].[LEVEL01],1,[0CALMONTH].CurrentMember,(@Select(Ratios\Salidas stk tot caj)))</EXPRESSION>
    When run a query with Rich Client this error appears: (spanish)
    Se produjo un error en la base de datos. El texto de error de la base de datos es: La consulta MDX WITH MEMBER [Measures].[D29E6BC1-5AC0-4245-86,DA,DB,41,D6,CF,B3,52] AS ' ParallelPeriod([0CALMONTH].[LEVEL01],1,[0CALMONTH].CurrentMember,([Measures].[4GPT8D1S01T3MR5EZ57C98LJC])) '  SELECT  { [Measures].[D29E6BC1-5AC0-4245-86,DA,DB,41,D6,CF,B3,52] }  ON COLUMNS , NON EMPTY CROSSJOIN(  { [0PLANT].[0021] } ,  { [0CALMONTH].[201002] }  ) ON ROWS FROM [ZIC_MP01/ZIC_Q01]  no pudo ejecutarse con el error Error desconocido. (WIS 10901)
    What is wrong ??
    Thanks

  • How to use string functions (substr or ltrim or replace)  in OLAP universe.

    cost element (0COSTELMNT) - 10 CHAR
    Controlling area (0CO_AREA) - 4 CHAR
    [0COSTELMNT].[LEVEL01].[[20COSTELMNT]].[Value]
    cOST ELEMENT is compounded/prefixed with Controlling Area. I just want to see cost element without conrolling area in the BO report.
    Currenlty BO unierse is build based on bex query. I am able to suppress the compounding object in bex query by chaning controlling area to 'No display'. But still BO Webi report displaying compounded values in the report. (Bex report works as expected)
    eg: Current display in reort.
    controlling area/cost element.
    AB00/2222
    AB00/2223
    AB00/2224
    Wanted like  below:
    2222
    2223
    2224
    I think by using string fucntions (substring, ltrim or  replace etc.), I can get the required result. But I am having issues with syntax. I have used like below.
    substr(0COSTELMNT ; 5 ; 10)
    substr(0COSTELMNT; 5 ; Length(0COSTELMNT)-5)
    substr(0COSTELMNT; Pos(0COSTELMNT;"/")+1;10)
    ltrim(0COSTELMNT,'AB00/')
    What is the syntax for substring/replace functions in OLAP universe. Technical name of cost element in OLAP  universe is [0COSTELMNT].[LEVEL01].[[20COSTELMNT]].[Value].
    I want to fix this at universe level not at report level as  i am using cost element in filter/variable section of the report. Please provide me syntax for above example.

    Hi,
    In fact SAP BW MDX supports limited string manipulation and only with NAME and UNIQUENAME attributes.
    Here are some samples that you can use in universes:
    MID([0COSTELMNT].currentmember.NAME,1,4)
    LEFT([0COSTELMNT].currentmember.NAME,2)
    RIGHT([0COSTELMNT].currentmember.NAME,3)
    MID([0COSTELMNT].currentmember.UNIQUENAME ,1,4)
    LEFT([0COSTELMNT].currentmember.UNIQUENAME ,2)
    RIGHT([0COSTELMNT].currentmember.UNIQUENAME ,3)
    Didier

  • Can we Implement YTD using MDX syntax in olap universe.

    Hi,
    I am trying to implement YTD prompt from universe level. Can any one suggest how can i implement it using MDX syntax in olap universe.
    Regards,
    Anil Kumar.

    Hi,
    In MDX, you need to generate the technical name to have you expression valid.
    Moreover the correct syntax is: SUM(MTD(member),measure)
    So in your case the prompt must be constrained on the technical name and cannot be free, the correct syntax is:
    <EXPRESSION> SUM(MTD(@Prompt('YYYYMM','A','Cal. year / month\L01 Cal. year / month',mono,primary_key)),
    @(Select(Key Figures\Total Variance)) </EXPRESSION>
    Last, the result will be not really significant because you are asking for a MTD with a Year-Month as time member: the result will be the measure value for the selected month.
    In your case you need to have a time series function for an upper level like YTD or QTD. If you want to use MTD, the the time member selected would be at a lowest level, such as week or day.
    Regards
    Didier

  • Errors in MDX function of Universe and WebI

    Dear Experts,
    I need to create a object get MTD, YTD of PS volume measure in Universe get data from Cube in SAP Business Warehouse.I have been tried to do many time and based on OLAP Universe best practice document from Ingo Hilgefort but it still generates errors.
    <EXPRESSION> SUM(MTD([0CALMONTH].[LEVEL01].CurrentMember, @Select(PS Volume\PS Volume))) </EXPRESSION>
    --> generate error
    A database error occured. The database error text is:
    The MDX query WITH MEMBER [Measures].
    [C6F14DED-1942-4F00-8F,88,E6,F3,3] AS
    SUM(MTD[0CALMONTH].[LEVEL01].CUurrentMember),
    [Measures].[ZPS_VOL])'SELECT {[Measures]...} ON COLUMNS FROM [$ZSD_C01]
    <EXPRESSION> SUM(MTD([0CALMONTH].CurrentMember), @Select(PS Volume\PS Volume)) </EXPRESSION>
    --> generate error
    A database error occured. The database error text is:
    (cs) "Driver not capable". (WIS 10901)
    With simple fomular, system run ok
    <EXPRESSION> @Select(PS Volume\PS Volume) - @Select(PS Return Volume\PS Return Volume) </EXPRESSION>
    --> OK
    We use system:
    SAP EHP 1 for SAP NetWeaver 7.0 SP8
    BOBJ Edge 3.1 SP3 with Standard Package
    SAP Integration Kits 3.x
    Could experts help me to solve that problem?
    Thanks & Regards,
    Jack Luu

    Hi,
    This is a big task and can't really be explained too well in a post. But here's the short version of the process you must follow:
    1. In the information design tool, convert your old (unv format) universes to the new (unx) format and save them to the repository. This will create a new universe.
    2. In each Webi report, go to the query panel and switch the report from looking at the old universe to the new universe. Assuming you're not making any changes to the universe all the objects will match and it will just work.
    Chapter three of the information design tool manual is dedicated to converting old universes to new.
    Changing the universe that a Webi report uses is in the Webi manual, it isn't specific to a BI4.0 migration.
    As far as I know, it isn't possible to convert OLAP universes.
    Lastly, I'd suggest making sure you're using BI4.0 SP01 - the information design tool seems to have quite a few things ironed out.
    For a fast intro into the information design tool, you can [have a look at this|http://blog.davidg.com.au/2011/04/bi40-information-design-tool.html].
    Hope that helps!

  • MDX OLAP Universe does not allow for a Top 10 rank on measure.

    Hello!
    I am trying to Rank a measure by Top 10 in count on a MDX OLAP universe based on Web Intelligence. The rank works, however for all the zeros in the row values it gives the same rank and keeps on appending. I then tried to rank a measure with the MDX syntax in the SELECT statement of the measure itself. The syntax is as below:
    <EXPRESSION>Rank([0MATERIAL__0MATL_GROUP].[LEVEL01].CurrentMember,
    Order([0MATERIAL__0MATL_GROUP].[LEVEL01].CurrentMember.Level.Members
    @Select(Exp Dem (Published)\Exp Dem (Published)),
    @Prompt(u2018Top orBottomu2019,u2019Nu2019,{u2018DESCu2019,u2019ASCu2019},mono,constrained) ) )</EXPRESSION>
    The XML is parsed because of the tags, however when using this measure in the query panel gives an error message for the prompt. Is there a way to rank a measure by Top 10 in the MDX statement above instead of the prompt for the Top/Bottom. I found the syntax in the OLAP Best practices guide.
    Kindly revert for any possible solution. Any inputs are highly appreciated.
    Thanks in advance!
    Regards,
    Vivek.
    P.S.: I am specifically looking to Rank multiple measures by Top 10 count without displaying zeros / repetetive values.

    Hi Ingo!
    Thank you for responding! I have gone through the OLAP Universe best practices as suggested by the guide. However, the Ranking has an offset of repeating the ranks for same value metrics. So if I need a Top 10 and there are 3 zero values in the column, the ranking extends to Top 13. is there any way to hardcode this as a predefined filter in the Universe on the measure, which states that the rank stays limited to Top 10 irrespective of repeating values?
    Kindly suggest if there is a work around for this!
    Thanks in advance!
    Regards,
    Vivek.

  • Problem in WEBI Report with PCM OLAP Universe (PCM MDX Connector)

    We need to create reports in Web Intelligence from our PCM Models (Business Objects Profitability and Cost Management). We are able to create the olap universe using PCM MDX Connector and we have no problems creating the reports in webi. The problem is when we execute the report (run query): all the data from PCM model is loaded correctly (dimensions, levels, etc.), except the Measures. I mean, the values of all the measures are always zero (0). No matter the way we change the query (adding filters, adding or chopping dimensions, drilling levels, etc.) the value for every measure is zero.
    We've checked the aggretation method of each measure in BO universe designer and are all correctly configured.
    The model in PCM is calculated and even when we run the queries in PCM Model Builder tool directly to the model, the results are retrieved Ok and the measures have correct values (Revenue, lineitem values, etc.).
    Any ideas of what is going on?

    Hi Henry… thanks for your answer…
    The reports we are creating of PCM are not from BW universes, but PCM OLAP Universes. PCM have its own cube OLAP files, and BO universes for those OLAP models use the Business Objects PCM MDX Driver.
    Nevertheless I will try to catch the MDX statement, as you suggest, and see if something is wrong with it.
    The versions we have are: “Business Objects Enterprise 12.3 build 601” and “Business Objects Profitability and Cost Management (PCM) 7.5.11”
    Thanks again.
    Vladimir.

  • OLAP Universes - Based on BEx Query - Month and Previous Month Functions

    Hi,
      I created a Universe based on SAP BEx queries and I like to create a filter so that I use in Web Intelligence report to run for "Previous Month" data always. There are "Date" filelds in BEx Query(No Month info only date data). I have no knowledge of SAP BEx Queries and new to OLAP universes. Could you help.
    How to create filter that show Previous Month.
    Nanda Kishore
    Edited by: Nanda Kishore B on Dec 26, 2010 6:15 AM

    The easiest way  (but NOT the most efficient one) is to create a local variable (Dimension) in your report with the following code:
    =if (Month(CurrentDate())=1 AND Month([[MyDate]])=12 AND Year([[MyDate]])=(Year(CurrentDate())-1)) OR (Month(CurrentDate())>1 AND   Month([[MyDate]])=(Month(CurrentDate())-1)) then 1 else 0
    where MyDate is the field from your query containing the data information
    Activate the report filter area in your report design panel by pressing the Report filter icon and drag and drop your variable there and apply it to the entire report. Filter value 1 and you will get the data for the previous month.
    Keep in mind that this approach is not optimal especially if you do have many rows of data delivered to your WebI report because filtering takes place only AFTER the data is retrieved. The Best practice here is to work with BEx variables.
    How many rows of data does your WebI report normally fetches?
    Regards,
    Stratos

  • "Count" MDX function in Universe based on SAP BW 7.1 Multiprovider

    Hi,
       I am creating a mesure in Universe using "Count".  If I use measure directly, I get "Multivalue" error. Do you know why.
    Help text reads folowing: COUNT ( " Set "    ,  EXCLUDEEMPTY     ) count number of cells in a set, optionally including or excluding empty cells.
    The following is the syntax in my universe : COUNT(.[0ACTION_Count]).
    OLAP Guides by Didier MAZOUÉ has the following syntax is Count(.Members)  or Count(.[LEVEL01].Members). This is for Dimension, but my object is already a measure (One of the Key figure and * data is at lowest level for an employee and my purpose is to show summary for a period/month or Country or city Using Count*) how should I change the syntax. What is the "Set" . Could you help me with Syntax. This is my first Universe.
    Regards,
    Nanda Kishore

    Hi everybody,
    we are discussing about that fact in another thread.
    I would appreciate if you join the discussion under:
    OLAP universes and Crystal Reports
    Thank you for any comments
    Sebastian

  • Edit an object's select statement of OLAP universe SAP BW

    Hi everybody
    I am new at working with Olap Universes BW, and I have to edit one universe SAP BW, I don't know if I can to use substring function on a select statement, for example  substring([0D_DIV].[LEVEL01],5,5), I try to use this function but I have a error,
    Could you help me? I need to returns part of a string, is correct to do it on a universe or is better to do at BW.

    Hi,
    First of all I recommend you read the documentation that gives you information about OLAP universes and especially SAP BW universes.
    I also recommend to download documents related to SAP universes deployment, administration and customization:
    [OLAP Universes - how to samples and recommendations |https://wiki.wdf.sap.corp/wiki/display/globalregions/OLAPUniverses-howtosamplesand+recommendations]
    [SAP Integration |https://wiki.wdf.sap.corp/wiki/display/globalregions/SAP+Integration]
    Now you can customize expression using MDX in OLAP universes. MDX expressions must be enclosed with <EXPRESSION></EXPRESSION> XML tags.
    Unfortunately SAP BW MDX does not support calculations that return string or date values.
    The onlyway to return string is to use NAME or UNOIQUENAME attribute.
    See answers I already in the forum: [Forum answer |Re: Create new dimension on top of SAP BW data]
    Regards
    Didier

  • Olap universe(creating new object)

    All,
    I am using bo 4.0 version and i have created an olap universe on top of bex query.i am new to olap universe.
    I have a need to create a new customized object in my olap universe out of two existing objects.As of now i am creating variables in my webi report generated out of the olap universe to fit my need.Instead i want to create a condition object or some kind of object in the universe itself.
    how can i do this?Any ideas or suggestions.
    For ex:
    my requirement looks like this,not exactly the same as indicated below but similar.
    existing objects
    city object has certain values 'hyd','new york'
    currency objecthas 'rupee','dollar'
    new person object out of the above mentioned existing objects
    if city='hyd' and currency='rupee' then 'indian' else 'non indian'
    how can i do this?Any ideas or suggestions.
    Regards,
    Reji.
    Edited by: reji2011 on Dec 7, 2011 11:10 PM

    Hi,
    there's a function builder / formula editor in Universe Designer, with OLAP universes this uses MDX syntax with XML markup.
    to build up some logic, you need to use the "IIF" operator.
    regards,
    H
    p.s.  in BI 4.0,   route-one should be the BICS BEx connection, not the OLAP .unv ..

  • Remove leading zeros using MDX function

    Hello,
    BO XI R3.1 SP2 FP2.5, SAP BW 7.0
    This seems simple, but I cannot find a solution.
    How do I remove leading zeros from a character field in a OLAP universe. Is there any MDX function?
    I tried
    <EXPRESSION>
    Value([0MATERIAL].[LEVEL01].[[20MATERIAL]].[Value])
    </EXPRESSION>
    <EXPRESSION>
    StrToValue([0MATERIAL].[LEVEL01].[[20MATERIAL]].[Value])
    </EXPRESSION>
    I can remove the leading zeros in Webi, but we require it for ad-hoc reporting? Is there a way to do this in the universe?
    Thanks,
    Nikhil

    Hi,
    SAP BW MDX only allows calcuated expressions that return numeric values: this is one if the main SAP MDX limitations.
    By the way there is the abilitiy to return string only for those expressions:
    [Dimension].currentmember.name
    [Dimension].currentmember.uniquename
    So you can do this:
    <EXPRESSION>
    (right([0MATERIAL].currentmember.name, 4))
    </EXPRESSION>
    <EXPRESSION>
    (right([0MATERIAL].currentmember.uniquename, 4))
    </EXPRESSION>
    <EXPRESSION>
    (left([0MATERIAL].currentmember.name, 3))
    </EXPRESSION>
    <EXPRESSION>
    (left([0MATERIAL].currentmember.uniquename, 3))
    </EXPRESSION>
    Otherwise you can use WebI formulas as described in the thread.
    Regards
    Didier

Maybe you are looking for