Application Development 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: 

no data

Former Member
0 Kudos

Guy's

pls help me, when i go to table plko

and pass data to following field (plnty,plnnr,plnal,

werks) ,i get status value ,but when i execute

following statement

SELECT SINGLE * FROM PLKO

WHERE PLNTY = 'N' "CAUFVD-PLNTY

AND PLNNR = '15294' "CAUFVD-PLNNR

AND PLNAL = '01' "CAUFVD-PLNAL

AND WERKS = '2001'. "CAUFVD-WERKS .

write PLKO-STATU.

i am not getting status value,why?

10 REPLIES 10

former_member181966
Active Contributor
0 Kudos

DID you check the table PLKO in SE11 and SE16 with same combination you`re passing in Select . Does it has data ?

Former Member
0 Kudos

try to give plnnr value = '00015294'

if the fetching is succesful, with the above value of PLNNR, then use conversion exit for this field before sending the value to SELECT Statement.

regards

srikanth

Message was edited by: Srikanth Kidambi

sunilachyut
Contributor
0 Kudos

Precede the PLNNR with 0's, so you might want to try with '00015294' and execute the query. Normally SAP performs coversion before it selects the output for SE16, in your case since you are passing string literals, its unable to find the record.

Hope it helps.

Sunil Achyut

Former Member
0 Kudos

Hi Sanju,

try this.

SELECT * FROM PLKO

WHERE PLNTY = 'N' "CAUFVD-PLNTY

AND PLNNR = '15294' "CAUFVD-PLNNR

AND PLNAL = '01' "CAUFVD-PLNAL

AND WERKS = '2001'. "CAUFVD-WERKS .

ENDSELECT.

Regards,

Vicky

0 Kudos

Guy's

i tried using FM CONVERSION_EXIT_ALPHA_INPUT,FOR field

plnnr,and plnal but no use

0 Kudos

Try this and see if it works

SELECT SINGLE * FROM PLKO INTO L_WA_PLKO

WHERE PLNTY = 'N' "CAUFVD-PLNTY

AND PLNNR = '00015294' "CAUFVD-PLNNR

AND PLNAL = '01' "CAUFVD-PLNAL

AND WERKS = '2001'. "CAUFVD-WERKS .

Write 😕 L_WA_PLKO-STATU.

0 Kudos

Hi Sanju,

When i tried using the same select statement, I am getting the status displayed.

I tried both ways and it looks fine.

tables: plko.

data: l_wa_plko type table of plko with header line.

SELECT SINGLE * FROM PLKO INTO L_WA_PLKO

WHERE PLNTY = 'N' "CAUFVD-PLNTY

AND PLNNR = '00000005' "CAUFVD-PLNNR

AND PLNAL = '01' "CAUFVD-PLNAL

AND WERKS = '2000'. "CAUFVD-WERKS .

Write 😕 L_WA_PLKO-STATU.

<b>OR</b>

tables: plko.

SELECT SINGLE * FROM PLKO

WHERE PLNTY = 'N' "CAUFVD-PLNTY

AND PLNNR = '00000005' "CAUFVD-PLNNR

AND PLNAL = '01' "CAUFVD-PLNAL

AND WERKS = '2000'. "CAUFVD-WERKS .

write PLKO-STATU.

check your code one more time as it works for me.

Regards,

Vicky

Former Member
0 Kudos

use the conversion exit CONVERSION_EXIT_ALPHA_INPUT to convert the field plnnr before you pass it to the select

Former Member
0 Kudos

hi,

the dataelement of PLNNR has conversion exit. so there should be leading zeros. use a variable and the conversion exit FM , you will get result.

Sudheer.A

Former Member
0 Kudos

pass this data into a work area of type plko

and then check out

e.g select * into wa_plko

from plko

WHERE PLNTY = 'N' "CAUFVD-PLNTY

AND PLNNR = '00015294' "CAUFVD-PLNNR

AND PLNAL = '01' "CAUFVD-PLNAL

AND WERKS = '2001'. "CAUFVD-WERKS .