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

Range

kiran_k8
Active Contributor
0 Likes
796

r_kschl-sign = 'I'.

r_kschl-option = 'EQ'.

r_kschl-low = 'JEC1'.

APPEND r_kschl.

r_kschl-low = 'JEC2'.

APPEND r_kschl.

r_kschl-low = 'JM01'.

APPEND r_kschl.

r_kschl-low = 'JM02'.

APPEND r_kschl.

......

....

...........

IF NOT itab3[] IS INITIAL.

CLEAR: R_KSCHL,ITAB3.

SELECT belnr AS belnr1

mwskz

hwbas

hwste

kschl

kbetr

FROM bset INTO CORRESPONDING FIELDS OF TABLE itab4

FOR ALL ENTRIES IN itab3

WHERE belnr = itab3-belnr1

AND kschl IN r_kschl

AND kbetr NE 0.

ENDIF.

I need to fetch all the conditon types declared in the range but it is fetching me only one.How a range works?

Thanks,

K.Kiran.

7 REPLIES 7
Read only

Former Member
0 Likes
759

hi

write it like dis

r_kschl-sign = 'I'.

r_kschl-option = 'EQ'.

r_kschl-low = 'JEC1'.

APPEND r_kschl.

r_kschl-sign = 'I'.

r_kschl-option = 'EQ'.

r_kschl-low = 'JEC2'.

APPEND r_kschl.

r_kschl-sign = 'I'.

r_kschl-option = 'EQ'.

r_kschl-low = 'JM01'.

APPEND r_kschl.

r_kschl-sign = 'I'.

r_kschl-option = 'EQ'.

r_kschl-low = 'JM02'.

APPEND r_kschl.

Read only

0 Likes
759

Will,

IN debuggin R_KSCHL is having both the condition types but while fetchng the data using select query it is fetching only JEC1.

K.Kiran.

Read only

0 Likes
759

kiran

check ur select query if it is

where < > IN R_KSCHL

Read only

Former Member
0 Likes
759

hi,

Append all entries like first one only.

r_kschl-sign = 'I'.

r_kschl-option = 'EQ'.

r_kschl-low = 'JEC1'.

APPEND r_kschl.

r_kschl-sign = 'I'.

r_kschl-option = 'EQ'.

r_kschl-low = 'JEC2'.

APPEND r_kschl.

r_kschl-sign = 'I'.

r_kschl-option = 'EQ'.

r_kschl-low = 'JM01'.

APPEND r_kschl.

r_kschl-sign = 'I'.

r_kschl-option = 'EQ'.

r_kschl-low = 'JM02'.

APPEND r_kschl.

Read only

seshatalpasai_madala
Product and Topic Expert
Product and Topic Expert
0 Likes
759

Hi,

Run an SQL trace (ST05) and check if the query is getting executed in the same way as you want it. Also make sure that the table has other conditions which are checking for, that is there are values in the table as per your condition.

Regards

Sesh

Read only

arpit_shah
Contributor
0 Likes
759

hi,

try like this,

e.g

ranges : temp for mkpf-budat.

temp-low = from_date.

temp-high = to_date.

append temp to temp.

now pass this temp in like ur using select-options.

i.e.

select field ..into..

where

date in temp.

Regards,

Arpit.

Read only

Former Member
0 Likes
759

check ur table itab3 with which u are fetching values. check whether the lines u r fetching based on this table have kschl with all values defined in ur range.

Rgds

Sathar