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

query

Dear Experts,

I have a internal table I_plaf using this I am writing the below select query.

SELECT zaufnr zpdcldte zefpsdte

INTO TABLE i_tempdate

FROM zppo_pl

FOR ALL ENTRIES IN i_plaf

WHERE zaufnr = i_plaf-aufnr.

Here zaufnr field length is 12 ,i_plaf-aufnr field length is 10. So, I am getting error in the above query.

Can any one give me solution for this.

Thanks in advance

sai

Add a comment
10|10000 characters needed characters exceeded

Assigned Tags

Related questions

3 Answers

  • author's profile photo Former Member
    Former Member
    Posted on Oct 14, 2006 at 07:06 AM

    maiintain structure of the table <b>i_plaf</b> like table

    zppo_pl

    if source field lenth is less its not a probs, and if u are not getting the data then u have to make use of FM

    CONVERSION_EXIT_ALPHA_INPUT

    regards

    Prabhu

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Oct 14, 2006 at 07:14 AM

    Hi

    When you define the internal table i_plaf, here the field AUFNR has to be defined like ZPPO_PL-ZAUFNR.

    So while you get the data from PLAF and store them into I_PLAF you have to store in I_PLAF-AUFNR in according to the value stored in ZPPO_PL-ZAUFNR.

    The field PLAF-AUFNR is 10 char, so for example 10 is stored like 0000000010,

    The field ZPPO_PL-ZAUFNR is 12 char, so 10 can be stored like 000000000010,

    So after insert the data from PLAF to I_PLAF you have to inert two zero on the left.

    U can use fm CONVERSION_EXIT_ALPHA_INPUT.

    SELECT * FROM PLAF INTO TABLE I_PLAF WHERE ....

    LOOP AT I_PLAF.

    CALL FUNCTION 'CONVERSION_EXIT_ALPHA_INPUT'

    EXPORTING

    INPUT = I_PLAF-AUFNR

    IMPORTING

    OUTPUT = I_PLAF-AUFNR.

    MODIFY I_PLAF.

    ENDLOOP.

    Anyway how to convert the the format of AUFNR depends on how the data is stored in ZPPO_PL-ZAUFNR.

    Max

    Add a comment
    10|10000 characters needed characters exceeded

  • Posted on Oct 14, 2006 at 07:14 AM

    hi,

    use CONVERSION_EXIT_ALPHA_INPUT befor the query.

    it will help u.

    rgds

    anver

    pls mark useful answers

    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.