on 10-01-2008 2:00 PM
Greetings!!
I have a question on FOX I am sure some people in thsi network might help me here.
In The planning function (COPY) I have headcount information in the planning cube and basically this function copy into cost center planning. Employee salary distribution into various cost element/center per job code. We used to have one job code for Direct employee now HR has created more job codes for direct hire .I thought of adding more line with similar syntax just wondering if this is the correct way or do we have any better option..
Here is the code which I am using currently..
*******************************
{ 0AMOUNT, 0005012000,10, #, ZSACOST1 } = { 0AMOUNT, #,
#, 40001519, ZSAHDCT1 } + { ZOVERTME, #, #, 40001519,
ZSAHDCT1 }.
*************************************
Say Instead of job code 40001519 we have now 5 new job codes so I am thinking to add more lines with similar syntax..
Any input from Fox experts !!!
If you think this can keep on changing later, it would be better to create a variable (multiple single value type) storing all the job codes and then looping on it in the FOX code - that way you would not have to change the code and transport it. You can create a 'default values' type variable but then you would have to change it to add/remove job codes and retransport; if you do not want that, you can maintain the job codes in some table and create an exit variable which will read the job codes so you can directly change the table data in production system and no need for any transporting.
For looping, you can use the FOREACH IN VARIABLE statement or a VARC, VARI construct. Search this forum if you need help with either of these and also look in SAP documentation.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Many Thanks
I have written as below
******************************************
DATA VJOB TYPE 0JOB.
NEW *************************
{ 0AMOUNT, 0005012000,10, #, ZSACOST1 } = { 0AMOUNT, #,
#, 40001519, ZSAHDCT1 } + { ZOVERTME, #, #, 40001519,
ZSAHDCT1 }.
{ 0AMOUNT, 0005012000,10, #, ZSACOST1 } = { 0AMOUNT, #,
#, 50000147, ZSAHDCT1 } + { ZOVERTME, #, #, 50000147,
ZSAHDCT1 }.
************************************************************
Do I need to add Sum function as well?
Many Thanks
I have written as below
******************************************
DATA VJOB TYPE 0JOB.
NEW *************************
{ 0AMOUNT, 0005012000,10, #, ZSACOST1 } = { 0AMOUNT, #,
#, 40001519, ZSAHDCT1 } + { ZOVERTME, #, #, 40001519,
ZSAHDCT1 }.
{ 0AMOUNT, 0005012000,10, #, ZSACOST1 } = { 0AMOUNT, #,
#, 50000147, ZSAHDCT1 } + { ZOVERTME, #, #, 50000147,
ZSAHDCT1 }.
************************************************************
Do I need to add Sum function as well?
User | Count |
---|---|
85 | |
10 | |
10 | |
10 | |
7 | |
6 | |
6 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.