WE'VE FOUND SAPhelpdesk!!!

***** Read the Reviews / Rate the Solution
We're not quite there yet.But we're getting there!-and we really want you to know when we're ready.
We can send the latest updates to ur email.Just subscribe to the email updates below and confirm the confirmation link in your email

Here's how to stay updated:

Enter ur email:

KEY WORDS ADDING IN INTERNAL TABLE

1. Which keyword adds a line anywhere within an internal table?
A: APPEND
B: MODIFY
C: ADD
D: INSERT

Internal tables are usually processed in loops. In this loop, all elements of the internal table are read, starting from the first line. The keyword that starts the loop is LOOP AT, followed by the name of the internal table.

If is an internal table without header line, such as the one you created in Declaring an internal table, you need a work area to fill the contents of the current line into. To define this work area, use the option INTO .

You can now write a statement block to process the individual lines of the internal table.

At the end of the block, close the loop using the keyword ENDLOOP.

Processing an internal table looks like this in the program:

LOOP AT itab INTO wa.

ENDLOOP.

The program based on the examples below is listed in Sample program: internal tables. If you encounter any problems coding your program, you can look for tips in the sample program.

Output of the table contents

To output table contents, you use a WRITE statement within a LOOP. Make sure that the contents of the current table line is in the work area of the table by specifying in the WRITE statement the relevant fields of the work area .

You can use the statement pattern to create the WRITE statement. However, note that you cannot mark Output to Struct. in the window Assemble a WRITE Statement. Instead, use Output from fld for each field you want to output. Enter the entire field name into the adjacent input field and choose Copy.

In the last exercise, you wrote a program that filled the internal table without header line with values from the database table SPFLI, using a logical database. Now output the internal table.

  1. Fetch the program into the editor.
  2. Find the correct event keyword at which to output the internal table. Since you must output the table after the event GET SPFLI, the only event possible is END-OF-SELECTION.
  3. Include a LOOP on the internal table into the program. Make sure to fill the work area with the current values of the internal table.
  4. Output the fields of the work area in the statement block of the loop.
  5. Check the syntax and save your program.
  6. Execute the program. On the selection screen, choose Airline = ‘ LH’ and Flight connection = ‘0400’ to ‘2000’. Use the Dynamic selections. Save the selection asVariant.

The system displays a list of all flights that correspond to the selections entered on the selection screen.




Confused? Feel free to ask

saphelpdesk.co.inYour feedback is always appreciated.I will try to reply Ur queries as soon as time allows.
Regards,
SAPhelpdesk

0 comments:

Post a Comment

Your Ad Here
Write 4 Us ( Support me ) !!!