Skip to Content
0
Former Member
Jan 06, 2011 at 11:29 AM

Excluding the vaues of Internal table while retreiving data from data base

836 Views

Dear all,

i had a problem while retreiving data from BKPF table. my problem i will get a list of values from the search help and i had written the following code in my search help exit to exclude the values of table tt_vblnr which is retreived from payer.

I want to get the values other than the retreived values from the search help .

when i am writing the following code it is excluding the values of BUKRS and GJAHR but not considering the BELNR value but if i am giving the BELNR value alone in for all entries it is not cosidering that and displaying all values.

select bukrs

belnr

gjahr

budat from bkpf into table tt_bkpf

FOR ALL ENTRIES IN tt_vblnr

where

( bukrs eq tt_vblnr-zbukr

and belnr ne tt_vblnr-vblnr

and gjahr eq tt_vblnr-gjahr )

and blart = 'KZ' .

can any one help me out how to solve the situation

i tried using ranges but it did not help