cancel
Showing results for 
Search instead for 
Did you mean: 

Derive characterstics value while File upload

sankamesh
Explorer
0 Kudos

Hello experts,

I use "file upload" planning function to load user's data. The file which is loaded has 0CALWEEK.

My real time planning cube has '0CALMONTH' and 'Fiscal period'.

My query is how to derive the 0CALMONTH and fiscal period for a record loaded from file using 0CALWEEK? (while file upload).

Possiblities tried :

1. A custom planning function which has the code to derive the value.

     - But it is not working to change a characterstic in cube. Rather it worked with a keyfigure. Can't I change a characterstic of a cube via code ?

2. Tried via file upload BADI

     - the structure of incoming file and cube is different. So I believe I can't use this option.

Kindly help me with options to derive 0CALMONTH from 0CALWEEK which is loaded via 'file upload' planning function.

Thank you !

Accepted Solutions (1)

Accepted Solutions (1)

sheldon_piao
Advisor
Advisor
0 Kudos

Hi Sankameshwa,

I guess there is standard logic about how to derive 0CALMONTH from 0CALWEEK:

--------

Function module      RST_TOBJ_TO_DERIVED_TOBJ_SID

*... X <-- CALWEEK

       WHEN rsd_c_timnm-calweek.

         CASE i_timnm_to.

*... CALMONTH <-- CALWEEK

           WHEN rsd_c_timnm-calmonth.

             PERFORM calweek_calmonth USING  i_timsid

                               CHANGING  e_timsid

                                      e_timsid2.

-------

You may create an aggregation level contains only 0CALWEEK, which is built on infocube containing both 0CALWEEK and 0CALMONTH. Then after saving the value for 0CALWEEK, the relevant 0CALMONTH value will be generated automatically.

For fiscal period, there seems no standard logic between 0CALWEEK and 0FISCPER. Maybe you have to design two Z characteristics and give the relevant logic for it via customized CR.

Best Regards,

Sheldon.

sankamesh
Explorer
0 Kudos

Dear Sheldon,

Thanks for your reply.

I did try the option you suggested. I had 0CALWEEK only in file. My cube had 0CALMONTH and 0CALWEEK.  My aggr level had 0CALWEEK.

But the 0CALMONTH was not populated in cube. Later, I went through the below link which specifies the source and target fields which would have automatic population of data.

https://help.sap.com/saphelp_nw73/helpdata/en/4c/ad8258d5943b9de10000000a42189b/content.htm


Hence as per the link, I added 0CALDAY in file instead of 0CALWEEK and tested. Now both, 0CALMONTH and 0CALWEEK got populated automatically.Thank you, your answer was helpful

Regarding population of 0FISCPER, can I change a characterstic value of a cube using custom class ?? I could change a key figure value.

Even though i have a Z charac for fiscal period, I am not sure if a charac value of a cube can be changed.. Any help would be appreciated

--

Regards,

Sankameshwar

sheldon_piao
Advisor
Advisor
0 Kudos

Hi Sankameshwar,

Yes, the online help is the right one.

For 0FISCPER, you may do the same as 0CALMONTH via 0CALDAY.
As there is 0FISCPER, there is definitely 0FISCVARNT. So you may use 0CALDAY and 0FISVARNT to derive 0FISCPER as well.

Best regards,
Sheldon.

Answers (0)