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

Error while releasing object to quality server

Former Member
0 Likes
938

Hi,

I have written follo select stmt ,

SELECT BELNR "Case1

GJAHR

EBELN

EBELP

DMBTR FROM EKBE

INTO TABLE IT_EKBE

FOR ALL ENTRIES IN IT_BKPF2

WHERE BELNR = IT_BKPF2-AWKEY+0(10).

When doing syntax chk , getting warning as "Lenth specification of AWKEY is ignored when FOR ALL ENTRIES IN used".

I activated the object.

Bur while releasing it to quality , in Code inspector 1 error is coming saying

"Large table EKBE : No first field of a table index in WHERE condition".But still i managed to release it.

What is the meaning of that Error. Is it that i m not using a primary key in WHERE cond while accessing a huge table EKBE ?

Is it going to impact anywhere in quality or production server as requset got released with ERROR ?

How to remove such errors which r appearing in code inspector and not in Syntax check.

Waiting 4 ur replies ....

Thanks,

Poonam.

3 REPLIES 3
Read only

former_member404244
Active Contributor
0 Likes
501

HI,

FOR ALL entries expects fields of same length...

U need to change ur code..Put a field of type belnr and pass the values

loop at it_bkpf2.

it_bkpf2-belnr = IT_BKPF2-AWKEY+0(10).

modify it_bkpf2.

endloop.

SELECT BELNR "Case1

GJAHR

EBELN

EBELP

DMBTR FROM EKBE

INTO TABLE IT_EKBE

FOR ALL ENTRIES IN IT_BKPF2

WHERE BELNR = IT_BKPF2-belnr.

Regards,

Nagaraj

Read only

Former Member
0 Likes
501

There will not be any problem with this code in any servers.

but the error you getting in code inspector is because you have not included all key fields of the table in where condition so the index will not be used in the query.

if you use all key fields of table in where condition then the index gets fired internally and the data retrieval becomes faster.

it will not impact anywhere in the system but have a practise to use all key fields of tables in where condition wherver possible.

Read only

nitesh_jain3
Active Participant
0 Likes
501

Hi,

Code Inspector checks can be performed using the Extended Program Check in SE38 for the program. Code inspector results are suggestions as per good programming practices. You might face performance problems in larger systems if your where clause is not following an index.

In this specific case you can have logical errors also as you might have the same FI doc number across different financial years.

Cheers

Nitesh