2007 Jul 03 10:03 AM
Hi,
I can't use this code because EBELP and VGPOS are not the same...
EBELP --> EBELP NUMC 5 0 Item Number of Purchasing Document
VGPOS --> VGPOS NUMC 6 0 Item number of the reference item
DATA: ls_likp TYPE likpvb,
it_lips TYPE tab_lipsvb,
ls_lips TYPE lipsvb.
DATA: gt_ekpo TYPE STANDARD TABLE OF ekpo,
gs_ekpo TYPE ekpo.
SELECT *
FROM ekpo
INTO TABLE gt_ekpo
FOR ALL ENTRIES IN it_lips
WHERE ebeln EQ it_lips-vgbel
AND ebelp EQ it_lips-vgpos. -------------->> HERE IS THE PROBLEM
How to solve this?
regards,
Adibo.
2007 Jul 03 10:11 AM
Declare another internal table with
it_lips1.
vgbel LIKE lips-vgbel,
vgpos LIKE ekpo-ebelp.
itlips1.
LOOP AT itlips.
vgbel = itlips-vgbel.
vgpos = itlips-vgpos.
APPEND itlips1.
ENDLOOP.
Rest use the same code.
Hi,
I can't use this code because EBELP and VGPOS are not the same...
EBELP --> EBELP NUMC 5 0 Item Number of Purchasing Document
VGPOS --> VGPOS NUMC 6 0 Item number of the reference item
DATA: ls_likp TYPE likpvb,
it_lips TYPE tab_lipsvb,
ls_lips TYPE lipsvb.
DATA: gt_ekpo TYPE STANDARD TABLE OF ekpo,
gs_ekpo TYPE ekpo.
SELECT *
FROM ekpo
INTO TABLE gt_ekpo
FOR ALL ENTRIES IN it_lips
WHERE ebeln EQ it_lips-vgbel
AND ebelp EQ it_lips-vgpos. -------------->> HERE IS THE PROBLEM
How to solve this?
regards,
Adibo.
2007 Jul 03 10:07 AM
Hi,
In the internal table it_lips declare vgpos referring to ebelp.
This will solve ur problem.
Reward if helpful.
2007 Jul 03 10:12 AM
Can't do that,
it_lips TYPE tab_lipsvb,
Table Type TAB_LIPSVB
Table Type for SD Document: Ref. Structure for XLIPS/YLIPS
line type --> LIPSVB
LIPSVB--> Reference structure for XLIPS/YLIPS
2007 Jul 03 10:16 AM
Hi
If you want to use FOR ALL ENTRIES option, don't use the item for the selection, but the document number only:
SELECT * FROM ekpo INTO TABLE gt_ekpo
FOR ALL ENTRIES IN it_lips
WHERE ebeln EQ it_lips-vgbel.
*AND ebelp EQ it_lips-vgpos. -------------->> HERE IS THE PROBLEMMax
2007 Jul 03 10:08 AM
yes you can not use it ...because the domain is not same .
only the fieds having same domain shoudl be used .
SELECT bukrs belnr gjahr buzei mwskz umsks prctr hkont xauto koart
dmbtr mwart hwbas aufnr projk shkzg kokrs
FROM bseg
INTO TABLE it_bseg
FOR ALL ENTRIES IN it_bkpf
WHERE bukrs EQ it_bkpf-bukrs AND
belnr EQ it_bkpf-belnr AND
gjahr EQ it_bkpf-gjahr.
reward points if it is usefull ...
Girish
2007 Jul 03 10:11 AM
Declare another internal table with
it_lips1.
vgbel LIKE lips-vgbel,
vgpos LIKE ekpo-ebelp.
itlips1.
LOOP AT itlips.
vgbel = itlips-vgbel.
vgpos = itlips-vgpos.
APPEND itlips1.
ENDLOOP.
Rest use the same code.
2007 Jul 03 10:17 AM
Hi,
this because ebelp is type char 10
and vgpos is type numc 6 so the error is because of type mismatch.
To avoid this in it_lips declare
vgpos type ekpo-ebelp.
regards,
sudha
| User | Count |
|---|---|
| 4 | |
| 2 | |
| 2 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |