Clarification of calculation script

Hello

Can someone tell me the differences between the underside of the calculation scripts.

Text 1:

SET CreateBlockonEQ

Fix (dim1, dim2)

Budget

(

Profit = (sales - COGS) * 2;

)

CreateBlockonEQ Off SET;

ENDFIX:

Text 2:

SET CreateBlockonEQ

Difficulty (Dim1, Dim2,Budget)

Profit = (sales - COGS) * 2;

CreateBlockonEQ Off SET;

ENDFIX;

the output of both calculations should be the same, the only difference (and I'm sure someone will correct me) lies in how Essbase process calculation

correction on the budget, the calculation runs only for the Budget scenario, where as with the fix but does not include a scenario, it will run the calculations for all scenarios, calculate the only member of Budget, but to evaluate all possible options.

Tags: Business Intelligence

Similar Questions

  • Calculation script of the OSB for exchange rates - shared members

    Hello together,

    Happy new year!!!

    I need your help with a BSO calculation script in the exchange rate.

    Here you can see how the entity & currency hierarchies are made up:

    Hierarchy of the entity

    Hierarchie1 (element Stored, EUR) - all children are only once in the hierarchy.

    H1Parent1 (stored element, EUR)

    H1P1Child1 (stored element, EUR)

    H1P1Child2 (stored element, EUR)

    H1Parent2 (stored element, SEK)

    H1P2Child1 (stored element, SEK)

    H1P2Child2 (stored element, SEK)

    Hierarchie2 (Stored item, EUR) - the child might be several times in this hierarchy!

    H2Parent1 (stored element, USD)

    H1Parent1 (element Shared, EUR)

    H1Parent2 (element Shared, SEK)

    H2Parent2 (stored element, CAD)

    H1Parent2 (element Shared, SEK)

    H1P1Child1 (element Shared, EUR)

    Hierarchy of currencies

    Local currency

    EUR

    USD

    SEK

    CAD

    Reported (group currency)

    Euro

    Parent currency

    EUR_USD

    EUR_CAD

    EUR_SEK

    First script:

    For the exchange rate of the national currency in euro (1 hierarchy), it was very easy because I could give each level-0-member of an attribute (UDA) for the currency. So it's pretty easy to create a script for all the members-0-level ((DEV) duration: 12 minutes)

    'Euro')

    IF (@ISUDA ("Accounts", "AR"))

    IF (@ISUDA ("Entities", "heart")) 'Euro ' is' EUR '.

    "Else if (@ISUDA ("entities","cAED")) 'Euro' = (@SUMRange ("AED","January": & CurrMonth)) /"AED"-> Average_Rate;

    ENDIF

    ENDIF);

    Second script - Part1:

    But for the second hierarchy (hierarchy 2) I have the problem that there are a lot of shared items and I can't give them an obvious UDA in which I can calculate the currency ((DEV) duration: 12 minutes).

    ("Parent currency"

    IF (@ISUDA ("Accounts", "AR"))

    IF (@ISMBR (@RDescendants("H2Parent1",0))) 'Euro_USD' = (@SUMRange ("Euro", "January": "January")) * "USD"-> "Average_Rate";

    ElseIf (@ISMBR (@RDescendants("H2Parent2",0))) 'Euro_CAD' = (@SUMRange ("Euro", "January": "January")) * "CAD"-> "Average_Rate";

    ENDIF

    ENDIF);

    Second script - Part2:

    This formula works, but it is very slow, because I have several fixes. (Duration (DEV): round about 1 h)

    FIX (@RDescendants("H2Parent1",0))

    ("Parent currency"

    IF (@ISUDA ("Accounts", "AR")) "Euro_USD" = (@SUMRange("Euro","January":"January")) * «USD»-> «Average_Rate»;)

    ElseIf (("Accounts", "CR") @ISUDA) "Euro_USD" = (@SUMRange("euro","January":"January")) * «USD»-> «Closing_Rate»;)

    ENDIF);

    ENDFIX


    You have an idea how I can improve my second calculation script in a dynamic and efficient?


    I hope that I have described my problem very well.


    Thanks a lot for your help


    Ben

    change "Motto of Parent" to "Euro_USD" would not make a difference if the hierarchy of currencies is Sparse

    I'll try to make the dense hierarchy of currencies as long as it does not have the size of your too big block. If make you it dense AND change "motto of Parent' to 'Euro_USD', it must increase the speed a lot.  However to change the size of Sparse to Dense is a very big change for the database.

  • How to use the @accum function in the calculation script

    Dear all.

    I'm new in essbase - calculation script so don't know how to use the @accum function.

    I want the aggregation value of child to parent

    Hierarchy

    Product

    100 > Storage Dimensions marked as stored (marked as intentionally as I want to calculate the value using the calculation script)

    100. 10 (+)

    100-20 (+)

    100-30 (+)

    I'm trying calculation Script

    100 = @Accum (@children("100"), jan: Feb);

    It works when I use below

    100 = @Accum("100-10",Jan:Feb);

    Error:-number of Dimensions [1] does not match number of gen/lev [3] office [@Dim]

    Don't know how I can roll up to an aggregate value of all the members of the child to the parent.

    Error.PNGhierachy.PNG

    you do this more difficult it must be. If you want to accumulate up to 100 then you could just make your calc

    '100 '.

    but that would be only 100, to make the OU any dimension would

    AGG (Product);

    Or better yet

    AGG (Product, Market);

  • Calculation script, loading data in each block?

    Hello

    I have a calculation script that does not replace an existing value with 1000. It should not do anything if the value is 0 or #missing, but I found it load actually numbers on all the blocks without worrying. Am I wrong in something?

    :

    FIX (@RELATIVE(Dimension1,0), @RELATIVE(Dimension2,0))
    FIX (& CURRENT_SCENARIO, & CURRENT_YEAR)
    "ACC100")
    IF (ACC100! = 0 OR ACC100! = #Missing)
    ACC100 = 1000;
    ENDIF
    ENDFIX
    ENDFIX


    Any help will be appreciated.


    Kind regards

    you want to use AND it is not OR

    in your case it will always return the true value, it will not not 0 or may not be #MISSING.

    If you use, and it won't work if its not the 0 and not #missing

  • Customized for Acrobat field calculation script

    Hi, I have a field calculation script. I want to calculate exp (x), I want to link a X 'A' value. May I know what is the formula for this calculation?

    From another angle, I found at online, the operation is < 2.71 * X >, means 2.71 X power. But duno why <>* may not work to this end (power) to the custom calculation script.

    Do I know what other script can be created for exp (x).

    Please notify. Thank you.

    Of

    McCarthy

    Thank you all! I finally have the answer by myself already.

    Use this formula:

    Event.Value = Math.exp (this.getField("A").value)

    Yes!

  • Is it possible to convert excel function if (and a custom calculation script

    Our field staff use many Excel files for project documentation.  Our organization moves for iPad instead of laptops and we found that a PDF file to be filled on-line is a great resource for our staff.  I have created several of these forms that contain multiple lines and I just starting to learn how to write custom calculation scripts.  I have a more complex than most calculation and I don't know if this can be written in script.

    = IF (I6 < 0.7, G6 * 0.8, IF (AND (I6 > = 0.7, I6 < 0.8), G6 * 0.85, IF (AND (I6 > = 0.8, I6 < 0,9), G6 * 0.9, IF (AND (I6 > = 0.9, I6 < = 1,1), G6 * 1, IF (AND (I6 > 1.1, I6 < = 1,2), G6 * 1.1, IF (AND (I6 > 1.2, I6 < = 1.3), G6 * 1.15, of"extra work"))))))

    I6 is OverdepthRow1

    G6 is WithDowelsRow1

    I think I understand how to get started

    var v1 = get.thisField("OverdepthRow1").value;

    var v2 = get.thisField("WithDowelsRow1").value;

    if(v1<0.7) {}

    var result = v2 * 0.8

    Event.Value = result}

    ElseIf (v1 > = 0, 7 - now I don't know what to do!)

    I hope that I used the correct brackets and braces in the right places.

    I appreciate your help and your advice.

    Thank you

    Rhonda

    I'm sorry, I made a mistake with the first two lines. I have corrected a problem but introduced another. They must be:

    var v1 = + getField("OverdepthRow1").value;

    var v2 = + getField("WithDowelsRow1").value;

  • If/Then converted to a custom calculation Script

    Can someone help me convert = IF (A2 - A1 > 0, 0, A1 - A2) in a customized for use in an Adobe form calculation Script?

    Thank you!

    If A1 and A2 are field names, then the custom calculation script might look like:

    (function () {}

    Get the field values as numbers

    var A1 = + getField("A1").value;

    var A2 = + getField("A2").value;

    Set the value of this field

    Event.Value = A2 - A1 > 0? 0: A2 - A1;

    })();

  • Convert the IF function in the custom calculation Script

    Can someone help me with 'IF(Line7<Line8) Line7, framework8' conversion in a custom calculation Script?

    var L7 = Number(this.getField("Line7").value);
    var L8 = Number(this.getField("Line8").value);
    event.value = (L7		   
  • How to make the calculation script to show 2 decimal places and stop rounding down to integers?

    Hello. First of all, thank you to those of you who have helped me create an interactive PDF file last year that worked perfectly if only integers are entered. This year, my client wants to show two decimal places in the calculations, and I'm back in this forum hoping to find the same expertise to make it happen.

    My form includes 43 fields for various monthly expenses. The sign of dollar for each field is part of the content of the form, not part of the scope of formatting. Users enter values directly in these fields, and the fields are formatted to display two decimal places. Each of these includes a the following validation script:

    Event.RC =! (event.value & & + event.value < 0);


    To the right of each of these fees, the fields are yes/no boxes ( expense Typecalled) that answer the question, "is this essential expense? The value of exports for Yes's 'essential', and the value of exports is "discretionary".


    A value entered in all areas of expenditure is directed to the field Total expenses by checking Yes or field Total discretionary spending by clicking No. two of these total fields are formatted to display two decimal places. In addition to long calculation scripts, the two totals fields include this custom validation script:

    If (event.value == "0") {event.value = util.printx ("", event.value)}

    Here's the problem: when values with two decimal places are entered in any area of expenditure, the calculation in two fields of total script rounded to the whole number closest. When 10.99 is entered in a field of expenditure and the Yes checkbox is checked, the value 10.00 is displayed in the field Total expenses . I want to display 10.99.

    For testing purposes, I inserted a new text field and did a simple calculation in choosing the fields of the somme and the values displayed correctly. The problem is definitely with the script in the two fields in total .


    I can drop the scripts of math here, but they are long and I'm not sure what the Protocol is super-long positions. I could also download the file, but I never did it and will need to understand this.

    Thank you for taking the time to read this. If you can help me, very well!

    To explicitly convert the field values for numbers, do something like this instead:

    var expense0 = + getField('monthly$.0').value,

    depenses1 = + getField('monthly$.1').value,

    etc.

  • Add a minimum value in a calculation script

    I'm working on a new form and add a minimum for a calculation script that calculates the amount of the loan, but if the calculation is <$ 175, it fills as $175 and is no less than that.

    Current script is:

    function MyRound (nValue, nDec) {}

    var nRound = util.printf ("" %, 1-1. "') + nDec + "f", nValue)

    Return Number (nRound);

    } / / end MyRound funciton.

    custom calculation script lenderstitlebase;

    lenderstitlebase = (loanamount *. 0030) circle until neareast 0;

    calculate the value;

    var lenderstitlebase = this.getField("loanamount").value * 0.0030.

    round the value;

    Event.Value = MyRound (lenderstitlebase, 1);

    Thank you!

    Add this line at the end of the code:

    If (event.value<175) event.value="">

  • How to add the field values custom calculation script

    Hello

    I have a calculation script:

    var bits = this.getField("DEXM").value;

    jib var = this.getField("acrofocus").value;

    var Misc = this.getField("acromisc").value;

    LVL var = this.getField("LVL").value;

    chk var = this.getField ("Check Box1.0") .isBoxChecked (0);

    {if(CHK==1)}

    Event.Value = (5 + jib + misc abi + (Math.floor (lvl/2))) ;}

    on the other

    {event.value = (jib + various + bits + (Math.floor (lvl/2))) ;}}

    I try to get the sum of the fields based on the value of a checkbox control. The if statement seems to work because the result does not change, but instead of adding up the results, it adds the numbers. Example: chk == 1, so add 5 + 0 + 0 + 2 + 1 and 8 display. But instead, it displays for event.value 521. All fields which events are digital with 0 decimal. What happens here? I expect that if they were formatted text fields, but they are not.

    Thank you all.

    You must explicitly convert the value of each field of a number. As an empty field values is a string type, the + operator gives you string concatenation instead of adding digital. You can review the first four lines of the script to:

    ABI = var + this.getField ("DEXM") .value;

    jib var = + this.getField ("acrofocus") .value;

    Misc = var + this.getField ("acromisc") .value;

    var = LVL + this.getField ("LVL") .value;

    and it should work properly.

  • Need help to create a custom for a simple calculation script

    I'm looking for a script that will allow me to take the average of several cells, but if the cell is empty, so that it can be ignored.

    For example, if I have five cells, and all five have numbers in them, I need the total divided by 5.

    But if I have five cells, and four only is filled with numbers, then I want that it just be an average of 4.

    I think I have explained well enough, but I would like to know if you have any other questions or need more information.

    Cell 1 Cell 2 Cell 3 Cell 4 Cell 5 Average
    55347(5 + 5 + 3 + 4 + 7) / 5 = avg
    5347(5 + 3 + 4 + 7) / 4 = avg

    I don't want empty cells is calculated in (I don't want a zero on average), but I need a script that I can apply to several rows as above.

    As the custom calculation script 'Dor 1', enter:

    calcAverage (["1-1", "1-3", "1-5", "1-7", "1-9"]);

  • Custom calculation script

    Hello

    I have some problems eiditing my custom calculation scripts.

    at present, there are: ColorField ('IncubatorLow', ValidateMinMax ('IncubatorLow', 400, 1000) & & ValidateOrder ('IncubatorLow', 'IncubatorHigh'));

    I want to change it

    If (event.value > = 400 & & event.value < = 1000) event.target.textColor = color.black;

    Else if (event.value > 1001) event.target.textColor = ["RGB", 0.5, 1, 0];

    Else if (event.value < 399) event.target.textColor = ["RGB", 0.5, 1, 0];

    But whenever I save my pdf file, it keeps the old one? Although even I tried to delete, lock and so on?

    Under java script, I can't know what is may be the course?

    Any ideas? Thanks in advance!

    Found under Java Script: ColorField runs by Custom Caluclations a string. But if I do one for example a new java script for CustomColors - and change of ColorFields to CustomColors.
    And then save the pdf file, it always uses the Colorfield?

    Just solved the problem.

    The form field name: IncubatorLow - IncubatorHigh - now, I just called them: IncubatorLowColor - IncubatorHighColor, then change the java script for validationminmax and change the colors for my 'java script' CustomColors.
    Can register with it back to the original script.

    I do not understand why change the field can solve it, but it has

  • Custom calculation script % help

    What is the custom calculation script to arrive at a percentage of penetration between two fields? Example: 50 / 100 = 50%

    The simple notation of field: field 1 / field 2

    Custom script:

    var v1 = + this.getField ("Field 1") .value;

    var v2 = + this.getField ("Field 2") .value;

    If (v2 == 0) event.value = "";

    else event.value = (v1 / v2);

  • Conversion of excel in the calculation script formula

    How to convert this excel formula in the calculation script in pdf format?

    = IF (K10 = "PRF1120", 13, IF (K10 = "PRF1020", 10, IF (K10 = "PRO1020", 8, IF (K10 = "PRF1140", 5, IF (K10 = "ACC 1020", 3, IF(K10="PRO1080",4,""))))))

    The custom calculation script should be something like:

    Get the value of an input field

    var sVal = getField("K10").valueAsString;

    Set the value of this field depnding on the value of the input field

    switch (sVal) {}

    case 'PRF1120 ':

    Event.Value = 13;

    break;

    case 'PRF1020 ':

    Event.Value = 10;

    break;

    Repeat for the other possibilities

    by default:

    Event.Value = "";  This field blank

    }

    More information about the JavaScript statement switch are available in any decent JavaScript reference. Replace "K10" in the first line above with the actual name of the input field.

Maybe you are looking for