Skip to Content
author's profile photo Former Member
Former Member

Short Dump while fetching values from a Database view

Hi ALL,

Here is the code that is giving short dump

SELECT * FROM ZVMATLMOVE INTO TABLE I_MATLMOVE

WHERE BUDAT >= V_LASTRUN_DATE

AND WERKS IN S_WERKS

AND LIFNR IN S_LIFNR

AND EBELN IN S_EBELN

AND MATNR IN S_MATNR

AND BWART IN S_BWART

(Please don't say that I am using * in the select query,

I knew that it is not a good way of fetching values)

Declaration of the internal table is:

DATA I_MATLMOVE LIKE ZVMATLMOVE OCCURS 0 WITH HEADER LINE.

The variable V_LASTRUN_DATE is:

DATA V_LASTRUN_DATE LIKE SY-DATUM.

We will be getting the lastrundate value from another table. And it is passing correct value (ex. 20060731)

ZVMATLMOVE is a database view created for MKPF and MSEG table. And I checked both table were consistent.

Dump Analysis:

Runtime errors DBIF_RSQL_SQL_ERROR

Exception CX_SY_OPEN_SQL_DB

Every thing is fine. But I don't know how it is going to dump. Any suggestions?

Add comment
10|10000 characters needed characters exceeded

4 Answers

  • author's profile photo Former Member
    Former Member
    Posted on Aug 03, 2006 at 02:32 PM

    I feel you should try into correponding fields of i_matlmove.

    Regards

    Anurag

    Add comment
    10|10000 characters needed characters exceeded

  • Posted on Aug 03, 2006 at 02:19 PM

    Everything looks ok to me. Not sure what the error is all about. Maybe try this to see if it makes a difference.

    SELECT * FROM ZVMATLMOVE 
         <b>INTO corresponding fields</b> of TABLE I_MATLMOVE
    WHERE BUDAT >= V_LASTRUN_DATE
    AND WERKS IN S_WERKS
    AND LIFNR IN S_LIFNR
    AND EBELN IN S_EBELN
    AND MATNR IN S_MATNR
    AND BWART IN S_BWART.

    Regards,

    Rich Heilman

    Add comment
    10|10000 characters needed characters exceeded

  • Posted on Aug 03, 2006 at 02:33 PM

    I've been looking around, I don't think the problem is in your code. I think this may be a db issue, and you may need to patch your system. Search OSS Notes for

    DBIF_RSQL_SQL_ERROR, you will see that a lot of times it talks about the db and fixing it with patches.

    Regards,

    Rich Heilman

    Add comment
    10|10000 characters needed characters exceeded

    • Former Member

      There is no problem with the code. The issue is related to table spaces. You need to consult your basis team and ask them to resolve this issue.

      Thanks and regards,

      Bharath.

  • author's profile photo Former Member
    Former Member
    Posted on Aug 04, 2006 at 05:59 AM

    Hi !

    It seams that your table is not correct / fully activated.

    To check it out you should try the following:

    - Go to the SE11

    - Give it your table name and go to "Display"

    - Check if the table is "active"

    - Choose "Utilities->Database Object->Check" and see

    if there are any errors

    - go back and choose "Utilities->Runtime Object->Check"

    and see if there are any errors

    If there are any errors - try to activate the table again. You may need the "Utilities->Database Utiliy" for that.

    After there are no more errors by checking all these your program should work.

    Regards

    Rainer

    Some points would be nice if thate helped a bit.

    Add comment
    10|10000 characters needed characters exceeded