How to display output without fieldnames in write statements

hi,
can any one tell how to get output with all fields values of a table without writing fieldnames in write statement.
giv proper code for this task.Thaks in advance.

hiii
if you want to write just values then you can use write statement only ..no need to do anything else.simply write as follows
LOOP AT t_customer INTO fs_customer.
  WRITE:/ fs_customer-customer_no,
          fs_customer-customer_name,
          fs_customer-customer_amount.
ENDLOOP
reward if useful
thx
twinkal

Similar Messages

  • How to display output parameters in storedprocedures in front end?

    hi all ,thank you for all the support.
    Now i want your help .Here below i have given the general format of stored procedure we are using in our application . In procedure we are catching the exception and assigning to an output variable P_STATUS .
    If any exception occurs ,How we display this caught exception from front end that means how we display the exception in front end .We are using VB.NET and VS 2005 and Oracle 9i for development.
    CREATE OR REPLACE PROCEDURE SELECTINTERVALS
    P_MINVAL INTEGER,
    P_MAXVAL INTEGER,
    P_INTERVAL     INTEGER,
    P_USERID VARCHAR2,
    P_STATUS OUT VARCHAR2
    AS
    BEGIN
              SELECT STATEMENT or INSERT STATEMENT     
    EXCEPTION
              WHEN OTHERS THEN
              ROLLBACK;
              P_STATUS:=SQLERRM;
    END;
    If anybody knows, please help me
    thanks & regards

    Both methods are wrong. Returning error/exit codes for the reasons I've stated above.
    As for handling the exception... If you want to propagate the exception, then DO NOT CHANGE IT INTO A MEANINGLESS USER EXCEPTION!
    This is useless:
    WHEN OTHERS THEN
    ROLLBACK;
    P_STATUS:=SQLERRM;
    RAISE_APPLICATION_ERROR(-20011, SQLERRM);
    Why it is meaningless? Because the caller now has to parse the error message to determine just what the actual root exception was... as the root exception number has been replaced with a meaningless number.
    This is meaningful and (almost) correct:
    [pre]
    when OTHERS then
    rollback;
    raise; -- re-raise the exception
    PS. It makes better sense to trap the actual exception like no data found, duplicate PK violations, etc... it seldom makes sense to trap all other exceptions and then do something like a rollback.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       

  • How to display output only sort format in alv

    Hi Experts,
    I have one problem in alv output display. I'm developing alv report for orders raised during the period.I want to display each order wise value(netwr) and order quatity (kwmeng) . i set 8 radio buttons one radio btn click then i want output ex.in grid display click on sort then each order wise calculate the value and quantity . that particular data to display when click on radio button.
    ex:click on sort in grid display.
    (branch) (order no)     (quantity)   (value)                        (BSTNK)
    AMUM     0000003354     2             10                                    3,271
    AMUM     0000003354     1              10                                    6,542
                                                       (above qty sum 2+1=3)  
    (SUM) =   AMUM       0000003354            3                       20            9,813
    HIP2         0000003362     2           5     17,810
    HIP2             0000003362     1          5     23,075
    (sum) = HIP2          0000003362                 10           40,885
    i display output in alv griddisplay.client asking one rb put in selection screen i want output like above only sum col.
    when i click one radio button output is come like (sum) above.
    Please help me.
    Thanks & Regards,
    Balakrishna Gajula

    hi you need to use sortinfo for your requirement.
    ie see the below code.
    "declare sortinfo at data declaration
    data:   wa_sort     type slis_sortinfo_alv,      "''' add this
                layout      type slis_layout_alv.          "add this
    ""make the below changes in your fieldcat
      wa_fieldcat-tabname   = 'FINAL'.
      wa_fieldcat-seltext_m = 'Td - Rvdt'.
      wa_fieldcat-fieldname = 'QUANTITY'.
      wa_fieldcat-do_sum    = 'X'.          """"""add this to your  *QUANTITY field*
      append wa_fieldcat to it_fieldcat.
      clear wa_fieldcat.
      wa_fieldcat-tabname   = 'FINAL'.
      wa_fieldcat-seltext_m = 'temp''.
      wa_fieldcat-fieldname = 'VALUE'.
      wa_fieldcat-do_sum    = 'X'.             """"""add this to your  *VALUE field*
      append wa_fieldcat to it_fieldcat.
      clear wa_fieldcat.
    """"" you need to add this after workarea of fieldcat
      wa_sort-fieldname =  'BRANCH'.  " Here Branch indicates the fieldname
      wa_sort-subtot    = 'X'.
      append wa_sort to it_sort.
      clear wa_sort.
      wa_sort-fieldname = 'ORDERNO'.
      append wa_sort to it_sort.
      clear wa_sort.
    " in your alv fm add sortinfo
      call function 'REUSE_ALV_GRID_DISPLAY'
        exporting
          i_callback_program = sy-cprog
          is_layout          = layout
          it_fieldcat        = it_fieldcat
          it_sort            = it_sort                   """""""""add this
        tables
          t_outtab           = final                   " your internal table name
        exceptions
          program_error      = 1
          others             = 2.
      if sy-subrc <> 0.
    * MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
    *         WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
      endif.
    This solves your purpose.
    Regards,
    koolspy.

  • How to display output with 5min & 10min averages?

    Hi I’ve Data Like below in SqlServer Table
    DateTimeMin
    Field
    Value
    2014-10-09 11:01:00
    some
    1
    2014-10-09 11:02:00
    some
    2
    2014-10-09 11:03:00
    some
    3
    2014-10-09 11:04:00
    some
    4
    2014-10-09 11:05:00
    some
    5
    2014-10-09 11:06:00
    some
    6
    2014-10-09 11:07:00
    some
    7
    2014-10-09 11:08:00
    some
    8
    2014-10-09 11:09:00
    some
    9
    2014-10-09 11:10:00
    some
    10
    If I Run a query, I need Output like below (5 minute average)
    DateTimeMin
    Field
    Value
    2014-10-09 11:05:00
    some
    3
    2014-10-09 11:10:00
    some
    8
    If it’s 10 minute average, I need output like below
    DateTimeMin
    Field
    Value
    2014-10-09 11:10:00
    some
    5.5
    at where clause, I've to use  DateTimeMin between
    2014-10-09 11:01:00 and 2014-10-09 11:10:00
    Please advise, how?

    Hi Visakh
    at present I'm getting output like below
    ID
    DateTimeMin
    Value
    1
    2014-10-09 11:05:00
    3
    2
    2014-10-09 11:10:00
    8
    How to get output like below(I need to add the Field Column)
    ID
    DateTimeMin
    Field
    Value
    1
    2014-10-09 11:05:00
    some
    3
    2
    2014-10-09 11:10:00
    some
    8
    I tried several ways, but unable to get it(The Field Data is same from min 1 to 10)

  • How to display content without using webcenter services - task flows?

    Good day!
    I wanted to create a portlet where I can display and update an xml content retrieved from UCM Content Server. How can I do this without using taskflows (webcenter services)?
    Thanks in advance!
    Keith

    Hey Keith,
    Since you are already using the getResponseAsString() method you have your GET_FILE call working. To get the xml file as the file itself you need to instead call the getResponseStream() method. This will get you an InputStream representing the response.
    Once you have the stream you can do the following (I assume you are on a jsp page or somewhere you have access to the HttpServletResponse):
    String contentType = serviceResponse.getHeader("Content-Type");
    InputStream xmlInputStream = serviceResponse.getResponseStream();
    OutputStream outStream = response.getOutputStream();
    response.addHeader("Content-Disposition", "attachment;filename=myXmlFile.xml");
    response.setContentType(contentType);
    StreamUtil.copyStream(xmlInputStream,outStream,true,true);
    The runthrough:
    1. get the content type of the file coming back form the GET_FILE call
    2. grab the file as an InputStream
    3. get the output stream representing the response
    4. add a header to the response to trigger the "download file" dialog
    5. set the content type of the response
    6. copy the input stream to the output stream to send the xml file to the browser
    Notes:
    -StreamUtil is part of the RIDC jar
    -use Content-Disposition = inline to tell the browser to try and render the file in it's window if it can.
    Hope that helps,
    Andy Weaver - Senior Software Consultant
    Fishbowl Solutions < http://www.fishbowlsolutions.com?WT.mc_id=L_Oracle_Consulting_amw >

  • SPOOL - how to display output list of more then 255 characters?

    Hi,
    First of all, I would like to say hi to all of you here, as a new member :)!
    I've just discovered this forum - I'm very new and let's say unexperienced in SAP, unlike you :)!
    Didn't know where to put my subject (in what folder) so I apologize in advance if I'm mistaken... I work as an ABAP programmer in SAP Core and SAP IS-T and currently I'm worried about this problem:(!
    We have these huge reports in IS-T that have to be run in background, because of lot of data. Most of reports are very wide and don't fit in those 255 characters that is SAP standard for spool display. Now I'm dealing with this RFC that has to provide spool display with 800 characters, and this has to be on production by tomorrow:)!!!!!
    First I created new format type (ZX_65_800) in transaction SPAD and assigned it to my local printer. I thought this would be enough, but I was wrong. Because when I try to run my programe in background, the system doesn't offer me my format at all :(!
    Is there anything else I must do in order to get it.... (I work in Release 620)
    If anyone had the same problem, please contact me!
    Thanks,
    BR,
    Sanja

    Hi All,
    We have been looking for a solution for what I believe is the same problem, for more than 2 years now. I would just like to verify with you, if your requirement are similar to ours.
    Problem:
    1.     Requirement is to run large HR reports – either standard or with Ad Hoc Query in background mode in a company with more than 50,000 employees.
    2.     Nobody wants printed reports these days.  We want to save the forests. Customers prefer to be emailed an Excel file so they can do further data analysis, filtering, pivot tables etc.
    3.     Reports are running OK in foreground for smaller sections of the organisation, where you send the output to Excel from ALV, or save as a local file in spreadsheet format.
    4.     But large reports for entire company are awkward, tie up your PCs resources, and complex reports accessing many tables can timeout before completion.
    5.     So scheduling these reports to run in background would be the ideal solution.
    6.     However when we access the report output from SP02, we find that most reports (say with more than 13 or so fields) have an output wider than 255 characters and the output of the spool file wraps to the next line in Excel.  It is very tricky to then parse the data back into one row for each employee.  And you have a problem if you output is for 50,000 or so employees, because then you file is 100,000 rows and will not load completely into Excel – limit problem of 65,536 characters.
    7.     We simply want a spool file that does not wrap the data to the next line after 255 characters.
    8.     But how to explain this simple requirement to some technical people. It seems a lot of posts on SDN think we always want to print a spool file.  NO – remember the forests!
    Possible Solutions:
    I see a lot of posts here that refer to OSS note 186603, but they don’t mention the target for the output of the spool is to import into an Excel File (i.e. spreadsheet format).  Just search for 186603 or ” Spool request with more than 255 columns”.  There is also a reference to OSS note 313566.  I am not sure if these will work?
    I have also seen the suggestions that you need to define a customer printer format that does not wrap the output after 255 characters (create a new format type in transaction SPAD).
    Did you find a solution yet to this problem, do the solutions above work, or can anyone else help us!
    John McKee

  • How to display output serially ?

    hi,
    i have a table and there is a coloum abc, in that data are like that
    PEN
    PENCIL
    BAG
    so now i want a sql query which will display as per my choice serially , like i want pencil should b first then BAG should be second and so on..
    thanks
    Edited by: Hi FRNzzz!! on Apr 22, 2010 10:50 PM

    Hi,
    What are the rules which determine that 'LG08' comes before 'LH07', and 'LH07' comes before 'LH09'?
    It looks like there are no rules, other than "'LG08' comes before 'LH07', and 'LH07' comes before 'LH09'"; that is, the order of those strings has nothing to do with the strings themselves.
    If that's the case, then you should have a table to store information that is related to the different possible m_vr values.
    You may already have such a table, for other uses. If so, add a column for the sort order.
    If you do not already have such a table, create one:
    CREATE TABLE     m_vr_lookup
    (       m_vr          VARCHAR2 (4)     PRIMARY KEY
    ,     sort_order     NUMBER
    );The populate the table with each possible value of m_vr and its relative sort order:
    INSERT INTO m_vr_lookup (m_vr, sort_order) VALUES ('LG08',  100);
    INSERT INTO m_vr_lookup (m_vr, sort_order) VALUES ('LH07',  200);
    INSERT INTO m_vr_lookup (m_vr, sort_order) VALUES ('LH09',  300);
    INSERT INTO m_vr_lookup (m_vr, sort_order) VALUES ('LG01',  400);
    COMMIT;For sort_order, you don't have to use numbers that are multiples of 100. You don't even have to use numbers. I did, because they're convenient. If you add new m_vrf bvalues later, you can give them sort_orders like 150, 125 or 100.003.
    Wheneve you need to use this sort order, join to the m_vr_lookup table, like this:
    SELECT       mvr.*
    FROM            mvr
    LEFT OUTER JOIN       m_vr_lookup     ON     mvr.m_vr     = m_vr_lookup.m_vr
    ORDER BY  mvr.m_sno
    ,            m_vr_lookup.sort_order
    ;Use an outer join (like I did above) if you're not sure that all the m_vr values in mvr are also in m_vr_lookup.
    If you are sure (for example, if you made a foreign key constraint on mvr), and if mvr.m_vr is never NULL, then you can use a more efficient inner join; just change "LEFT OUTER JOIN" to "JOIN" in the query above.
    If you need help, post CREATE TABLE and INSERT statements for your sample data (including the lookup table). Also post the results you want from that data, and an explanation of how you get those results.
    Make sure the results you post correspond to the data you post.
    In your last message, you said the sample data for m_sno=12345 was the following 5 rows:
    12345 LG01 01-JAN-03
    12345 LG02 05-FEB-03
    12345 LG08 03-JUN-07
    12345 LH07 03-FEB-06
    12345 L202 01-FEB-03but the output for that m_sno was 6 rows, including:
    12345 LH09 05-FEB-08Was that a mistake, or is part of the problem generating new rows?

  • How to display output of from clause query?

    Hi. I am using Forms Developer 10g. I have a datablock which uses a from_clause_query. In my from_clause_query, i used a WITH AS SELECT.
    I am trying to display the output of this query in my forms but the first column, V_CUTOFF_TO is not displayed, probably because it is not a database item. It was a result of my initial WITH AS SELECT query months. How can i display this along with the output of my from_clause_query. Thanks in advance for the help. By the way, i am trying to post the contents of my from_clause_query here but it says Sorry, this content is not allowed. I dont know why?

    Here is how you should most your code for it to be legible.
    WITH months AS
      (SELECT ADD_MONTHS(:V_DATE_FROM,LEVEL-1) m_first ,
        (ADD_MONTHS(:V_DATE_FROM, LEVEL    -0 )-1) m_last
      FROM dual
        CONNECT BY LEVEL < MONTHS_BETWEEN(:V_DATE_TO,:V_DATE_FROM) + 1
      EQUIP_per_month AS
      (SELECT COUNT(TRANS_CODE) V_COUNT,
        m_last V_CUTOFF_TO,
        trans_code,
        transformer,
        DATE_COMMISSION,
        DATE_DECOMMISSION,
        CLASSIFICATION,
        SUBSTATION_CODE
      FROM
        (SELECT C.TRANS_CODE,
          C.TRANSFORMER,
          C.SUBSTATION_CODE,
          C.DATE_COMMISSION,
          C.DATE_DECOMMISSION,
          C.CLASSIFICATION,
          m_last
        FROM SPM_TRANS C
        CROSS JOIN months
        WHERE CLASSIFICATION              IS NOT NULL
        AND SUBSTR(C.SUBSTATION_CODE,6,4) <>'M001'
        AND C.DATE_COMMISSION             IS NOT NULL
        AND (C.DATE_PRIVATELY_OWNED       IS NULL
        OR C.DATE_PRIVATELY_OWNED          > m_first)
        AND (SUBSTR(C.TRANS_CODE,5,1) '5'
        AND SUBSTR(C.TRANS_CODE,5,1) '9')
        AND (:P_GRID             = SUBSTR(C.SUBSTATION_CODE, 1,1)
        OR :P_GRID              IS NULL)
        AND (:P_REGION           = SUBSTR(C.SUBSTATION_CODE, 2,4)
        OR :P_REGION            IS NULL)
        AND (C.DATE_DECOMMISSION > m_first
        OR C.DATE_DECOMMISSION  IS NULL)
        AND C.DATE_COMMISSION   <= m_last
        AND (:P_BRANCH           =
          (SELECT DISTINCT BRANCH_CODE
          FROM SPM_SUBSTATIONS
          WHERE C.SUBSTATION_CODE = SUBSTATION_CODE
        OR :P_BRANCH IS NULL)
        AND (:P_ACC   =
          (SELECT DISTINCT ACC_CODE
          FROM SPM_SUBSTATIONS
          WHERE C.SUBSTATION_CODE = SUBSTATION_CODE
        OR :P_ACC                    IS NULL)
        AND (:P_DISTRICT              = SUBSTR(C.SUBSTATION_CODE, 6,4)
        OR :P_DISTRICT               IS NULL)
        AND (RTRIM(:P_CLASSIFICATION) = RTRIM(CLASSIFICATION)
        OR :P_CLASSIFICATION         IS NULL)
        AND (:P_VOLTLEVEL             = SUBSTR(C.TRANS_CODE, 1,1)
        OR :P_VOLTLEVEL              IS NULL)
      GROUP BY m_lAst,
        trans_code,
        transformer,
        DATE_COMMISSION,
        DATE_DECOMMISSION,
        CLASSIFICATION,
        SUBSTATION_CODE
    SELECT V_CUTOFF_TO,
      A.trans_code,
      S.SUBSTATION_CODE,
      A.transformer,
      A.DATE_COMMISSION,
      A.DATE_DECOMMISSION,
      A.CLASSIFICATION
    FROM
      (SELECT *
      FROM
        (SELECT trans_code,
          transformer,
          DATE_COMMISSION,
          DATE_DECOMMISSION,
          CLASSIFICATION,
          SUBSTATION_CODE,
          V_CUTOFF_TO
        FROM EQUIP_per_month
        GROUP BY trans_code,
          transformer,
          DATE_COMMISSION,
          DATE_DECOMMISSION,
          CLASSIFICATION,
          SUBSTATION_CODE,
          V_CUTOFF_TO
      ) A,
      SPM_SUBSTATIONS S
    WHERE A.SUBSTATION_CODE = S.SUBSTATION_CODE
    ORDER BY V_CUTOFF_TO,
      S.SUBSTATION_CODE,
      TRANS_CODE);The V_CUTOFF_TO , your first column, may not to be getting a (not null ) value.
    Regards,
    Edited by: Prabodh on Jun 21, 2012 2:41 PM

  • SGD 4.31 : How to display applications without window decoration

    Hi,
    I'm trying to display an application in a independant window without window decoration.
    The kiosk mode doesn't fit because the window cannot be resize.
    Is it possible ?
    Thks for your help.

    May be you can clarify what "window decoration" mean.
    If you are seeing two sets of window control (minimize, maximize, close) in the top right hand, then verify that:
    - application is indeed configured for seamless windows
    - on the application server, there's a ttasw process running for that user
    If you are still unable to get seamless window to work, try rebooting your windows application server.

  • How to display output of SQL Loader in a readable format

    Hi All,
    We have an inbound interface wherein we are uploading data from a flat file to Oracle Applications.
    The entire process is happening in a request set -
    1. Loading from flat file to staging tables via SQL Loader
    2. Validating Data in staging tables
    3. Uploading in Oracle standard tables
    User says that the log file which shows the output of SQL Loader (step 1) is not readable and they want the data in some particular format which is understandable/readable for them.
    Firstly, help me understand is it possible.
    Also I have heard about BAD file, can anyone tell me where is it created and by what name and can we fetch that file created ?
    Any pointers would be really helpful.
    Regards,
    Shruti

    Hi
    DATA :
      w_i TYPE i VALUE 1,
      w_temp TYPE i VALUE 1..
    WHILE w_temp LE 10.
      w_i = 1.
      WHILE w_i LE w_temp.
        WRITE :
          w_i.
        ADD 1 TO w_i.
      ENDWHILE.
      SKIP.
      ADD 1 TO w_temp.
    ENDWHILE.
    Regards
    Pavan

  • How to display names without file extension in Content Query Web Part in SharePoint 2010

    I try to display names in Content Query Web Part  but it shows file extension. I cannot find a way in CQWP editor that can exclude file extension.  Is there a way to display names excluding file extensions thru settings in the CQWP editor?
    I have to edit the code in SharePoint Designer, right?
    Thanks in advance for any tips!

    In the file ContentQueryMain you have already a function to get the file without extension.
    So we just can use this:
    <xsl:call-template name="OuterTemplate.GetFileNameWithoutExtension">
    <xsl:with-param name="input" select="$DisplayTitle" />
    </xsl:call-template>

  • How to display output in a single line?

    Hi
    im getting the out put in the following way
    100006        1120             01
                                          02
                                          03
    100007        1410            01
                                         02
                                         03
    but i want the output as follows
    100006         1120           01,02,03
    100007          1410          01,02,03
    Can any body tell me the code for this?

    Hi Dilip
    this is my full code
    im not getting the proper out put..
    eg : i have material 1000002 for this 3 inspection types are there 01,02,03
                                1000003 for this 1 inspection types are there 05
    following program giving me the out put as
                                1000002      1410          03
                                1000003       2140         05
                                                                   01
                                                                   02
                                                                   03
                                                                   05
    but i want the output as follows
                              1000002          1410        01
                                                                   02
                                                                   03
                              1000003          2140       05
    can u help me on this also?
    TABLES:MARC.
    TYPE-POOLS: SLIS.
    SELECTION-SCREEN:BEGIN OF BLOCK B1 WITH FRAME TITLE TEXT-T01.
      SELECT-OPTIONS:S_MATNR FOR MARC-MATNR.
      PARAMETERS:P_WERKS TYPE MARC-WERKS.
      SELECTION-SCREEN:END OF BLOCK B1.
      TYPES:BEGIN OF TYPE_FINAL,
            ART TYPE QMAT-ART,
            MATNR TYPE MARC-MATNR,
            WERKS TYPE MARC-WERKS,
            END OF TYPE_FINAL,
            BEGIN OF TYPE_QMAT,
            ART TYPE QMAT-ART,
            MATNR TYPE QMAT-MATNR,
            END OF TYPE_QMAT.
    DATA:IT_FINAL TYPE TABLE OF TYPE_FINAL,
          WA_FINAL LIKE LINE OF IT_FINAL,
          I_FINAL TYPE TABLE OF TYPE_FINAL,
          IT_QMAT TYPE TABLE OF TYPE_QMAT,
          WA_QMAT LIKE LINE OF IT_QMAT.
          DATA: i_FCAT TYPE TABLE OF SLIS_FIELDCAT_ALV,
                W_FCAT TYPE SLIS_FIELDCAT_ALV.
    field-symbols: <fs_fin> TYPE TYPE_FINAL.
      START-OF-SELECTION.
      PERFORM GET_DATA.
      PERFORM PROCESS_DATA.
      PERFORM DISPLAY_DATA.
    form GET_DATA .
      SELECT MATNR
             WERKS
        FROM MARC
        INTO CORRESPONDING FIELDS OF TABLE IT_FINAL
        WHERE MATNR IN S_MATNR.
        IF IT_FINAL[] IS NOT INITIAL.
          SELECT ART
                 MATNR
                 WERKS
            FROM QMAT
            INTO CORRESPONDING FIELDS OF TABLE IT_QMAT
            FOR ALL ENTRIES IN IT_FINAL
            WHERE MATNR = IT_FINAL-MATNR
            AND WERKS = IT_FINAL-WERKS.
        ENDIF.
        SORT IT_FINAL BY
        MATNR
        WERKS
        ART.
        DELETE ADJACENT DUPLICATES FROM IT_FINAL COMPARING
        MATNR
        WERKS
        ART.
    endform.                    " GET_DATA
    form PROCESS_DATA .
    move it_final to i_final.
    REFRESH IT_FINAL.
    LOOP AT I_FINAL assigning <fs_fin>.
    LOOP AT IT_QMAT INTO WA_QMAT where MATNR = <fs_fin>-MATNR.
                                   P_werks = <fs_fin>-werks.
    *REFRESH i_final.
    IF sy-subrc eq 0.
    <fs_fin>-ART = WA_QMAT-ART.
    APPEND <fs_fin>-ART TO i_final.
    ENDIF.
      ENDLOOP.
    ENDLOOP.
    form DISPLAY_DATA .
    W_FCAT-FIELDNAME = 'MATNR '.
    W_FCAT-SELTEXT_M = 'MATERIAL NUMBER'.
    W_FCAT-OUTPUTLEN = '18'.
    APPEND W_FCAT TO I_FCAT.
    W_FCAT-FIELDNAME = 'WERKS'.
    W_FCAT-SELTEXT_M = 'PLANT'.
    W_FCAT-OUTPUTLEN = '04'.
    APPEND W_FCAT TO I_FCAT.
    W_FCAT-FIELDNAME = 'ART'.
    W_FCAT-SELTEXT_M = 'INSPECTION TYPE'.
    W_FCAT-OUTPUTLEN = '08'.
    APPEND W_FCAT TO I_FCAT.
                     " DISPLAY_DATA
    CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'
    EXPORTING
       I_CALLBACK_PROGRAM = SY-REPID
       IT_FIELDCAT = I_FCAT[]
       I_DEFAULT = 'X'
       I_SAVE = 'A'
      TABLES
        t_outtab = i_final[].
    CALL FUNCTION 'CONVERSION_EXIT_ALPHA_OUTPUT'
      EXPORTING
        input         = WA_FINAL-MATNR.
    endform.
    FORM BUILD_FCAT USING FIELD TYPE SLIS_FIELDNAME
                          TEXT TYPE  dd03p-scrtext_m
                          LENGTH TYPE dd03p-outputlen.
      W_FCAT-FIELDNAME = FIELD.
      W_FCAT-SELTEXT_M = TEXT.
      W_FCAT-OUTPUTLEN = LENGTH.
      APPEND W_FCAT TO i_FCAT.
      CLEAR W_FCAT.
      ENDFORM.
    thanks & Regards
    Smitha

  • How to display output with 3 levels in ALV

    He experts,
         I have on classical report & it output is with 3 levels, like
               Ex:  material no<Level-1>
                            customer no<Level-2>
                                                date<Level-3>.
             For this i used 2 select staments within select & endselect statmens.
    Now i want to display in ALV. I can't use Hierarchy FM for this bcoz more than 2 levels.
    Plz help on this
    Regards.

    Hi Kumar,
    Thanks for response
      Here i don't need drill down capability....
                   is it possible to diplay <level-1>  <level-2>   <level-3> by using ALV Grid FM. If not alternative solutions
    Regards.

  • How to increase the Font Size in Write Statement?

    I found the Code in the initial search  I found the syntax "PRINT-CONTROL SIZE 6 LPI 6."
    But the font size seems same in the Report output.
    How can I see the size if it is changed? Is the changes only reflected in the Print-out?
    Thanks

    Hi,
    not sure if I understand your requirement. Anyways, have a look at the sap help, maybe this helps you:
    You can manipulate the output of a list during the print process from within the executable program (report). The statements SET MARGIN and PRINT-CONTROL, described in the topics below, take effect only if the list is directly sent to the spool. The statements do not affect a list that is displayed on the screen and printed from there using List ® Print.
    http://help.sap.com/saphelp_nw04/helpdata/en/9f/dba60935c111d1829f0000e829fbfe/frameset.htm
    Br,
    Tim

  • Internal Table output in customer format ; write statement

    Hello All,
    I need help in printing the O/P.
    Currently the program is displaying ALV.
    However I need the O/P to be displayed like.
    FIELDANAME1;FIELDNAME2;FIELDNAME3;....FNZ.
    VALUE1;VALUE2;VALUE3....VZ.
    Code is below - Dynamically it will show the table contents
    according to the tabel name.
    *& Report YREN_FIELDSDISPLAY
    REPORT YREN_FIELDSDISPLAY.
    FIELD-SYMBOLS:
    <f_tab1> TYPE STANDARD TABLE.
    PARAMETERS:
    p_tname TYPE tabname16 OBLIGATORY, " DEFAULT 'MARA' ,
    p_rows(5) TYPE c DEFAULT '200'.
    CLASS lcl_dynamic DEFINITION
    CLASS lcl_dynamic DEFINITION CREATE PRIVATE.
    PUBLIC SECTION.
    CLASS-METHODS:
    check_selection
    EXCEPTIONS invalid_table,
    main
    EXCEPTIONS no_data_found,
    display.
    PRIVATE SECTION.
    TYPE-POOLS: abap.
    CLASS-DATA: tab TYPE REF TO cl_abap_structdescr,
    wa_tab TYPE REF TO cl_abap_structdescr,
    comp_tab TYPE cl_abap_structdescr=>component_table,
    i_tab TYPE REF TO cl_abap_tabledescr,
    i_table TYPE REF TO data.
    ENDCLASS. "lcl_dynamic DEFINITION
    CLASS lcl_dynamic IMPLEMENTATION
    CLASS lcl_dynamic IMPLEMENTATION.
    METHOD check_selection.
    SELECT COUNT( * )
    FROM dd02l
    WHERE tabname = p_tname
    AND as4local = 'A'
    AND tabclass = 'TRANSP'.
    IF sy-subrc = 0.
    RAISE invalid_table.
    ENDIF.
    ENDMETHOD. "check_selection
    METHOD main.
    tab ?= cl_abap_typedescr=>describe_by_name( p_tname ).
    comp_tab = tab->get_components( ).
    wa_tab = cl_abap_structdescr=>create( comp_tab ).
    i_tab = cl_abap_tabledescr=>create( wa_tab ).
    CREATE DATA i_table TYPE HANDLE i_tab.
    ASSIGN i_table->* TO <f_tab1>.
    IF p_rows IS INITIAL.
    p_rows = '50000'.
    ENDIF.
    *Get data
    SELECT * FROM (p_tname)
    INTO TABLE <f_tab1>
    UP TO p_rows ROWS.
    IF sy-subrc EQ 0.
    RAISE no_data_found.
    ENDIF.
    ENDMETHOD. "main
    METHOD display.
    SET TITLEBAR sy-title
    OF PROGRAM sy-cprog
    WITH 'Display table:' p_tname.
    DATA:
    l_gr_alv TYPE REF TO cl_salv_table,
    l_gr_functions TYPE REF TO cl_salv_functions.
    TRY.
    CALL METHOD cl_salv_table=>factory
    IMPORTING
    r_salv_table = l_gr_alv
    CHANGING
    t_table = <f_tab1>.
    CATCH cx_salv_msg . "#EC NO_HANDLER
    ENDTRY.
    l_gr_functions = l_gr_alv->get_functions( ).
    l_gr_functions->set_all( abap_true ).
    l_gr_alv->display( ).
    ENDMETHOD. "display
    ENDCLASS. "lcl_dynamic IMPLEMENTATION
    AT SELECTION-SCREEN.
    CALL METHOD lcl_dynamic=>check_selection
    EXCEPTIONS
    invalid_table = 1.
    IF sy-subrc EQ 0.
    MESSAGE e001(00) WITH
    p_tname ' is not a Transparant Table'.
    ENDIF.
    START-OF-SELECTION.
    CALL METHOD lcl_dynamic=>main
    EXCEPTIONS
    no_data_found = 1.
    IF sy-subrc EQ 0.
    MESSAGE i001(00) WITH 'No data found'.
    LEAVE LIST-PROCESSING.
    ENDIF.
    END-OF-SELECTION.
    CALL METHOD lcl_dynamic=>display.
    Thanks,
    Varun.

    hi varun,
    amandep is correct ...use REUSE_ALV_GRID_DISPLAY .If still you have problem in formatting then go through this code used for ALV display.
    *& Report  ZYOGALVEX1
    REPORT  ZYOGALVEX1.
    type-pools: slis.
    tables: zyogstudent,t001.
    data: itab like zyogstudent occurs 0 with header line.
    data: begin of jtab occurs 0,
          bukrs like t001-bukrs,
          butxt like t001-butxt,
          ort01 like t001-ort01,
          stceg like t001-stceg,
          end of jtab.
    data: field_cat type slis_t_fieldcat_alv,
          xlayout type slis_layout_alv,
          i_sort type slis_t_sortinfo_alv.
    start-of-selection.
      perform get_data.
      perform dis_lay.
      perform dis_sort.
      perform display.
    *&      Form  get_data
          text
    -->  p1        text
    <--  p2        text
    form get_data .
      select * from zyogstudent into table itab.
      select bukrs ort01 stceg butxt  from t001 into corresponding fields of table jtab.
           perform field_init using field_cat.
    endform.                    " get_data
    *&      Form  dis_lay
          text
    -->  p1        text
    <--  p2        text
    form dis_lay .
      xlayout-zebra = 'X'.
      xlayout-no_keyfix = 'X'.
      xlayout-flexible_key = 'X'.
      xlayout-colwidth_optimize = 'skip'.
      xlayout-header_text = 'this is using header text'.
    endform.                    " dis_lay
    *&      Form  dis_sort
          text
    -->  p1        text
    <--  p2        text
    form dis_sort .
      data l_sort type slis_sortinfo_alv.
        l_sort-fieldname = 'ZNAME'.
        l_sort-tabname = 'ZYOGSTUDENT'.
        l_sort-spos = 1.
        l_sort-up = 'X'.
        append l_sort to i_sort.
    endform.                    " dis_sort
    *&      Form  field_init
          text
         -->P_FIELD_CAT  text
    form field_init  using    p_field_cat.
      data wa_cat type slis_fieldcat_alv.
           wa_cat-fieldname = 'ZNAME'.
           wa_cat-tabname = 'zyogstudent'.
           wa_cat-outputlen = 25.
           wa_cat-seltext_m = 'ZNAME'.
           wa_cat-just = 'L'.
           append wa_cat to field_cat.
           wa_cat-fieldname = 'ZCLASS'.
           wa_cat-tabname = 'zyogstudent'.
           wa_cat-outputlen = 25.
           wa_cat-seltext_m = 'ZCLASS'.
           wa_cat-just = 'C'.
           append wa_cat to field_cat.
            wa_cat-fieldname = 'ZFEES'.
           wa_cat-tabname = 'zyogstudent'.
           wa_cat-outputlen = 25.
           wa_cat-seltext_m = 'ZFEES'.
           wa_cat-just = 'C'.
           append wa_cat to field_cat.
           wa_cat-fieldname = 'ZADD'.
           wa_cat-tabname = 'zyogstudent'.
           wa_cat-outputlen = 25.
           wa_cat-seltext_m = 'ZADD'.
           wa_cat-just = 'R'.
           append wa_cat to field_cat.
    endform.                    " field_init
    *&      Form  display
          text
    -->  p1        text
    <--  p2        text
    form display .
    CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'
    EXPORTING
       I_CALLBACK_PROGRAM                = 'sy-repid'
      I_CALLBACK_PF_STATUS_SET          = ' '
      I_CALLBACK_USER_COMMAND           = ' '
      I_CALLBACK_TOP_OF_PAGE            = ' '
      I_STRUCTURE_NAME                  = itab
       I_GRID_TITLE                      = 'This is grid title'
       IS_LAYOUT                         = xlayout
       IT_FIELDCAT                       = FIELD_CAT
       IT_SORT                           = i_sort
       I_DEFAULT                         = 'X'
      I_SAVE                            = ' '
      IT_EVENTS                         =
      TABLES
        t_outtab                          = itab.
    IF sy-subrc <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
            WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
    ENDIF.
    endform.                    " display

Maybe you are looking for

  • Discoverer 10g, it returns no data

    Hi all, I have a doubt can any one clarifies. Currently I work migration projects from 4i to 10g discoverer reports (Upgraded 11i to R12). Previously in 4i discoverer reports many views used and data also populated. Same query in discoverer 10g, it r

  • Read a file sent as an attachment from CPSC

                       I have a requirement where in CPO has to read a text file sent as an attachment from portal (cisco prime service catalog), Is there a way to query RCdatabase to fetch Document ID and retrive the file and read the file. If this appr

  • Sending a SOAP request with binary attachment

    hi all, I am sending a SOAP request from a SOAP client SOAP UI  with a binary attachment ( image file as an attachment )  and creating a file on the receiver side with attachment. But how do i see this attachment in XI and do i have to specify some a

  • SOL10-6-06 Jumpstart question

    Adding 10-6-06 to our existing Sol10 JS server, have mounted all .iso's lofi and run add_to_install_server for iso's 2-5 to the correct directory, but the jumpstart still stops and asks me: Starting Solaris Install Launcher in Command Line Mode. Plea

  • Message d'erreur recurant a chaque utilisation de Photoshop cs6

    bonjour Je suis débutant sur Photoshop, je suis une formation à l'initiation de Photoshop CS6, et je démarre a peine ma formation et a chaque fois que je clique sur un icône pour modifier une image ; où faire un nouveau calque, ce message d'erreur ap