‎2006 Aug 10 1:37 AM
Hi experts.
I always appreciate your help. Today, I have some problem. I made infoset query using SQ01 and got some data. Those data include WBS no but some of them didn't. So I tried to put some code into the infoset query that any data has not WBS has some value, for example 'X', in WBS no field.
I needed to know what field or table I should control to display value 'X' in WBS no field in case that WBS field has no value.
I tried to put code at "END-OF-SELECTION(before display)" and control %dtab. But I met error message there is no such table %dtab. So, I define %dtab then during runtime, I also met error message %dtab has already been defiend.
How can I do? Is it impossible thing?? I'm wating for your answer.
regards.
‎2006 Aug 10 1:48 AM
Hi, if you just want to fill the field if it is blank, you can do this in the Record Processing Section.
I'm not familar with the WBS number, so for this example, I will fill the BISMT in MARA during the "Recording Processing" Section.
if mara-bismt is initial.
mara-bismt = 'X'.
endif.Regards,
Rich Heilman
‎2006 Aug 10 1:47 AM
Instead of updating program, you can update infoset which is used. I assume you have created custom infoset for your query. We can add ABAP routines in Infoset. Have you tried this option? If you click on EXTRAS in infoset, you can add new fields. Add a custom field which will be populated with text or so 'No WBS Element', if there is no WBS element. You can write a small ABAP routine for this. This is one option for you.
‎2006 Aug 10 1:48 AM
Hi, if you just want to fill the field if it is blank, you can do this in the Record Processing Section.
I'm not familar with the WBS number, so for this example, I will fill the BISMT in MARA during the "Recording Processing" Section.
if mara-bismt is initial.
mara-bismt = 'X'.
endif.Regards,
Rich Heilman
‎2006 Aug 10 1:50 AM
In the infoset, right click on the node which represents the table which you want to work with. THis is on the left hand side. Right click on it and choose, "Code for Record Process", In the right hand side of the screen, you should now see an editor. Here is where you can put your code to modify the field. You can access the field directly like I've done above.
REgards,
Rich Heilman