on 10-18-2015 4:49 PM
Hi experts
I am using The below logic script to effect the profit of the year in rhe balance sheet by any transaction that happen on the Income statement
// This script contains the logic which is executed whenever data is entered and sent
*XDIM_MEMBERSET CATEGORY = Actual
*XDIM_MEMBERSET ENTITY = CSO
*WHEN ACCOUNT.ACCTYPE
*IS "INC"
*REC(FACTOR=1,ACCOUNT="000210000201")
*ELSE
*WHEN ACCOUNT.ACCTYPE
*IS "EXP"
*REC(FACTOR=1,ACCOUNT="000210000201")
*ENDWHEN
*ENDWHEN
the problem is i have posted 4 entries and each one of them is balanced and totally sure that its balanced
but when the 4 entries are posted the system seems that it refuse one of them or something and there is a difference in the balance sheet
It seems that the logic script when i post 2 Entries it duplicate the first 1
Example
I have posted the entry A
so the logic script effect the balance sheet by the entry A
then i post entry B so the logic script effect the balance sheet by A again and then B
so how the make the Logic script just effect the balance sheet by only new entries ?
the first screen shot is for below 2 expense acc
0252121000_C - National Organization for social Ins |
0311010100_C - marcel |
when i posted 500 on 0252121000_C the logic worked fine and posted the 500 to 000210000201
but when i posted 1000 to 0311010100_C the logic erased the 500 from the gl 000210000201 and posted the new amount only ( 1000 )
it must be 500+1000
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
the acctype of 000210000201 is LEQ
and for ur info when i post 5000 the logic use the 5000 correctly but when i post another 3000 the logic remove the 5000 and post the 3000
so it erase the old balance of the GL and post the new one
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
If target account ACCTYPE is LEQ then:
*XDIM_MEMBERSET CATEGORY = Actual_IFRS
*XDIM_MEMBERSET ENTITY = CSO
*XDIM_MEMBERSET AUDITTRAIL = Journal_Entries
*WHEN ACCOUNT.ACCTYPE
*IS "INC"
*REC(FACTOR=1,ACCOUNT="000210000201")
*IS "EXP"
*REC(FACTOR=-1,ACCOUNT="000210000201") // -1!!!!
*ENDWHEN
About your results - only screenshots, please!
Hi Vadim
thanks for ur reply
Balance for GL 000210000201 is 0
when i post the below journal entry the logic post 18887259 to GL 000210000201 which is correct
Description | Dr (Cr) |
Cost of sales | 13,524,759 |
Administrative expenses | 5,362,500 |
Trade and other payables | (18,887,259) |
but when i post the second journal entry the logic erase the old balance (18887259) and post the new balance 4637204 which is no correct
it must sum 4,637,204 + 18,887,259
Description | Dr (Cr) |
Retained earnings | (4,637,204) |
Other expenses | 4,637,204 |
first i posted 4 journals and there is no problem with them
i am trying to make the logic to run by default but i face the same issue
when i ran the logic using Data package it worked correctly
*XDIM_MEMBERSET CATEGORY = Actual_IFRS
*XDIM_MEMBERSET ENTITY = CSO
*XDIM_MEMBERSET AUDITTRAIL = Journal_Entries
*WHEN ACCOUNT.ACCTYPE
*IS "INC","EXP"
*REC(FACTOR=1,ACCOUNT="000210000201")
*ENDWHEN
we need it to be automatically so we need it to run by default
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You have to read my document about default.lgf - the script works differently!
Read about sign conversion!
SignedData_Result = if(Result.ACCTYPE=INC,LEQ, -1, 1) * Function(if(Argument1.ACCTYPE=INC,LEQ, -1, 1) * SignedData_Argument1, if(Argument2.ACCTYPE=INC,LEQ, -1, 1) * SignedData_Argument2, ...)
That's the reason why I told you to test on the EXP type accounts!
Your script is correct for DM package, but for default.lgf it has to be like:
*XDIM_MEMBERSET CATEGORY = Actual_IFRS
*XDIM_MEMBERSET ENTITY = CSO
*XDIM_MEMBERSET AUDITTRAIL = Journal_Entries
*WHEN ACCOUNT.ACCTYPE
*IS "INC"
*REC(FACTOR=-1,ACCOUNT="000210000201") // -1!!!!
*IS "EXP"
*REC(FACTOR=1,ACCOUNT="000210000201")
*ENDWHEN
Or the opposite depending on ACCTYPE of 000210000201!
What is the ACCTYPE of 000210000201?
Just to be more accurate
Gl balance = 5000
journal A = 1000
logic change Gl balance to 6000
Journal B = 3000
Logic change Gl Balance = 8000 but it suppose to be 9000
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Vadim
I did exactly what u told me
i simplified the process as much as possible and that's what i found
the script logic when i post the first journal A = 200
it use the 200 correctly and post it to the Gl 000210000201 = 200
but when i post the second journal B =300
it use the 300 and post it to Gl 000210000201 =300 with out summation 200+300
it suppose to be 500 but it just erase the old value (200) and post the new value 300
so how to make the logic sum new values with old values
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
first i posted 4 journals and there is no problem with them
i am trying to make the logic to run by default but i face the same issue
when i ran the logic using Data package it worked correctly
*XDIM_MEMBERSET CATEGORY = Actual_IFRS
*XDIM_MEMBERSET ENTITY = CSO
*XDIM_MEMBERSET AUDITTRAIL = Journal_Entries
*WHEN ACCOUNT.ACCTYPE
*IS "INC","EXP"
*REC(FACTOR=1,ACCOUNT="000210000201")
*ENDWHEN
we need it to be automatically so we need it to run by default
account based calculation will take all the amount of the net income and i don't want this for financial wise
i only need to post the changes (journal Entries ) on the P/L GL to the retained earning
Only the changes cause i already take the all amounts before and consolidate it with some Adjusments
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Can you try to use absolutely correct wording or prepare a detailed table - before, after etc?
"Logic use the first journal" - incorrect - logic use the total amount after posting first journal
"when i post the second journal it use the first one and the second which is" correct! The logic will ALWAYS use the result like:
Initial Value + Journal1 Value + Journal2 Value
By design! And there is no way to change it, because logic is working with the cube data - not with journal table entries.
Vadim
Some detailed explanation:
1. Lets assume we have some intersection of base members of all dimensions in the cube.
2. In the report we will have the single value (100 for example) for this intersection.
3. We create a journal entry for this intersection: 200 and post it (journal itself will be stored in the journal table, not in the cube).
4. After refresh of report in the same cell we will have 300.
5. If we run some script for this intersection scoped the %VALUE% will be equal to 300.
6. Then we create a second journal entry for this intersection: 400 and post it
7. After refresh of report in the same cell we will have 700.
8. If we run some script for this intersection scoped the %VALUE% will be equal to 700.
Hope it's clear now!
Please repeat all steps from my previous post exactly! Use BASE members intersection! Use EXP accounts to simplify things. Use simple journal without balancing - just for the intersection (single line journal)!
Use very simple script:
*WHEN ACCOUNT
*IS SOMEBASESOURCEACCT
*REC(EXPRESSION=%VALUE%, ACCOUNT=SOMEBASETARGETACCT)
*ENDWHEN
Provide screenshots of original report and results!
There is no way to get anything different from I have posted!
Vadim
My requirement is to post the changes on the P/L to the retained earning in the balance sheet by default
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Sample:
You have 2 accounts A1 and A2
A1=1000 and A2=1500
You create journal adjustment A1 +200 and A2 -200
The result will be:
A1=1200 and A2=1300
If you write ANY logic script in calculations 1200 or 1300 will be used - final values after journal
In your case it's even worse - you have number of values to be aggregated and the script has to calculate this aggregation
Vadim
You have 2 accounts A1 and A2
A1=1000 and A2=1500
You create journal adjustment A1 +200 and A2 -200
The result will be:
A1=1200 and A2=1300
the script work fine but when i do the second Adjustment
A1+300 and A2-300
the logic script just duplicate the first Adjustment as it was posted in the first time and it post it again in the second time
P.S. May be it's better to use Account-based Calculations as Script Logic - SAP Business Planning and Consolidation, version for SA...
Vadim
Sorry, what do you mean by "the logic script just duplicate the first Adjustment as it was posted in the first time and it post it again in the second time"
What do you mean - "script work fine " and "do the second Adjustment"
Looks like I will be unable to help without real screenshots of your system!
here its numeric example to see what happen
total assets =2000
liability = 1000
retained earning = 1000
so Balance sheet = 0
net income = 1000
if i posted entry A
dr expense 500
cr account payable 500
it will be like this
total assets =2000
liability = 1500
retained earning = 500
so Balance sheet = 0
net income = 500
the logic script as i told u take the changed that happened on P/L account and post it to retained earning
the problem come when i post second entry B
it just duplicate first one (A)
i tried to post journal B first then A and i found that B is duplicated
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
My business is that after consolidation customer want to post manual entries that effect the expense and the account payable so if he posted this entry without telling the system to effect the (Retained earning F10) with the increase in expense The Balance sheet will not be balanced there will be a difference
so what i needed from the above script is to effect the profit for the year which is 000210000201 by any changes happened on EXP and INC
but my problem is
It seems that the logic script when i post 2 Entries it duplicate the first 1
Example
I have posted the entry A
so the logic script effect the balance sheet by the entry A
then i post entry B so the logic script effect the balance sheet by A again and then B
so how the make the Logic script just effect the balance sheet by only new entries ?
Sorry, this is absolutely not clear... I want to see some table with some figures. And I want to see what result is expected and not the explanation of the strange current script.
P.S. Journals are used to post some delta, but after posting script will use in calculation the total value. If any account is changed after journal posting - all accounts has to be summed up to generate correct total
User | Count |
---|---|
14 | |
4 | |
2 | |
1 | |
1 | |
1 | |
1 | |
1 | |
1 | |
1 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.