Skip to Content
0
Jun 18, 2009 at 05:24 AM

problem in displaying plant names

22 Views

hi

below is my code...

my requirement is if i enter 3 plants in select option like 1120 1130 1410

then i have to get the out put as Unit 2 , Unit 3 , Unit 1

how to do this?

SELECT a~name1
       b~werks
  INTO TABLE it_final1
  from T001w as a INNER JOIN
  eine as b on a~werks = b~werks
  WHERE b~werks in i_werks.
  CLEAR: wa_final1.
  LOOP AT it_final1 INTO wa_final1.
     IF sy-tabix = 1.
       CONCATENATE text-to1 ':' wa_final1-name1 INTO t_text SEPARATED BY space.
       ELSE.
         CONCATENATE t_text wa_final1-name1 INTO t_text SEPARATED BY ','.
     ENDIF.
  ENDLOOP.
    wa_header-typ = 'H'.
    wa_header-info = t_text.
    APPEND wa_header to it_header.
    CLEAR: wa_header.