on 10-27-2015 2:18 PM
Hello Everybody,
Below-written code has generating error like "E:"L_T_UCPREMISE" is a table without a header line and therefore has no component called "UC_POD"", which i am no sure the underlying error.
DATA: l_t_result_package LIKE result_package,
l_s_result_package LIKE LINE OF l_t_result_package.
TYPES: BEGIN OF ltype_work_area,
ucinstalla TYPE /bi0/oiucinstalla,
ucpremise TYPE /bi0/oiucpremise,
uc_connobj TYPE /bi0/oiuc_connobj,
postcd_gis TYPE /bi0/oipostcd_gis,
uc_pod_ext TYPE /bi0/oiuc_pod_ext,
END OF ltype_work_area.
* DATA: ls_work_area LIKE ltype_work_area,
Data:
l_t_ucinstalla type table of /bi0/pucinstalla,
l_t_ucpremise type table of /bi0/pucpremise,
l_t_uc_connobj type table of /bi0/puc_connobj,
l_t_uc_pod type table of /bi0/muc_pod.
DATA: l_s_ucinstalla LIKE LINE OF l_t_ucinstalla,
l_s_ucpremise LIKE LINE OF l_t_ucpremise,
l_s_uc_connobj LIKE LINE OF l_t_uc_connobj,
l_s_uc_pod LIKE LINE OF l_t_uc_pod.
SELECT * FROM /bi0/pucinstalla
INTO CORRESPONDING FIELDS OF TABLE l_t_ucinstalla
FOR ALL ENTRIES IN result_package
WHERE ucinstalla = result_package-ucinstalla
AND objvers = 'A'
AND soursystem = 'L1'.
SELECT * FROM /bi0/mucpremise
INTO CORRESPONDING FIELDS OF TABLE l_t_ucpremise
FOR ALL ENTRIES IN result_package
WHERE ucpremise = l_t_ucpremise-uc_pod
AND objvers = 'A'
AND soursystem = 'L1'.
SELECT * FROM /bi0/puc_connobj
INTO CORRESPONDING FIELDS OF TABLE l_t_uc_connobj
FOR ALL ENTRIES IN result_package
WHERE uc_connobj = l_t_uc_connobj-uc_connobj
AND objvers = 'A'
AND soursystem = 'L1'.
SELECT * FROM /bi0/muc_pod
INTO CORRESPONDING FIELDS OF TABLE l_t_uc_pod
FOR ALL ENTRIES IN result_package
WHERE uc_pod = l_t_uc_pod-uc_pod
AND objvers = 'A'
AND soursystem = 'L1'.
LOOP AT l_t_result_package INTO l_s_result_package.
READ TABLE l_t_ucinstalla WITH KEY
ucinstalla = l_s_result_package-ucpinstalla
soursystem = 'L1'
objvers = 'A'.
READ TABLE l_t_ucpremise WITH KEY
ucpremise = l_s_result_package-ucpremise
soursystem = 'L1'
objvers = 'A'.
READ TABLE l_t_uc_connobj WITH KEY
uc_connobj = l_s_result_package-uc_connobj
soursystem = 'L1'
objvers = 'A'.
READ TABLE l_t_uc_pod WITH KEY
uc_pod = l_s_result_package-uc_pod
soursystem = 'L1'
objvers = 'A'.
IF sy-subrc EQ 0.
l_s_result_package-uc_installa = l_s_uc_istalla-uc_installa.
l_s_result_package-uc_connobj = l_s_uc_connobj-uc_connobj.
l_s_result_package-postcd_gis = l_s_uc_connobj-postcd_gis.
l_s_result_package-uc_pod_ext = l_s_uc_pod-uc_pod_ext.
APPEND l_s_result_package TO result_package.
ENDLOOP.
I would kindly request your help on the relevant correction on the syntax.
Regards.
Eddy
Hi Eddy
In you below code, you should use result package instead of the internal table.
SELECT * FROM /bi0/mucpremise
INTO CORRESPONDING FIELDS OF TABLE l_t_ucpremise
FOR ALL ENTRIES IN result_package
WHERE ucpremise = result_package-uc_pod
AND objvers = 'A'
AND soursystem = 'L1'.
Try and let us know if it works.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
You may also do the same for the following SELECT statements which will also cause same error..
SELECT * FROM /bi0/puc_connobj
INTO CORRESPONDING FIELDS OF TABLE l_t_uc_connobj
FOR ALL ENTRIES IN result_package
WHERE uc_connobj = RESULT_PACKAGE-uc_connobj
AND objvers = 'A'
AND soursystem = 'L1'.
SELECT * FROM /bi0/muc_pod
INTO CORRESPONDING FIELDS OF TABLE l_t_uc_pod
FOR ALL ENTRIES IN result_package
WHERE uc_pod = RESULT_PACKAGE-uc_pod
AND objvers = 'A'
AND soursystem = 'L1'.
Regards,
Loed
Hello everybody,
As you mentioned right, those code parts should be replaced with RESULT_PACKAGE.
However I am receiving further below error for the same code.
I would like to ask for your little help.
E:Specify either "INTO wa", "ASSIGNING", "REFERENCE INTO", or "TRANSPORTING NO FIELDS" addition
Thanks
Regards.
Eddy
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
That was my mistake.
The work area for l_t_ucinstalla is ucinstalla. You should have proper naming convention. If its a work area, start it with wa. it will easier for understanding and future corrections.
Try this code now.
READ TABLE l_t_ucinstalla INTO ucinstalla WITH KEY
ucinstalla = l_s_result_package-ucpinstalla
soursystem = 'L1'
objvers = 'A'.
Regards
Karthik
Hi Eddy,
these are internal tables
l_t_ucinstalla type table of /bi0/pucinstalla,
l_t_ucpremise type table of /bi0/pucpremise,
l_t_uc_connobj type table of /bi0/puc_connobj,
l_t_uc_pod type table of /bi0/muc_pod.
these are work area
DATA: l_s_ucinstalla LIKE LINE OF l_t_ucinstalla,
l_s_ucpremise LIKE LINE OF l_t_ucpremise,
l_s_uc_connobj LIKE LINE OF l_t_uc_connobj,
l_s_uc_pod LIKE LINE OF l_t_uc_pod.
so for internal table l_t_ucinstalla Work area is : l_s_uc_istalla
READ TABLE l_t_ucinstalla into l_s_uc_istalla WITH KEY
ucinstalla = l_s_result_package-ucpinstalla
soursystem = 'L1'
objvers = 'A'.
similarly check your other Read statements.
User | Count |
---|---|
87 | |
10 | |
10 | |
10 | |
7 | |
6 | |
6 | |
5 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.