cancel
Showing results for 
Search instead for 
Did you mean: 

Offset issue for Fiscal Year Quarter

former_member351149
Participant
0 Kudos

Dear All,

There is a requirement to develop a report for balance sheet to compare the fiscal year quarter like if user is going to give input 20143 then comparison quarter is 20142 where I did offset (-1) and if user give input as 20141 then the comparison quarter is 20134 where I am using offset as (-7).

So I have incorporated both offset in one variable. Now the issue is if I will run for any quarter then it is giving error in the run time. Could anyone suggest that how I could achieve this, whether I have used correct offset interval?

Query Key Figures Selections:

Bex Analyzer Selection Error:

Regards,

Abhishek Jain

Accepted Solutions (1)

Accepted Solutions (1)

Loed
Active Contributor
0 Kudos

Hi Abhishek,

If you want to compare two (2) periods, you must create two (2) selections..

What do you really want to achieve? Can you post sample report?

Regards,

Loed

Answers (4)

Answers (4)

rathy_moorthy2
Active Contributor
0 Kudos

Hi Abhishek,

Your requirement is to have 3 columns -

1)Current Qtr - here on the key figure, you do a restriction on fiscal year qtr for the user entered variable

2)Previous Qtr - here on the key figure, you do a restriction on fiscal year qtr for the user entered variable with a offset of '-1'

3)Previous Year Qtr - here on the key figure, you do a restriction on fiscal year qtr for the user entered variable with a offset of '-4'

If the offsets do not work in any of these case, you can write a CMOD exit to return the desired value.

Hope it helps

Regards,

Rathy

former_member194898
Active Contributor
0 Kudos

Hi,

I wouldn't do it in that way i.e. one column where you count previous quarter for quarters 2 3 4 (offset -1) and another column for counting previous quarter for quarter 1 (offset 7).

There should be just one column where you count just previous quarter. Use an EXIT to count previous quarter for any value of quarter.

Regards, Leszek

something like this can be used:

WHEN 'ZPREVQUARTER'.

* QUARTER(1) TYPE C.

* YEAR(4) TYPE C.

* have to be defined after DATA: keyword !!!


   IF i_step = 2.

         LOOP AT i_t_var_range INTO l_s_var_range

           WHERE vnam = 'ZCURRENTQUARTER'.

           EXIT.

         ENDLOOP.

         CLEAR: l_s_range.

         YEAR = l_s_var_range-low(4).

         QUARTER = l_s_var_range-low+4(1).

         IF QUARTER = 1.

          YEAR = YEAR - 1.

          QUARTER = '4'.

         ELSE.

          QUARTER = QUARTER - 1.

         ENDIF.

         CONCATENATE YEAR QUARTER INTO l_s_range-low.

         l_s_range-sign = 'I'. "loc_var_range-sign.

         l_s_range-opt = 'EQ'. "loc_var_range-opt.

         APPEND l_s_range TO e_t_range.


      ENDIF.



former_member351149
Participant
0 Kudos

Dear All,

Just for the update regarding the requirement is:

1.

                         Current Quarter           Previous Quarter                Previous Year Quarter

FSV                       20144                         20143                                  20134

2.

                         Current Quarter           Previous Quarter                Previous Year Quarter

FSV                       20141                         20134                                  20131

User will have to input only current quarter value like 20144 or 20141, based on that corresponding quarter will display. So I have used the offset -1 and -7 which suppose to calculate previous quarters but by using two values in column I am getting error.

Regards,

Abhishek Jain

former_member194898
Active Contributor
0 Kudos


Hi,

Write something more about this error ? Do values are incorrect ?

Note ! if you use virtual infoprovider eg. 0figl_v10 rules of restricting are slight different.

Why don't you try using exit's for restricting data ?

Leszek

Loed
Active Contributor
0 Kudos

Hi Abhishek,

Is this always fixed? The -1 and -7 in offset? I mean, what's the logic behind your report?


Why is it if user enters 2014004, previous quarter will be 2014003..But if user enters 2014001. previous quarter will be 2013004? What's the logic? How about the other months?


Regards,


Loed

former_member351149
Participant
0 Kudos

Dear Loed,

Offset -1 and -7 are two values which covers my all conditions like 2014001  ---> 2013004, 2014003  --> 2014002.

For time being as suggested by  @Leslaw, I have given two selection parameters at the input fields.

Regards,

Abhishek Jain

Loed
Active Contributor
0 Kudos

Hi Abhishek,

You need -9 in order to achieve 2013004 from 2014001, right? How did you get 2013004 from 2014001 by just using -1 or -7?

Regards,

Loed

former_member194898
Active Contributor
0 Kudos

Hi,

In column no one restrict needed time characteristic (zquarter ?)  with variable ready for input.

In column no two restrict the same characteristic with exit variable I wrote before.

Tell us please if you have problem with it.

Regards, Leszek

sai_adapa
Participant
0 Kudos

HI Abhishek,

you need to create 3 restricted key figures.

1. RKF1 restricted with the selection screen fiscal quarter variable.

2. RKF2 restricted with the selection screen quarter variable - 1 ( off set value "-1").

3. RKF3 restrcited with selection screen quarter variable - 4 ( off set value "-4" ).

Display these 3 RKFs in the report.

User will enter the quarter that he want to see.

RKF2 and RKF3 calculated based on the selection screen value automatically

Regards,

Sai

former_member351149
Participant
0 Kudos

Dear Leslaw,

I have used three RKF's and provided two input selections for quarter in first two RKF's then in the third RKF's used offset -10 which full fill my requirement.

Regards,

Abhishek Jain

former_member183241
Active Participant
0 Kudos

Hi Abhishek,

You can compare balance sheet quarterly by adding two KF twice in the report like current quarter and previous quarter with condition, refer below screen shot.

Thanks,

Kashif Ali Khan

former_member182346
Active Contributor
0 Kudos

Hi,

Looking at the requirement it seems that you need comparison.

So why to use both the conditions in single KF (Column).

Use 2 column with condition separately and compare the data.

Also please check the value of the fiscal year quarter in your cube. Generally they are 1,2,3,4.

SO your -7 offset condition can also be issue.

I will suggest just remove the offset 7 condition and just keep the offset 1, and see whether you are getting desired output.

Thank-You.


Regards,

VB