‎2009 Apr 15 11:05 AM
Hi All,
I'm creating a Query to extract the data from EKKO, EKPO and EKKN.
here I have to insert a piece of code as checking below.
IF EKPO-KNTTP ne ' '. "not equal to blank
extract the data from table EKKN.
ENDIF.here I need your help like how to write this code in a Query.
Thanks,
Sunil Bodda.
Edited by: sunil bodda on Apr 15, 2009 12:05 PM
‎2009 Apr 15 11:21 AM
select the query and go to QUERY in the menubar then goto more functions where you have an option display report name it will give you the report name.
Menubar ---> Quer ---> MoreFunctions ----> Display Reportname.
Goto SE80/SE38-->Report name and add the Codes in the program.Regards,
gurpreet
‎2009 Apr 15 1:02 PM
Hi,
In SAP Queries, all the code will be written in infosets. Identify under which event your code should be written and made it.
Once done, generate infoset and query in sequence and execute.
Regards,
Prasanth
Edited by: Prasanth Ponnaganti on Apr 15, 2009 2:02 PM
‎2009 Apr 15 7:35 PM
Hi Sunil,
You need to code it in infoset. follow the steps below.
1. Goto SQ02, enter your infoset.
2. Click on "Extras" button(above find button). On the next page you will find a "Code" tab.
3. Declare a constant as space. choose DATA in the drop down for coding section.
4. Choose "Record processing" or if any other appropriate choice from the drop down in the coding section.
5. CHECK EKPO-KNTTP EQ c_space. and write your code here.
Hope this helps.
‎2009 Apr 16 6:20 AM
Hi Sunil,
To write any code in a query, please follow these steps :
1. Create InfoSet by using t-code SQ02 give the name of the Infooset
2. Select redio button direct read from table(Your table name).
3. Select redio button include all key feilds.
4. Press 'code' (Shift+f8) .
There you get ABAP Editor, here you can write your own code.
Thanks.
Regards,
Lokesh.