2009 Feb 12 9:20 AM
Hello all,
Can any one tell me how to execute Native SQL queries from ABAP.
Thanks in advance.
Best Regards,
Sasidhar Reddy Matli.
2009 Feb 12 9:31 AM
Hi,
Write your SQL queries in between Exec Sql and EndExec.
Here's sample code:
data: begin of itab occurs 0,
matnr like makt-matnr,
maktx like makt-maktx,
end of itab.
exec sql.
select matnr, maktx from makt into :itab
endexec.
loop at itab.
write:/ itab-matnr, itab-maktx.
endloop.Check in Help/ for more info.
Cheers\
Mahesh
Hello all,
Can any one tell me how to execute Native SQL queries from ABAP.
Thanks in advance.
Best Regards,
Sasidhar Reddy Matli.
2009 Feb 12 9:23 AM
check this.
[http://help.sap.com/saphelp_nw04/helpdata/en/51/ef9f94e4ba894d8e93b2eed7c9f82d/frameset.htm]
2009 Feb 12 9:27 AM
Hi,
Check out below link for ABAP.
http://help.sap.com/saphelp_nw04/helpdata/EN/fc/eb3b8b358411d1829f0000e829fbfe/content.htm
Regards,
Vishal
2009 Feb 12 9:28 AM
2009 Feb 12 9:29 AM
Hi,
Kindly go through these link below:
http://help.sap.com/saphelp_nw04/helpdata/EN/fc/eb3b8b358411d1829f0000e829fbfe/content.htm
Hope it helps
Regrds
Mansi
2009 Feb 12 9:31 AM
Hi,
Write your SQL queries in between Exec Sql and EndExec.
Here's sample code:
data: begin of itab occurs 0,
matnr like makt-matnr,
maktx like makt-maktx,
end of itab.
exec sql.
select matnr, maktx from makt into :itab
endexec.
loop at itab.
write:/ itab-matnr, itab-maktx.
endloop.Check in Help/ for more info.
Cheers\
Mahesh
| User | Count |
|---|---|
| 6 | |
| 2 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |