Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

ABAP Programmin

Former Member
0 Likes
648

Hi,

Could you guys please give me some codin to fetch all the tcodes which begins with ZPR..?

please please please...

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
621

Hi Nalina,

You can do one thing declare a range and in the assign the values sign as 'I' Options as 'CP' and low value as 'ZPR*' and write a select statement for the table TSTC. Then you can obtain the required output.

Please reward pints if I am correct.

Please let me know if i am wrong.

Thanks & Regards,

M.Ramana Murthy.

Edited by: Ramana Murthy on Apr 30, 2008 8:31 AM

5 REPLIES 5
Read only

Former Member
0 Likes
621

hi

use the table TSTC to fetch the tcodes.

here is the sample code:

tables: tstc.

DATA: V_STR(20).

CONCATENATE 'Z' '%' INTO V_STR.

SELECT * UP TO 10 ROWS

FROM TSTC

WHERE tcode LIKE V_STR.

WRITE: / tstc-tcode.

ENDSELECT.

regards,

madhu

Read only

0 Likes
621

hi

check this one

data:

begin of itab occurs 0,

t_code like tstc-tcode.

end of itab.

select tcode

from tstc

into table itab

where tstc-tcode like 'zpr%'.

Read only

Former Member
0 Likes
622

Hi Nalina,

You can do one thing declare a range and in the assign the values sign as 'I' Options as 'CP' and low value as 'ZPR*' and write a select statement for the table TSTC. Then you can obtain the required output.

Please reward pints if I am correct.

Please let me know if i am wrong.

Thanks & Regards,

M.Ramana Murthy.

Edited by: Ramana Murthy on Apr 30, 2008 8:31 AM

Read only

Former Member
0 Likes
621

Hi nalini,

data : Begin of it_tstc occurs 0,

tcode type TCODE,

End of it_tstc.

select tcode from tstc into table it_tstc where tcode like 'ZPR%'.

This statement will fetch all the tcodes starting with ZPR.

Read only

Former Member
0 Likes
621

Thnx for the answers