on 10-08-2008 9:29 PM
Hi,
I have implemented ON_data_check event for inserted, deleted & modified rows. The tables R_PARAM->T_INSERTED_ROWS,
R_PARAM->T_DELETED_ROWS & R_PARAM->T_MODIFIED_ROWS are getting populated. But I don't know how to get the data which user has entered/deleted/modified. Bcoz I could not find the data in the above mentioned tables.
Pls suggest...
Thanks,
The data is there. It is in the R_VALUE column of the associated parameter. However this column is generically types as TYPE REF TO DATA. Therefore it needs to be cast into a data type with the specific structure of your context node in order to read the values. If you want to see this for yourself, set a breakpoint in the on_data_check event handler and have a look at the values in the debugger. They will show the assocated acutal type.
you will have to an ASSIGN R_PARAM->T_MODIFIED_ROWS -R_VALUE->* to <wa_struc>.
where <wa_struct> is a field system declared like your actual line type. For instance if your ALV was for SFLIGHT:
field-symbols <wa_struct> type SFLIGHT.
This is done generically so that there can be a fixed interface to the event parameter yet still support any data structure in the ALV.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Ok, now I m getting the values in r_value, but i have two more question. Even if i use 'Insert Rows', then t_modified_cells rows is getting populated. Is this designed like this? Becuase what i assume is t_modified cells should be populated when we change the value in cell. I think it's like the normal MODIFY sql statement. Pls suggest.
One more thing, in t_modified_cells the values which are getting populated in R_value and r_old_value starts with '->'. Is this normal also?
Pls answer both of my questions
Thanks,
>Is this designed like this?
I would assume so. That approach makes sense to me.
>One more thing, in t_modified_cells the values which are getting populated in R_value and r_old_value starts with '->'. Is this normal also?
You mean in the debugger, right? This is done in the debugger to signify that the are field references (the TYPE REF TO DATA that I explained earlier).
User | Count |
---|---|
94 | |
11 | |
11 | |
10 | |
9 | |
8 | |
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.