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

RSQL error 23

Former Member
0 Likes
1,804

Dear Friends,

I am getting this error while i am accessing EKPO table. RSQL error 23 when accessing table EKPO, while I am performing interactive reports. Please help me.

Thank you

1 ACCEPTED SOLUTION
Read only

Kanagaraja_L
Active Contributor
1,381

Check you WHERE condition in SQL statement.

Can you paste the piece fo SQL code ?

Kanagaraja L

8 REPLIES 8
Read only

Former Member
0 Likes
1,381

Hi,

Are you getting this dump on a select query? If so check the attributes of the internal table fields are compatible with that of the fields of table EKPO.

Regards,

Vikranth

Read only

Kanagaraja_L
Active Contributor
1,382

Check you WHERE condition in SQL statement.

Can you paste the piece fo SQL code ?

Kanagaraja L

Read only

0 Likes
1,381

Moderator message - Please respect the 2,500 character maximum when posting. Post only the relevant portions of code

Edited by: Rob Burbank on Sep 3, 2009 1:47 PM

Read only

0 Likes
1,381

>

> Check you WHERE condition in SQL statement.

>

> Can you paste the piece fo SQL code ?

>

> Kanagaraja L

CLEAR V_FNAM.
      GET CURSOR FIELD V_FNAM VALUE V_FVAL_EBELN.
      IF V_FNAM = 'WA_EKKO-EBELN'.
*** CONVERTING FROM EXTERNAL TO INTERNAL FORMAT
        CALL FUNCTION 'CONVERSION_EXIT_ALPHA_INPUT'
          EXPORTING
            INPUT  = V_FVAL_EBELN
          IMPORTING
            OUTPUT = V_FVAL_EBELN.


*** DISPLAY LINE ITEM ***
        SELECT EBELN EBELP MATNR MENGE NETPR FROM EKPO INTO CORRESPONDING FIELDS OF TABLE IT_EKPO
              WHERE EBELN = V_FVAL_EBELN.
        IF NOT IT_EKPO IS INITIAL.
          LOOP AT IT_EKPO INTO WA_EKPO.
            AT FIRST.
              FORMAT COLOR 5.
              WRITE:/3'ITEM NO OF PURCHASE DOCUMENT FROM EKPO TABLE'.
              FORMAT COLOR 5 OFF.
              ULINE.
              WRITE:/3'PURDOC.NO',15 'ITEM.NO',25 'MAT.NO',45 'QUANTITY',65'NETPRICE'.
              ULINE.
            ENDAT.
            WRITE:/3 WA_EKPO-EBELN,15 WA_EKPO-EBELP,25 WA_EKPO-MATNR." 45 WA_EKPO-MENGE,65 WA_EKPO-NETPR .
            CLEAR WA_EKPO.
          ENDLOOP.

        ELSE.
          WRITE:/3'NO RECORDS FOUND FOR THE SELECTED RECORD'.

        ENDIF.
      ENDIF.

Read only

0 Likes
1,381

It may be that the fields of table IT_EKPO are not the same as the database fields. How is this table declared?

Rob

Read only

0 Likes
1,381

THIS IS DECLARATION PART


TYPES : BEGIN OF TY_EKPO,
          EBELN TYPE EBELN,
          EBELP TYPE EBELP,
          MATNR TYPE MATNR,
          MENGE TYPE MENGE,
          NETPR TYPE NETPR,
        END OF TY_EKPO.
DATA : IT_EKPO TYPE TABLE OF TY_EKPO,
       WA_EKPO LIKE LINE OF IT_EKPO.

Read only

0 Likes
1,381

Hi,

Change the types declaration to this and check,


TYPES : BEGIN OF TY_EKPO,
          EBELN TYPE EKPO-EBELN,
          EBELP TYPE EKPO-EBELP,
          MATNR TYPE EKPO-MATNR,
          MENGE TYPE EKPO-MENGE,
          NETPR TYPE EKPO-NETPR,
        END OF TY_EKPO.
DATA : IT_EKPO TYPE TABLE OF TY_EKPO,
       WA_EKPO LIKE LINE OF IT_EKPO.

Regards,

Vikranth

Read only

Clemenss
Active Contributor
0 Likes
1,381

Hi jyotnsna,

vrikanth is right about the declaration. MENGE is a structure with the fields

MATNR

MEINH

UMREZ

UMREN

EANNR

EAN11

NUMTP

LAENG

BREIT

HOEHE

MEABM

VOLUM

VOLEH

BRGEW

GEWEI

ATINN

KZWSO

MSEHI

wheras EKPO-MENGE is TYPE BSTMG.

This caused the trouble.

Regards,

Clemens