11-11-2010 11:15 AM
Hello,one of my report program can't select data from my customize
table 'ZLIKP',the related part of source code is as below:
SELECT b~LFDAT AS WADAT
b~VBELN
b~VGBEL
b~KUNRG AS KUNNR
a~POSNR
a~LFIMG
b~LIFSK
a~MATNR
a~PSPNR
INTO CORRESPONDING FIELDS OF TABLE detail_itab
FROM ZLIKP AS b inner JOIN ZLIPZ AS a ON aVBELN = bVBELN
inner JOIN VBAK AS C ON CVBELN = AVGBEL
WHERE
a~VGBEL IN S_VGBEL
AND b~VBELN IN S_VBELN
AND b~KUNRG IN S_KUNNR
AND b~LFDAT IN S_WADAT
AND C~AUART IN S_AUART.
*********************************************************
when i don't fill the selection variant S_KUNNR and run the program,it
can select data from table ZLIKP,if i fill,it can't ,but table ZLIKP
has some reords that meets the select criteria actually,if i use this way:AND b~KUNRG = '100001',it also can select data from ZLIKP.
And then,i found the customize table has some problem,i run tcode
SE11,browse the table zlikp,i also can't select data from this
table directly,i fill the KUNRG variant,click 'number of entries' ,it show up the entries is zero.someone can help me?
11-11-2010 11:23 AM
Hi,
Possible options:
1) Go to SE14, Generate and Save the table. OR
2) Delete the table maintenance and recreate the same, then you enter the data into the table.
Regards
Shiva
11-11-2010 3:07 PM
Someone has replaced standard SAP delivery tables with Z versions? Good way to end a budding SAP/IT career.
11-11-2010 3:30 PM
ZLIKP-KUNRG likely has a conversion exit associated with it. You'll have to take that into account when doing your SELECT.
Rob
11-11-2010 3:47 PM
Hi,
If the table configuration is ok,
Can yo try to create S_KUNNR for LIKP-KUNAG instead of KNA1-KUNNR or so.
Please update..
Thanks,
Anmol.
11-12-2010 2:32 AM
thank you guys,i find out the solution now,the customize table didn't add the leading zero to the KUNRG filed,and the S_KUNNR has the leading zero,so KUNRG didn't match S_KUNNR,therefor,it can't fetch data from table.