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: 

select query

former_member587342
Participant
0 Kudos

Hi Experts

I have one scenario i need to pass ebeln to ekpo so we need to get bednr associated with it.then i need to pass this bednr to ekpo-bednr so we will get all po's assocaited with this bednr.

I ma getting error. could you please help me out to achieve this.

so i have write query like this

data: lv_po type ekpo-bednr.

select bednr from ekpo into lv_po where ebeln = po_number.(po_number is the attriubute

4 REPLIES 4

srikanthnalluri
Active Participant

Read the Documentation - https://help.sap.com/doc/abapdocu_750_index_htm/7.50/en-US/abapselect.htm

Either you need to write SELECT SINGLE or Close the set using ENDSELECT.

tan_michael
Active Participant
0 Kudos

Hi,

I think you should use SELECT SINGLE..

0 Kudos

select single bednr

from ekpo

into lv_po

where ebeln = po_number.

matt
Active Contributor

"Getting an error" is not really sufficient detail.