Automation of assigning Substitution Variable Values

Hi All,
I have 3 substitution variables with values in my server as follows:
Prev Month - "January"
Curr Month - "February"
Next Month - "March"
I want to automate the assigning of values to the substitution variables so that in the next month, the values change automatically as follows:
Prev Month - "February"
Curr Month - "March"
Next Month - "April"
Is there any way available to accomplish the above task.
Any help appreciated.
Thanks,
Raja

Ditto Sean V. Except the date logic I built into a Perl script. So basically one answer is to use your favorite scripting/programming language to do the date manipulation and either pass to a MAXL script as a variable, or to build the MAXL script dynamically

Similar Messages

  • Sharing complex substitution variable values between ASO and BSO databases

    We have ASO and BSO Essbase database member names with spaces in, and need to store some of these member names in substitution variables. However, this has to be done differently for ASO and BSO, due to calc script syntax requiring double quotes and MDX requiring square brackets. For example:
    ASO:
    &CurWeek value = Week 1
    MDX: [&CurWeek]
    BSO:
    &CurWeek value = "Week 1"
    Calc Script: &CurWeek
    As a result, the substitution variables cannot be shared between the ASO and BSO cubes, since the BSO variable value requires double quotes due to the space in the member name.
    Is there a way to get the above to work with both ASO and BSO? Can the double quotes be escaped in calc script syntax? Or can the double quotes be removed in the MDX formula?

    Hi TimG,
    Apologies for such a late reponse to this, genuinely haven't had a spare second to reply until now!
    Yes, I suspect a complex alias name may be the best solution here, and to remove the spaces from the actual member names.
    I was not aware of the latter part at all. My colleague has confirmed as much on this too - DBAG 11.1.2.1 pp117 & 118:
    "Note: If a substitution variable value is numeric or a member name starting with a
    numeral or containing the special characters referred to above is to be used both
    in MDX and non-MDX situations, create two substitution variables, one without
    the value enclosed in quotation marks and one with the value in quotation marks."
    "To ensure that a new substitution variable value is available in formulas, partition definitions,
    and security filters, stop and restart the application. All other uses of substitution variables are
    dynamically resolved when used."
    This last paragraph is the most concerning since we were planning to be able to update substitution variables values and then access the new values from calc scripts and formulae instantaneously. This quirk is unexpected and a little inconvenient. We may have to look at scheduling a change of substitution variable value overnight, followed by a stop/start of the app ready for the next day, and to work around needing to access changed values instantly.

  • Changing Substitution Variables - Value takes time to appear in Planning

    Hi,
    I have an issue with changing substitution variables values. When I do it, Planning takes about 5 minutes to "know" about that change and till then, it continues working with the previous value. Any Idea of how I can solve that?

    Hi,
    By default, each substitution variable is retrieved and cached from the Essbase server every five minutes or 300 seconds). You can change the retrieval interval by adding the SUBST_VAR_CACHE_LIFETIME property and setting its value in seconds.
    To set Planning application or system properties:
    1. Select Administration, then Manage Properties.
    2. Select:
    *Application Properties: set properties for the current application.
    * System Properties: set properties for all Planning applications.
    3. To:
    * Change a property, change its value under Property Value.
    *Add a property, click Add. Enter a name (avoid using spaces) and value for the property in the blank row.
    If you enter a property already on the tab, its name turns red to indicate it is a duplicate. You can duplicate properties between the application and system tabs.
    4. Click Save and confirm your changes.
    5. Stop and then restart the application server
    Ok?
    Cheers
    John
    http://john-goodwin.blogspot.com/

  • Is it possible to increase the substitution variable value length?

    Hi,
    Is it possible to increase the substitution variable value length to higher value? I checked the SQL User Guide (http://download.oracle.com/docs/cd/B19306_01/server.102/b14357/apa.htm) and it says that the limit is 240 characters.
    i just want to know any workaround for this issue?
    Thanks.

    Hi,
    Basically I have a script contains SQL statement (eg: select c,b,a.........from table a.... group by a,b and order by b c) and I have another shell script that will read the whole entire SQL statement
    In my shell script, i do it in this way.
    sqlplus -S test/test@testdb $SQL statement and i hit the following issue
    string beginning ""select c...." is too long. maximum size is 239 characters. {code}                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                   

  • Assign substitution variable to another substitution variable with truncation of value

    I launch a sql*plus .sql script by way of a concurent job. The concurrent job provides a date paramenter to the script.  Job log shows the date passed to scrpit as:
    Arguments
    2013/09/01 00:00:00
    For cosmetic purposes in the ouput's heading, I want to convert/truncate the character string to an end-user format of 2013/09/01.
    Trying to simply change one substitution variable
    (below is not working, but hopefully telegraphs my intention:
    UnDefine Low_date
    Define Low_date = '2013-09-01 00:00:00'
    UnDefine Low_date_10
    Define Low_date_10 = 'yyyy-mm-ds'
    select substr('&Low_Date',1,10) into &Low_date_10 from dual;
    prompt "Variable value is: &Low_date_10"
    WHICH PRODUCES:
    old:select substr('&Low_Date',1,10) into &Low_date_10 from dual
    new:select substr('2013-09-01 00:00:00',1,10) into yyyy-mm-ds from dual
    Error starting at line 8 in command:
    select substr('2013-09-01 00:00:00',1,10) into yyyy-mm-ds from dual
    Error at Command Line:8 Column:55
    Error report:
    SQL Error: ORA-00905: missing keyword
    00905. 00000 -  "missing keyword"
    *Cause:   
    *Action:
    old:prompt "Variable value is: &Low_date_10"
    new:prompt "Variable value is: yyyy-mm-ds"
    "Variable value is: yyyy-mm-dd"
    "I need to get to "Variable value is: 2013/09/01"

    Hi,
    SELECT ... INTO only works in PL/SQL.
    In SQL*Plus, you can use COLUMN ... NEW_VALUE, like this:
    DEFINE  low_date = '2013-09-01 00:00:00'
    COLUMN low_date_10_col        NEW_VALUE  low_date_10
    SELECT  REPLACE ( SUBSTR ( '&Low_Date', 1, 10)
                    )    AS low_date_10_col
    FROM  dual;
    PROMPT  Variable value is: &Low_date_10

  • Unable to assign the variable value

    Hi,
    I am trying to capture the error message into a variable using statement in the Refreshing tab :
    Select '<%=odiRef.getPrevStepLog("MESSAGE")%>' from dual
    After getting the error log into variable, I am making a call to Scenario which will generate a file and email it stating the error log.
    Now the issue is when i assign this variable to the Scenario variable it throws the following error:
    com.sunopsis.tools.core.exception.SnpsSimpleMessageException: Invalid parameter
         at com.sunopsis.dwg.function.SnpsFunctionBase.getSunopsisApi(SnpsFunctionBase.java)
         at com.sunopsis.dwg.dbobj.SnpSessTaskSql.execIntegratedFunction(SnpSessTaskSql.java)
         at com.sunopsis.dwg.dbobj.SnpSessTaskSql.treatTaskTrt(SnpSessTaskSql.java)
         at com.sunopsis.dwg.dbobj.SnpSessTaskSqlS.treatTaskTrt(SnpSessTaskSqlS.java)
         at com.sunopsis.dwg.dbobj.SnpSessTaskSql.treatTask(SnpSessTaskSql.java)
         at com.sunopsis.dwg.dbobj.SnpSessStep.treatSessStep(SnpSessStep.java)
         at com.sunopsis.dwg.dbobj.SnpSession.treatSession(SnpSession.java)
         at com.sunopsis.dwg.cmd.DwgCommandSession.treatCommand(DwgCommandSession.java)
         at com.sunopsis.dwg.cmd.DwgCommandBase.execute(DwgCommandBase.java)
         at com.sunopsis.dwg.cmd.e.i(e.java)
         at com.sunopsis.dwg.cmd.g.y(g.java)
         at com.sunopsis.dwg.cmd.e.run(e.java)
         at java.lang.Thread.run(Unknown Source)
    If i set the variable with any default value, it successfully makes a call to the scenario and generates the file.
    Please help!
    Thanks,
    Ritika

    Hi,
    i created a variable and assigned the value to another variable in a procedure, am getting the following error, as it says in the error i don't have any ";" that is causing the problem.
    the variable name is table_nm
    inside the procedure am assigning the value to lv_table_nm :=#SESSNAME.table_nm;
    If i change the variable name tos ome constant or any other value, the package is working fine. Any ideas why am getting error assigning the variable?
    6550 : 65000 : java.sql.SQLException: ORA-06550: line 1, column 294:
    PLS-00103: Encountered the symbol ";" when expecting one of the following:
    ( - + case mod new not null <an identifier>
    <a double-quoted delimited-identifier> <a bind variable>
    continue avg count current exists max min prior sql stddev
    sum variance execute forall merge time timestamp interval
    date <a string literal with character set specification>
    <a number> <a single-quoted SQL string> pipe
    <an alternatively-quoted string literal with character set specification>
    <an alternatively
    java.sql.SQLException: ORA-06550: line 1, column 294:
    PLS-00103: Encountered the symbol ";" when expecting one of the following:

  • How to assign a variable value to crystal report viewer formula with CR2008

    Hi ,
    I am using crystal reports 2008 and i am not able to find how to assign  variable value  to crystal report viewer formula.
    In CR 8.5 , i used to have crystalreport1.Formulas(0) = variable1
                                             crystalreport1.Formulas(1) = variable2
    but, i don't find similar kind  in crystal reports 2008.
    How can i achieve the same functionality using crystal reports 2008.
    Thanks in Advance
    Regards,
    Ramnath

    Hi,
    Can i anyone help me out with this.
    I am generating crystal reports in vb6 using CR 8.5 and vb6 and below is the code snippet for the same
    CrystalReport1.Formulas(0) = "PrintTitle= '" & strMyTitle & "'"
    CrystalReport1.Formulas(1) = "FromDate= '" & MskFromDate.Text & "'"
    CrystalReport1.Formulas(2) = "ToDate= '" & MskToDate.Text & "'"
    Please let me know how the same functionality can be achieved in VB.Net using Crsytal reports 2008
    Any code snippet would be of great Help.
    Thanks in Adnvance.
    Ramnath

  • Can we assign jython variable value into ODI variable?

    Hi Team,
    We are trying to save jython variable value into ODI variable so that ODI variable can use in later steps.
    we are facing failure regards same.
    Please suggest us so that we can use ODI variable value in later steps.
    Thanks
    Ankush.

    See if this post help you :- How to assign value for a ODI variable from Jython Script
    Doc id 424579.1 on metalink should help.

  • Getting a substitution variable value with VB API

    Hi,I'm trying to get the value of a specific substitution variable on an application with EsbGetVariable().I get a nice message that says "you do not have sufficient access to get this subsitution variable." and then i get the return code of EsbGetVariable() that is 1051085 (i couldn't find it in any documentation).The funniest thing is that i can get the value of the substitution variable, using Application Manager, with the same Essbase user that tries to get the value in the API.Any help would be welcome...PS : here is the code of the macro i execute (hope it will be readable)...Public Sub ESB_GetVariable()Dim i As IntegerDim nCount As IntegerDim sts As LongDim oVariable As ESB_VARIABLE_TDim hCtx As LongDim AppName As String * ESB_APPNAMELENDim DbName As String * ESB_DBNAMELENDim szApp As IntegerDim szDb As IntegerDim pAccess As IntegerDim X As VariantX = EssVConnect("Feuil1", "xxx", "xxx", "xxx", "Gmo_RvIt", "It_Repr")If X = 0 Then hCtx = EssVGetHctxFromSheet("Feuil1") If hCtx <> 0 Then sts = EsbGetActive(hCtx, AppName, szApp, DbName, szDb, pAccess) oVariable.AppName = AppName oVariable.VarName = "Divers_VR" sts = EsbGetVariable(hCtx, oVariable) MsgBox "status is " & sts MsgBox "Divers_VR value is " & oVariable.VarValue Else MsgBox "EssVGetHctxFromSheet failed with status " & hCtxEnd IfElse MsgBox "EssVConnect failed with status " & XEnd IfEnd Sub

    testing formatting ...
    0.03965 0.00026 ds ... <save> auth user=nobodyEdited by: gpoz on Apr 18, 2013 12:14 PM

  • Synchronize substitution variables values between Essbase and Planning

    Hello,
    In EPM version 11.1.2.1 (but we noticed the problem also in previous EPM versions) when we set the value of a substitution variable in Essbase, the value is is not immediately updated in Planning: for some time we see the old value. The value in Planning remains unchanged even in we log off or exit Planning and log on again.
    Instead if we restart the Planning service, the value is immediately updated
    Since we would like to use the Essbase substitution variables to manage some selections in Planning Data Entru Forms, is there any way to force a synchronization, or to increase the frequence of synchronizations between Essbase and Planning?
    Regards
    Francesco Quaranta

    Have a look at setting the planning property SUBST_VAR_CACHE_LIFETIME
    http://docs.oracle.com/cd/E17236_01/epm.1112/hp_admin/properts.html
    Cheers
    John
    http://john-goodwin.blogspot.com/

  • Using calc script function when setting substitution variable value

    I would like to be able to execute the below, but this wont work since it is a combination of MaxL and calc script syntax:
    alter database 'App'.'DB' set variable 'Var1' @PARENT("Day 1");
    The following does not work either for the same reason:
    set A = @PARENT("Day 1");
    echo $A;
    alter database 'App'.'DB' set variable 'Var1' $A;
    Is there a correct way to do the above, and is it even possible? Or will the variable literally have to contain the value "@PARENT("Day 1")" to be later parsed in a calc script?

    Hi James. I was hoping that 'query database' with the 'member info' option was going to include the parent in the result set, but it's just a bunch of storage / consolidation properties so no luck there.
    The only idea i could come up with (and this is getting pretty clunky) would be to use MaxL to execute a report script (or MDX query, but the output would be different and probably harder to parse):
    //ESS_LOCALE English_UnitedStates.Latin1@Binary
    {SUPHEADING}
    {TABDELIMIT}
    <ROW("YourDimension")
    <PARENT &YourSubVar
    !This spits out a tab delimited file containing just one line - the name of the parent of the member named in &YourSubVar, and one data value, tab delimited. You could then parse the output in cmd (I'm assuming you're on Windows) using FOR /F to grab the first value and then pass it back in to a subsequent MaxL command to update the value of the second subvar (as referenced in your fix).

  • Problem in assigning a variable value to another one

    hi
    i am just trying to develop class calculating the selling price of car as 15% of the purchase price addeed on the purchase price
    and i developed the next code which is a part of longer code :
    package cardealer;
    public class Car4Sale extends Car {
      public static void main(int[] args) {
        Car4Sale pur , sell; //pur is purchasing price , sell is selling price
        sell = pur *(1+ 0.15) ;
    }the proplem is in the line : sell = pur *(1+ 0.15) ;
    the program says: the variable pur might have not been intialized . operator * can not be applied .
    Note: when i delete this line the variable pur returns intialized in the upper line

    Here is a simple example of what (i think) your
    trying to do.
    //Car class
    public class Car
         private double purchasePrice;
         private String type;
         public Car(double price, String type)
              this.purchasePrice=price;
              this.type=type;
         public double getPurchasePrice()
              return purchasePrice;
         public void setPurchasePrice(int price)
              this.purchasePrice = price;
         public String getType()
              return type;
         public void setType(String type)
              this.type = type;
    //Car Sales class
    public class CarSales
         private Car car = new Car(100,"Porsche");
         private double sellingPrice;
         public static void main(String[] args)
              CarSales cs = new CarSales();
    System.out.println("Car Type :"
    :" +cs.car.getType());
    System.out.println("Car Purchase Price
    ce :"+cs.car.getPurchasePrice());
    System.out.println("Car Selling price
    ce
    :"+cs.getSellingPrice(cs.car.getPurchasePrice()));
         public double getSellingPrice(double purchasePrice)
              return purchasePrice += (purchasePrice / 100) *15;
    }modify it to suit your needs.thank you for this great reply but what i am really looking for is to enter attributes for the car. the attributes are number , manufacturer , size, color . after then adding the purchase price in a subclass and calculating the selling price .
    Ihave no problem whith input code but i am not sure about it is how to deal with these attributes

  • Substitution variable - Problem

    The requirement is to have numeric value to a substitution variable. In essbase there is a provision to set numeric value to a substitution variable . i tried out the below one its not working.
    Create a sub variable and assigned value "12" and tried using the same sub variable in the MDX query but getting error. kindly let me know is it possible to set a numeric value to a sub variable and use the same in MDX formula. Any help would be greatly appreciated.
    I have seen this note in dbag :
    If a substitution variable value is numeric, different rules apply for how you enter the variable:
    If it is not used in MDX statements, enclose a substitution variable value in quotation marks; for example, if the variable name is Month, and its corresponding value is 01 (corresponding to January), place quotation marks around 01 (“01”). Substitution variables usually are used with block storage databases; they are not used in MDX statements.
    If it is used in MDX statements only, such as in formulas in aggregate storage outlines, and the value is numeric or a member name, do not enclose the value in quotation marks.
    Note:
    If a substitution variable value is numeric or a member name starting with a numeral or containing the special characters referred to above is to be used both in MDX and non-MDX situations, create two substitution variables, one without the value enclosed in quotation marks and one with the value in quotation marks.

    i got the way to do

  • Substitution Variable in Essbase

    Hi Experts,
    In our report script, whenever there is a small change in say Product then we need to update several Rows/code in Report scripts.We were using Rename script for the same like -
    {Rename "ABC"} "testl"
    So, we thought of a solution where we can create say 3 Substitution variables as we have restriction of 255 chars say V1, V2 and V3 substitution variables having this Rename script. and finally create "V" substitution variable = V1+V2+V3
    Is there any possibility of having Substitution variable Value as sum of 3 other existing Substitution variables in Essbase? Say in my Case
    V = V1+ V2+V3
    Please help me out if there is any?

    Hi,
    Your thinking is sound and creative, however due to the way they work you can't define a subvar as a concatenation of other subvars because it will be interpreted literally. e.g.
    sv1 = hello
    sv2 = world
    sv3 = &sv1 + &sv2
    sv3 interpreted by essbase will be: &sv1 + &sv2 and throw an error.
    (If you think about it, concatenating two 255 char subvars into another would still exceed the character liimit.)
    So,
    if you want to concatenate several long subvars, just define them and mash them together:
    &sv1 &sv2 = hello world
    regards,
    Robb Salzmann

  • Substitution variables in Sql*Plus

    Hi all,
    How to make Sql*Plus ask for the substitution variable value one time only for a substitution variable even if it appears multiple times inside a query ? Because so far each time I launched the query below then I have been asked two times by Sql*Plus for the variable value. For example : select ref_site from t_comsis where longitude_lamb + latitude_lamb < &distance + power(&distance,2).
    Thanks

    of course accept is more friendly, you can check for valid number, you can have a prompt or a hidden input.
    you can also undef your variable if you prefer the && solution
    SQL> select &&x+&&x from dual;
    Enter value for x: 1
    old   1: select &&x+&&x from dual
    new   1: select 1+1 from dual
           1+1
             2
    SQL> undef x
    SQL> r
      1* select &&x+&&x from dual
    Enter value for x: 2
    old   1: select &&x+&&x from dual
    new   1: select 2+2 from dual
           2+2
             4

Maybe you are looking for

  • Can I "count" the number of rows excluding the header and footers

    I have some tables that consist of a different number of rows, as the number is part of an equation I need to know the number of rows excluding the header and footers. I have the work around in =ROWS(ColumnG)-3, but is there a tidier way? I want to b

  • Subvi is not executable error, but it has no error

    Hey I hope you can help me with a weird error. I got the error "SubVi  'name' : SubVi is not executable" but when I click on the SubVi and open it it does not show me any description of an error. If I open the main vi or the SubVi alone it shows no e

  • Expand the Background Image to Cover the Entire Region Title

    I have a region title that contains an image and it has a height of 2 rows but the background image (blue image) is not expanding in the area (the css contains repeat for the background). The application uses theme 2. Can someone help? CSS: .rc-title

  • The buttons 'New entry' and 'Delete' disappear on all customizing t_codes.

    Hello All I want to define one new storage location, but I don't find the button 'New entry'.  After checking, I found that the button 'New entry' and 'Delete' disappear on all customizing transaction codes.   who know why? By the way, currently our

  • ZCM Update 11.2.3a: Failures after Crash

    Hi, when i update my 2. Primary with Update 11.2.3a whe shutdown the Server by a mistake in the middle of the Process. So there was a lot of Problem's, most of them i found and repaired, but Now i got 2 Problems where i can't repair and didn't know w