on 09-13-2017 3:19 PM
Hello,
I want to process a customer exit variable wherein I can call both I_step =1 and I_step2 .
In istep1,i will set default values for the variable and in istep2 I will derive the value from another variables input.
Problem is when I run the Query,it only takes the default value set by istep 1. Istep2 is not being executed at all.
I have tried writing both isteps in different cases in CMOD but no change.
My Variables is Not ready for input and Customer exit.
Any Suggestions on this. Need a workaround urgently.
Regards,
Aditya
Hi,
I'm not sure it's been a long time since I've been using queries.
But I would say i_step 1 is not necessary for a not Input ready variable. A Default value is not needed because the variable is nevere be shown to the user.
So you can do everthing in the i_step 2.
May be the variable handling skip i_step 2 if the variable already been handeld in i_step 1?
But I'm not 100% sure. Try to handle the variable only in i_step 2.
If you sure the variable is set to not-Input-ready and part of the query and would not be handled in i_step 2 it's sounds like an error.
In that case I would open an incident.
Torsten
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Thanks for the reply torsten.
The variable is not ready for Input but we want both i.e a default value when query selections appear and then a dynamic value when a query runs.
So to achieve this, we wrote istep1 for default value and istep2 for dynamic value.
The problem is we are using this variable for currency translation in Planning Function in Integrated planning. So unless we give a default value to this Variable, it throws an error saying Variable has to be restricted to Single Value.
But our code in cmod,executes istep1 only.
Is it that only one istep is executed for a variable?
Hi,
Can you please post here your code so we can check if there is any code issue?
Regards,
Loed
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
Heres the code
Case i_vnam.
When = 'YGC'.
If i_step =1.
L_s_range-low = 'INR'.
L_s_range-Sign = 'I'.
L_s_range-opt ='EQ'.
append l_s_range to e_t_range
Endif.
If istep =2.
Read table i_t_var_range into loc_var_range with key v_nam = 'ZCCode'.
Select single ZCurr from Ztab into ZGC where
ZCCode = loc_var_range-low .
Loc_var_range-low = ZGC.
L_s_range-Sign = 'I'.
L_s_range-opt ='EQ'.
append l_s_range to e_t_range
Endif.
Endcase.
Problem is its not going to Istep 2 at all. We have tried different cases as well but no results
Because I don't want this variable in the selection screen.
Even if I make this variable ready for input then also the variable executes the Query with the default value in istep1 only,it doesn't get the istep2 value.
My Scenario is ,for a variable, I want a default value and then based on comp code fetch a dynamic value.
Hi,
try to add the bold marked line and try again.
Torsten
Case i_vnam.
When = 'YGC'.
If i_step =1.
L_s_range-low = 'INR'.
L_s_range-Sign = 'I'.
L_s_range-opt ='EQ'.
append l_s_range to e_t_range
c_check_again = 'X'.
Endif.
If istep =2.
Read table i_t_var_range into loc_var_range with key v_nam = 'ZCCode'.
Select single ZCurr from Ztab into ZGC where
ZCCode = loc_var_range-low .
Loc_var_range-low = ZGC.
L_s_range-Sign = 'I'.
L_s_range-opt ='EQ'.
append l_s_range to e_t_range
Endif.
Endcase.
Hi,
I'd tested it in the BAdI implementation and here the parameter is changed to c_check_again.
You can read more about that in my blog
Torsten
User | Count |
---|---|
95 | |
11 | |
10 | |
9 | |
9 | |
7 | |
6 | |
5 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.