Quantcast
Channel: SCN: Message List
Viewing all articles
Browse latest Browse all 10449

Re: Is this ABAP statement correct ?

$
0
0

Hi,

 

Problem is with corresponding fields of table.Please create appropriate structure and try it.

 

I tried the below code and it was working.

 

 

 

TYPES : BEGIN OF ty_sflight ,

        carrid  TYPE sflight-carrid,

        seatsmax TYPE sflight-seatsmax,

        END OF ty_sflight.

DATA: t_sflight TYPE TABLE OF ty_sflight,

      l_sflight TYPE ty_sflight.



SELECT carrid SUM( seatsmax ) FROM sflight INTO TABLE t_sflight GROUP BY carrid.



  LOOP AT t_sflight INTO l_sflight.

    WRITE :/ l_sflight-carrid, l_sflight-seatsmax.

  ENDLOOP.

 

Regards,

Peri


Viewing all articles
Browse latest Browse all 10449

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>