cancel
Showing results for 
Search instead for 
Did you mean: 

Default Logic Doesn't Work Correctly

Former Member
0 Kudos

Hi expert,

I'm on BPC 10 MS SP 11, I have some problems with default logic:

This is an example of default logic code that cause the problems:

 

*WHEN
RPTCURRENCY

    *IS
LC

  *REC(FACTOR=1,RPTCURRENCY=EUR)

  *ENDWHEN

  *COMMIT

I use Enviroment Shell, Planning Enviroment for testing purpose.

If a create an input schedule and send data in LC, the default logic doesn't be triggered. The data is sent correctly, but only in LC.

If I launch default logic using data manager package , this logics works correclty; a record with EUR currency is created.

Anyone have experience on similar issue ?

Thnaks,

SB

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

I have rebooted the server and now default logic work's fine.

former_member186498
Active Contributor
0 Kudos

Hi Samuele,

then please remember to close the thread assing your last answer as correct answer and eventually helpful answers if there are any.

Regards

     Roberto

Former Member
0 Kudos

The same logics, after rebooting, works in an customer enviroment  but still doesn't works in our test enviroment.

cecilia_petersson2
Active Participant
0 Kudos

Hi Samuele,

I had a similar problem, and when scoping all dimensions using

*XDIM_MEMBERSET, it worked.

/Cecilia


Answers (3)

Answers (3)

Former Member
0 Kudos

This is the "Default Formula" package logs


****************************************************************************************************


Start time --->12:50:51  -  Date:2014-03-11  (build version:10.0.10.0)


****************************************************************************************************



User:BICPMTST01\Administrator


Environment:EnvironmentShell


Model:Planning


Logic mode:0


Logic by:


Scope by:


Data File:


Debug File:\\BICPMTST01\OSoft\WebFolders\EnvironmentShell\Planning\PrivatePublications\Administrator\TempFiles\DebugLogic_9_1178694948.Log


Logic File:


Selection:\\BICPMTST01\OSoft\WebFolders\EnvironmentShell\Planning\PRIVATEPUBLICATIONS\Administrator\TempFiles\FROM_9_.TMP


Run mode:1


Query size:0


Delim:,


Query type:0


Simulation:0


Calc diff.:0


Formula script:


Max Members:


Test mode:0


Is Modelling:1


Work status Check:0


Task name:DM



Number of logic calls: 1


----------------------------------------------------------------------------------------------------


Call no. 1, logic: \\BICPMTST01\OSoft\WebFolders\EnvironmentShell\AdminApp\Planning\DEFAULT.LGX


----------------------------------------------------------------------------------------------------



-------------------------


Building sub-query 1


-------------------------


Query Type: 0


Max members:


Region:


DIMENSION:ENTITY


FR


Loading TIME.TIMEID


Time to load properties: 0.00 sec


----------------------------------------------------------------------------------------------------


select ACCOUNT,AUDITTRAIL,CATEGORY,INTERCO,PRODUCT,RPTCURRENCY,TIMEID,SIGNEDDATA


into #tblTempLogic_182538


from tblFactPlanning


WHERE  ENTITY=N'FR' AND  RPTCURRENCY=N'LC'


insert into #tblTempLogic_182538 (ACCOUNT,AUDITTRAIL,CATEGORY,INTERCO,PRODUCT,RPTCURRENCY,TIMEID,SIGNEDDATA)


select ACCOUNT,AUDITTRAIL,CATEGORY,INTERCO,PRODUCT,RPTCURRENCY,TIMEID,SIGNEDDATA


from tblFactWBPlanning


WHERE  ENTITY=N'FR' AND  RPTCURRENCY=N'LC'


and SOURCE = 0


insert into #tblTempLogic_182538 (ACCOUNT,AUDITTRAIL,CATEGORY,INTERCO,PRODUCT,RPTCURRENCY,TIMEID,SIGNEDDATA)


select ACCOUNT,AUDITTRAIL,CATEGORY,INTERCO,PRODUCT,RPTCURRENCY,TIMEID,SIGNEDDATA


from tblFAC2Planning


WHERE  ENTITY=N'FR' AND  RPTCURRENCY=N'LC'


select tmpTable.ACCOUNT,tmpTable.AUDITTRAIL,tmpTable.CATEGORY,tmpTable.INTERCO,tmpTable.PRODUCT,tmpTable.RPTCURRENCY,tmpTable.TIMEID,sum(SIGNEDDATA) as SIGNEDDATA


from #tblTempLogic_182538 as tmpTable


group by tmpTable.ACCOUNT,tmpTable.AUDITTRAIL,tmpTable.CATEGORY,tmpTable.INTERCO,tmpTable.PRODUCT,tmpTable.RPTCURRENCY,tmpTable.TIMEID


drop table #tblTempLogic_182538


----------------------------------------------------------------------------------------------------


Time to load Source data: 0.03 sec.


1 records to process


Time to prepare data process: 0.00 sec.


Time to initialize destination: 0.00 sec.


----------------------------------------------------------------------------------------------------


Time to get source data: 0.00 sec.


----------------------------------------------------------------------------------------------------


1 records scanned


0 records skipped


1 records processed


1 records generated


Time to scan data: 0.26 sec.


------------------------------


Time to prepare final strings: 0.00 sec.


Total processing time: 0.26 sec.


Model: PLANNING - Records to be posted are 1  (calc diff = 0)


ENTITY,ACCOUNT,AUDITTRAIL,CATEGORY,INTERCO,PRODUCT,RPTCURRENCY,TIME,SIGNEDDATA


FR,PL010,INPUT,ACTUAL,THIRDPARTY,PRODUCTA,EUR,2013.JAN,-50.0000000000


Time to validate records: 0.00 sec.



Post Record Status


Save count : 1


Accept count : 1


Reject count : 0


Locked region(s) by work status: 0



Posting is OK


Time to post records: 2.86 sec.



call 1 completed and data posted in 3.18 sec.



Run completed in 3.22 sec.


****************************************************************************************************


End time --->12:50:54  -  Date: 2014-03-11


****************************************************************************************************



File path: \EnvironmentShell\Planning\PrivatePublications\Administrator\tempfiles\DebugLogic_9_1178694948.Log

bishwajit_das
Active Contributor
0 Kudos

You can write the logic in a different script and try *INCLUDE that script into the DEFAULT.LGF.

Regards,

B.DAS

Former Member
0 Kudos

I'v tried to include the script in external file but It doesn't works. This is the code:

DEFAULT.LGF:
*INCLUDE PIPPO.LGF


PIPPO.LGF:
*WHEN RPTCURRENCY
  *IS LC
*REC(FACTOR=1,RPTCURRENCY=EUR)
*ENDWHEN
*COMMIT

Record in EUR are generated only if I launch "Default Formula" Package

This is the default script log:


****************************************************************************************************
Start time --->12:42:24  -  Date:2014-03-11  (build version:10.0.10.0)
****************************************************************************************************

User:BICPMTST01\Administrator
Environment:EnvironmentShell
Model:Planning
Logic mode:0
Logic by:
Scope by:AUDITTRAIL,CATEGORY,ENTITY,INTERCO,PRODUCT,RPTCURRENCY,TIME
Data File:
Debug File:\\BICPMTST01\OSoft\WebFolders\EnvironmentShell\Planning\PrivatePublications\Administrator\TempF...
Logic File:
Selection:DIMENSION:AUDITTRAIL
|INPUT
|DIMENSION:CATEGORY
|ACTUAL
|DIMENSION:ENTITY
|FR
|DIMENSION:INTERCO
|THIRDPARTY
|DIMENSION:PRODUCT
|PRODUCTA
|DIMENSION:RPTCURRENCY
|LC
|DIMENSION:TIME
|2013.JAN
|
Run mode:1
Query size:0
Delim:,
Query type:0
Simulation:0
Calc diff.:1
Formula script:
Max Members:
Test mode:0
Is Modelling:1
Work status Check:1
Task name:MANUALINPUT

Number of logic calls: 1
----------------------------------------------------------------------------------------------------
Call no. 1, logic: \\BICPMTST01\OSoft\WebFolders\EnvironmentShell\AdminApp\Planning\DEFAULT.LGX
----------------------------------------------------------------------------------------------------

-------------------------
Building sub-query 1
-------------------------
Query Type: 0
Max members:
Region:
DIMENSION:AUDITTRAIL
INPUT
DIMENSION:CATEGORY
ACTUAL
DIMENSION:ENTITY
FR
DIMENSION:INTERCO
THIRDPARTY
DIMENSION:PRODUCT
PRODUCTA
DIMENSION:RPTCURRENCY
LC
DIMENSION:TIME
2013.JAN
Loading TIME.TIMEID
Time to load properties: 0.00 sec
----------------------------------------------------------------------------------------------------
select ACCOUNT,RPTCURRENCY,SIGNEDDATA
into #tblTempLogic_137792
from tblFactPlanning
WHERE  AUDITTRAIL=N'INPUT' AND  CATEGORY=N'ACTUAL' AND  ENTITY=N'FR' AND  INTERCO=N'THIRDPARTY' AND  PRODUCT=N'PRODUCTA' AND  RPTCURRENCY=N'LC' AND  TIMEID=N'20130100'
insert into #tblTempLogic_137792 (ACCOUNT,RPTCURRENCY,SIGNEDDATA)
select ACCOUNT,RPTCURRENCY,SIGNEDDATA
from tblFactWBPlanning
WHERE  AUDITTRAIL=N'INPUT' AND  CATEGORY=N'ACTUAL' AND  ENTITY=N'FR' AND  INTERCO=N'THIRDPARTY' AND  PRODUCT=N'PRODUCTA' AND  RPTCURRENCY=N'LC' AND  TIMEID=N'20130100'
and SOURCE = 0
insert into #tblTempLogic_137792 (ACCOUNT,RPTCURRENCY,SIGNEDDATA)
select ACCOUNT,RPTCURRENCY,SIGNEDDATA
from tblFAC2Planning
WHERE  AUDITTRAIL=N'INPUT' AND  CATEGORY=N'ACTUAL' AND  ENTITY=N'FR' AND  INTERCO=N'THIRDPARTY' AND  PRODUCT=N'PRODUCTA' AND  RPTCURRENCY=N'LC' AND  TIMEID=N'20130100'
select tmpTable.ACCOUNT,tmpTable.RPTCURRENCY,sum(SIGNEDDATA) as SIGNEDDATA
from #tblTempLogic_137792 as tmpTable
group by tmpTable.ACCOUNT,tmpTable.RPTCURRENCY
drop table #tblTempLogic_137792
----------------------------------------------------------------------------------------------------
Time to load Source data: 0.02 sec.
1 records to process
Time to prepare data process: 0.00 sec.
----------------------------------------------------------------------------------------------------
select ACCOUNT,RPTCURRENCY,SIGNEDDATA
into #tblTempLogic_595319
from tblFactPLANNING
WHERE  AUDITTRAIL=N'INPUT' AND  CATEGORY=N'ACTUAL' AND  ENTITY=N'FR' AND  INTERCO=N'THIRDPARTY' AND  PRODUCT=N'PRODUCTA' AND  RPTCURRENCY=N'EUR' AND  TIMEID=N'20130100'
insert into #tblTempLogic_595319 (ACCOUNT,RPTCURRENCY,SIGNEDDATA)
select ACCOUNT,RPTCURRENCY,SIGNEDDATA
from tblFactWBPLANNING
WHERE  AUDITTRAIL=N'INPUT' AND  CATEGORY=N'ACTUAL' AND  ENTITY=N'FR' AND  INTERCO=N'THIRDPARTY' AND  PRODUCT=N'PRODUCTA' AND  RPTCURRENCY=N'EUR' AND  TIMEID=N'20130100'
and SOURCE = 0
insert into #tblTempLogic_595319 (ACCOUNT,RPTCURRENCY,SIGNEDDATA)
select ACCOUNT,RPTCURRENCY,SIGNEDDATA
from tblFAC2PLANNING
WHERE  AUDITTRAIL=N'INPUT' AND  CATEGORY=N'ACTUAL' AND  ENTITY=N'FR' AND  INTERCO=N'THIRDPARTY' AND  PRODUCT=N'PRODUCTA' AND  RPTCURRENCY=N'EUR' AND  TIMEID=N'20130100'
select tmpTable.ACCOUNT,tmpTable.RPTCURRENCY,sum(SIGNEDDATA) as SIGNEDDATA
from #tblTempLogic_595319 as tmpTable
group by tmpTable.ACCOUNT,tmpTable.RPTCURRENCY
drop table #tblTempLogic_595319
----------------------------------------------------------------------------------------------------
Time to load Destination data: 0.02 sec.
0 records in destination region
Time to initialize destination: 0.00 sec.
----------------------------------------------------------------------------------------------------
Time to get source data: 0.00 sec.
----------------------------------------------------------------------------------------------------
1 records scanned
0 records skipped
1 records processed
1 records generated
Time to scan data: 0.01 sec.
------------------------------
Time to calculate difference: 0.00 sec.
Time to prepare final strings: 0.00 sec.
Total processing time: 0.02 sec.
Model: PLANNING - Records to be posted are 0  (calc diff = 1)
AUDITTRAIL,CATEGORY,ENTITY,INTERCO,PRODUCT,TIME,ACCOUNT,RPTCURRENCY,SIGNEDDATA
Time to post records: 0.00 sec.

call 1 completed and data posted in 0.08 sec.

Run completed in 0.10 sec.
****************************************************************************************************
End time --->12:42:24  -  Date: 2014-03-11
****************************************************************************************************

Former Member
0 Kudos

Hi Samuele,

could you please post the full script.

You could also try to replace the *REC with

*REC(EXPRESSION=%VALUE%,RPTCURRENCY=EUR)

BR,

Arnold

Former Member
0 Kudos

Hi Arnold,

this is the full script:

*WHEN RPTCURRENCY

  *IS LC

*REC(FACTOR=1,RPTCURRENCY=EUR)

*ENDWHEN

*COMMIT

Former Member
0 Kudos

Hi,

when you trigger the default logic from a data manager package, which dimensions do you need to select an element for?

BR,
Arnold