<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: doubt in using field catalog merge function in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/doubt-in-using-field-catalog-merge-function/m-p/3123769#M741872</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;hI&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Supports the creation of the field catalog for the ALV function modules&lt;/P&gt;&lt;P&gt;based either on a structure or table defined in the ABAP Data&lt;/P&gt;&lt;P&gt;Dictionary, or a program-internal table.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The program-internal table must either be in a TOP Include or its&lt;/P&gt;&lt;P&gt;Include must be specified explicitly in the interface.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The variant based on a program-internal table should only be used for&lt;/P&gt;&lt;P&gt;rapid prototyping since the following restrictions apply:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;o Performance is affected since the code of the table definition must&lt;/P&gt;&lt;P&gt;always be read and interpreted at runtime.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;o Dictionary references are only considered if the keywords LIKE or&lt;/P&gt;&lt;P&gt;INCLUDE STRUCTURE (not TYPE) are used.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If the field catalog contains more than 90 fields, the first 90 fields&lt;/P&gt;&lt;P&gt;are output in the list by default whereas the remaining fields are only&lt;/P&gt;&lt;P&gt;available in the field selection.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If the field catalog is passed with values, they are merged with the&lt;/P&gt;&lt;P&gt;'automatically' found information. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Below is an example ABAP program which will populate a simple internal table(it_ekpo) with data and&lt;/P&gt;&lt;P&gt;display it using the basic ALV grid functionality(including column total). The example details the main&lt;/P&gt;&lt;P&gt;sections of coding required to implement the ALV grid functionality:&lt;/P&gt;&lt;P&gt;Data declaration&lt;/P&gt;&lt;P&gt;Data retrieval&lt;/P&gt;&lt;P&gt;Build fieldcatalog&lt;/P&gt;&lt;P&gt;Build layout setup&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;*&amp;amp;---------------------------------------------------------------------*
*&amp;amp; Report ZDEMO_ALVGRID *
*&amp;amp; *
*&amp;amp;---------------------------------------------------------------------*
*&amp;amp; *
*&amp;amp; Example of a simple ALV Grid Report *
*&amp;amp; ................................... *
*&amp;amp; *
*&amp;amp; The basic requirement for this demo is to display a number of *
*&amp;amp; fields from the EKKO table. *
*&amp;amp;---------------------------------------------------------------------*
REPORT zdemo_alvgrid .

TABLES: ekko.

type-pools: slis. "ALV Declarations
*Data Declaration
*----------------
TYPES: BEGIN OF t_ekko,
ebeln TYPE ekpo-ebeln,
ebelp TYPE ekpo-ebelp,
statu TYPE ekpo-statu,
aedat TYPE ekpo-aedat,
matnr TYPE ekpo-matnr,
menge TYPE ekpo-menge,
meins TYPE ekpo-meins,
netpr TYPE ekpo-netpr,
peinh TYPE ekpo-peinh,
END OF t_ekko.

DATA: it_ekko TYPE STANDARD TABLE OF t_ekko INITIAL SIZE 0,
wa_ekko TYPE t_ekko.

*ALV data declarations
data: fieldcatalog type slis_t_fieldcat_alv with header line,
gd_tab_group type slis_t_sp_group_alv,
gd_layout type slis_layout_alv,
gd_repid like sy-repid.


************************************************************************
*Start-of-selection.
START-OF-SELECTION.

perform data_retrieval.
perform build_fieldcatalog.
perform build_layout.
perform display_alv_report.


*&amp;amp;---------------------------------------------------------------------*
*&amp;amp; Form BUILD_FIELDCATALOG
*&amp;amp;---------------------------------------------------------------------*
* Build Fieldcatalog for ALV Report
*----------------------------------------------------------------------*
form build_fieldcatalog.

* There are a number of ways to create a fieldcat.
* For the purpose of this example i will build the fieldcatalog manualy
* by populating the internal table fields individually and then
* appending the rows. This method can be the most time consuming but can
* also allow you more control of the final product.

* Beware though, you need to ensure that all fields required are
* populated. When using some of functionality available via ALV, such as
* total. You may need to provide more information than if you were
* simply displaying the result
* I.e. Field type may be required in-order for
* the 'TOTAL' function to work.

fieldcatalog-fieldname = 'EBELN'.
fieldcatalog-seltext_m = 'Purchase Order'.
fieldcatalog-col_pos = 0.
fieldcatalog-outputlen = 10.
fieldcatalog-emphasize = 'X'.
fieldcatalog-key = 'X'.
* fieldcatalog-do_sum = 'X'.
* fieldcatalog-no_zero = 'X'.
append fieldcatalog to fieldcatalog.
clear fieldcatalog.

fieldcatalog-fieldname = 'EBELP'.
fieldcatalog-seltext_m = 'PO Item'.
fieldcatalog-col_pos = 1.
append fieldcatalog to fieldcatalog.
clear fieldcatalog.

fieldcatalog-fieldname = 'STATU'.
fieldcatalog-seltext_m = 'Status'.
fieldcatalog-col_pos = 2.
append fieldcatalog to fieldcatalog.
clear fieldcatalog.

fieldcatalog-fieldname = 'AEDAT'.
fieldcatalog-seltext_m = 'Item change date'.
fieldcatalog-col_pos = 3.
append fieldcatalog to fieldcatalog.
clear fieldcatalog.

fieldcatalog-fieldname = 'MATNR'.
fieldcatalog-seltext_m = 'Material Number'.
fieldcatalog-col_pos = 4.
append fieldcatalog to fieldcatalog.
clear fieldcatalog.

fieldcatalog-fieldname = 'MENGE'.
fieldcatalog-seltext_m = 'PO quantity'.
fieldcatalog-col_pos = 5.
append fieldcatalog to fieldcatalog.
clear fieldcatalog.

fieldcatalog-fieldname = 'MEINS'.
fieldcatalog-seltext_m = 'Order Unit'.
fieldcatalog-col_pos = 6.
append fieldcatalog to fieldcatalog.
clear fieldcatalog.

fieldcatalog-fieldname = 'NETPR'.
fieldcatalog-seltext_m = 'Net Price'.
fieldcatalog-col_pos = 7.
fieldcatalog-outputlen = 15.
fieldcatalog-do_sum = 'X'. "Display column total
fieldcatalog-datatype = 'CURR'.
append fieldcatalog to fieldcatalog.
clear fieldcatalog.

fieldcatalog-fieldname = 'PEINH'.
fieldcatalog-seltext_m = 'Price Unit'.
fieldcatalog-col_pos = 8.
append fieldcatalog to fieldcatalog.
clear fieldcatalog.
endform. " BUILD_FIELDCATALOG


*&amp;amp;---------------------------------------------------------------------*
*&amp;amp; Form BUILD_LAYOUT
*&amp;amp;---------------------------------------------------------------------*
* Build layout for ALV grid report
*----------------------------------------------------------------------*
form build_layout.
gd_layout-no_input = 'X'.
gd_layout-colwidth_optimize = 'X'.
gd_layout-totals_text = 'Totals'(201).
* gd_layout-totals_only = 'X'.
* gd_layout-f2code = 'DISP'. "Sets fcode for when double
* "click(press f2)
* gd_layout-zebra = 'X'.
* gd_layout-group_change_edit = 'X'.
* gd_layout-header_text = 'helllllo'.
endform. " BUILD_LAYOUT


*&amp;amp;---------------------------------------------------------------------*
*&amp;amp; Form DISPLAY_ALV_REPORT
*&amp;amp;---------------------------------------------------------------------*
* Display report using ALV grid
*----------------------------------------------------------------------*
form display_alv_report.
gd_repid = sy-repid.
call function 'REUSE_ALV_GRID_DISPLAY'
exporting
i_callback_program = gd_repid
* i_callback_top_of_page = 'TOP-OF-PAGE' "see FORM
* i_callback_user_command = 'USER_COMMAND'
* i_grid_title = outtext
is_layout = gd_layout
it_fieldcat = fieldcatalog[]
* it_special_groups = gd_tabgroup
* IT_EVENTS = GT_XEVENTS
i_save = 'X'
* is_variant = z_template

tables
t_outtab = it_ekko
exceptions
program_error = 1
others = 2.
if sy-subrc &amp;lt;&amp;gt; 0.
* MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
* WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
endif.
endform. " DISPLAY_ALV_REPORT


*&amp;amp;---------------------------------------------------------------------*
*&amp;amp; Form DATA_RETRIEVAL
*&amp;amp;---------------------------------------------------------------------*
* Retrieve data form EKPO table and populate itab it_ekko
*----------------------------------------------------------------------*
form data_retrieval.

select ebeln ebelp statu aedat matnr menge meins netpr peinh
up to 10 rows
from ekpo
into table it_ekko.
endform. " DATA_RETRIEVAL&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 03 Dec 2007 05:50:30 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2007-12-03T05:50:30Z</dc:date>
    <item>
      <title>doubt in using field catalog merge function</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/doubt-in-using-field-catalog-merge-function/m-p/3123767#M741870</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;hi all,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;    When I am using the function maodule reuse_alv_fieldcatalog_merge for building the field catalog in alv list,it was giving abend message as&lt;/P&gt;&lt;P&gt;'Field catalog is empty'.&lt;/P&gt;&lt;P&gt;     what might be the reason for such message?can some one help me out with the solution to get rid of that.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;    I cant populate the catalog manually because I need to display nearly 40 fields in the output.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;         Thanks in advance.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 03 Dec 2007 05:47:28 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/doubt-in-using-field-catalog-merge-function/m-p/3123767#M741870</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-12-03T05:47:28Z</dc:date>
    </item>
    <item>
      <title>Re: doubt in using field catalog merge function</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/doubt-in-using-field-catalog-merge-function/m-p/3123768#M741871</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;   May be u are not passing the internal table structure, better tp paste ur code here&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Prashant&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 03 Dec 2007 05:49:12 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/doubt-in-using-field-catalog-merge-function/m-p/3123768#M741871</guid>
      <dc:creator>former_member386202</dc:creator>
      <dc:date>2007-12-03T05:49:12Z</dc:date>
    </item>
    <item>
      <title>Re: doubt in using field catalog merge function</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/doubt-in-using-field-catalog-merge-function/m-p/3123769#M741872</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;hI&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Supports the creation of the field catalog for the ALV function modules&lt;/P&gt;&lt;P&gt;based either on a structure or table defined in the ABAP Data&lt;/P&gt;&lt;P&gt;Dictionary, or a program-internal table.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The program-internal table must either be in a TOP Include or its&lt;/P&gt;&lt;P&gt;Include must be specified explicitly in the interface.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The variant based on a program-internal table should only be used for&lt;/P&gt;&lt;P&gt;rapid prototyping since the following restrictions apply:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;o Performance is affected since the code of the table definition must&lt;/P&gt;&lt;P&gt;always be read and interpreted at runtime.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;o Dictionary references are only considered if the keywords LIKE or&lt;/P&gt;&lt;P&gt;INCLUDE STRUCTURE (not TYPE) are used.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If the field catalog contains more than 90 fields, the first 90 fields&lt;/P&gt;&lt;P&gt;are output in the list by default whereas the remaining fields are only&lt;/P&gt;&lt;P&gt;available in the field selection.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If the field catalog is passed with values, they are merged with the&lt;/P&gt;&lt;P&gt;'automatically' found information. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Below is an example ABAP program which will populate a simple internal table(it_ekpo) with data and&lt;/P&gt;&lt;P&gt;display it using the basic ALV grid functionality(including column total). The example details the main&lt;/P&gt;&lt;P&gt;sections of coding required to implement the ALV grid functionality:&lt;/P&gt;&lt;P&gt;Data declaration&lt;/P&gt;&lt;P&gt;Data retrieval&lt;/P&gt;&lt;P&gt;Build fieldcatalog&lt;/P&gt;&lt;P&gt;Build layout setup&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;*&amp;amp;---------------------------------------------------------------------*
*&amp;amp; Report ZDEMO_ALVGRID *
*&amp;amp; *
*&amp;amp;---------------------------------------------------------------------*
*&amp;amp; *
*&amp;amp; Example of a simple ALV Grid Report *
*&amp;amp; ................................... *
*&amp;amp; *
*&amp;amp; The basic requirement for this demo is to display a number of *
*&amp;amp; fields from the EKKO table. *
*&amp;amp;---------------------------------------------------------------------*
REPORT zdemo_alvgrid .

TABLES: ekko.

type-pools: slis. "ALV Declarations
*Data Declaration
*----------------
TYPES: BEGIN OF t_ekko,
ebeln TYPE ekpo-ebeln,
ebelp TYPE ekpo-ebelp,
statu TYPE ekpo-statu,
aedat TYPE ekpo-aedat,
matnr TYPE ekpo-matnr,
menge TYPE ekpo-menge,
meins TYPE ekpo-meins,
netpr TYPE ekpo-netpr,
peinh TYPE ekpo-peinh,
END OF t_ekko.

DATA: it_ekko TYPE STANDARD TABLE OF t_ekko INITIAL SIZE 0,
wa_ekko TYPE t_ekko.

*ALV data declarations
data: fieldcatalog type slis_t_fieldcat_alv with header line,
gd_tab_group type slis_t_sp_group_alv,
gd_layout type slis_layout_alv,
gd_repid like sy-repid.


************************************************************************
*Start-of-selection.
START-OF-SELECTION.

perform data_retrieval.
perform build_fieldcatalog.
perform build_layout.
perform display_alv_report.


*&amp;amp;---------------------------------------------------------------------*
*&amp;amp; Form BUILD_FIELDCATALOG
*&amp;amp;---------------------------------------------------------------------*
* Build Fieldcatalog for ALV Report
*----------------------------------------------------------------------*
form build_fieldcatalog.

* There are a number of ways to create a fieldcat.
* For the purpose of this example i will build the fieldcatalog manualy
* by populating the internal table fields individually and then
* appending the rows. This method can be the most time consuming but can
* also allow you more control of the final product.

* Beware though, you need to ensure that all fields required are
* populated. When using some of functionality available via ALV, such as
* total. You may need to provide more information than if you were
* simply displaying the result
* I.e. Field type may be required in-order for
* the 'TOTAL' function to work.

fieldcatalog-fieldname = 'EBELN'.
fieldcatalog-seltext_m = 'Purchase Order'.
fieldcatalog-col_pos = 0.
fieldcatalog-outputlen = 10.
fieldcatalog-emphasize = 'X'.
fieldcatalog-key = 'X'.
* fieldcatalog-do_sum = 'X'.
* fieldcatalog-no_zero = 'X'.
append fieldcatalog to fieldcatalog.
clear fieldcatalog.

fieldcatalog-fieldname = 'EBELP'.
fieldcatalog-seltext_m = 'PO Item'.
fieldcatalog-col_pos = 1.
append fieldcatalog to fieldcatalog.
clear fieldcatalog.

fieldcatalog-fieldname = 'STATU'.
fieldcatalog-seltext_m = 'Status'.
fieldcatalog-col_pos = 2.
append fieldcatalog to fieldcatalog.
clear fieldcatalog.

fieldcatalog-fieldname = 'AEDAT'.
fieldcatalog-seltext_m = 'Item change date'.
fieldcatalog-col_pos = 3.
append fieldcatalog to fieldcatalog.
clear fieldcatalog.

fieldcatalog-fieldname = 'MATNR'.
fieldcatalog-seltext_m = 'Material Number'.
fieldcatalog-col_pos = 4.
append fieldcatalog to fieldcatalog.
clear fieldcatalog.

fieldcatalog-fieldname = 'MENGE'.
fieldcatalog-seltext_m = 'PO quantity'.
fieldcatalog-col_pos = 5.
append fieldcatalog to fieldcatalog.
clear fieldcatalog.

fieldcatalog-fieldname = 'MEINS'.
fieldcatalog-seltext_m = 'Order Unit'.
fieldcatalog-col_pos = 6.
append fieldcatalog to fieldcatalog.
clear fieldcatalog.

fieldcatalog-fieldname = 'NETPR'.
fieldcatalog-seltext_m = 'Net Price'.
fieldcatalog-col_pos = 7.
fieldcatalog-outputlen = 15.
fieldcatalog-do_sum = 'X'. "Display column total
fieldcatalog-datatype = 'CURR'.
append fieldcatalog to fieldcatalog.
clear fieldcatalog.

fieldcatalog-fieldname = 'PEINH'.
fieldcatalog-seltext_m = 'Price Unit'.
fieldcatalog-col_pos = 8.
append fieldcatalog to fieldcatalog.
clear fieldcatalog.
endform. " BUILD_FIELDCATALOG


*&amp;amp;---------------------------------------------------------------------*
*&amp;amp; Form BUILD_LAYOUT
*&amp;amp;---------------------------------------------------------------------*
* Build layout for ALV grid report
*----------------------------------------------------------------------*
form build_layout.
gd_layout-no_input = 'X'.
gd_layout-colwidth_optimize = 'X'.
gd_layout-totals_text = 'Totals'(201).
* gd_layout-totals_only = 'X'.
* gd_layout-f2code = 'DISP'. "Sets fcode for when double
* "click(press f2)
* gd_layout-zebra = 'X'.
* gd_layout-group_change_edit = 'X'.
* gd_layout-header_text = 'helllllo'.
endform. " BUILD_LAYOUT


*&amp;amp;---------------------------------------------------------------------*
*&amp;amp; Form DISPLAY_ALV_REPORT
*&amp;amp;---------------------------------------------------------------------*
* Display report using ALV grid
*----------------------------------------------------------------------*
form display_alv_report.
gd_repid = sy-repid.
call function 'REUSE_ALV_GRID_DISPLAY'
exporting
i_callback_program = gd_repid
* i_callback_top_of_page = 'TOP-OF-PAGE' "see FORM
* i_callback_user_command = 'USER_COMMAND'
* i_grid_title = outtext
is_layout = gd_layout
it_fieldcat = fieldcatalog[]
* it_special_groups = gd_tabgroup
* IT_EVENTS = GT_XEVENTS
i_save = 'X'
* is_variant = z_template

tables
t_outtab = it_ekko
exceptions
program_error = 1
others = 2.
if sy-subrc &amp;lt;&amp;gt; 0.
* MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
* WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
endif.
endform. " DISPLAY_ALV_REPORT


*&amp;amp;---------------------------------------------------------------------*
*&amp;amp; Form DATA_RETRIEVAL
*&amp;amp;---------------------------------------------------------------------*
* Retrieve data form EKPO table and populate itab it_ekko
*----------------------------------------------------------------------*
form data_retrieval.

select ebeln ebelp statu aedat matnr menge meins netpr peinh
up to 10 rows
from ekpo
into table it_ekko.
endform. " DATA_RETRIEVAL&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 03 Dec 2007 05:50:30 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/doubt-in-using-field-catalog-merge-function/m-p/3123769#M741872</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-12-03T05:50:30Z</dc:date>
    </item>
    <item>
      <title>Re: doubt in using field catalog merge function</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/doubt-in-using-field-catalog-merge-function/m-p/3123770#M741873</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Method 1 : Using Structures&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;gv_repid means current prg name, c_structure is the structure created in se11, lt_fieldcat is the fieldcat internal table&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  CALL FUNCTION 'REUSE_ALV_FIELDCATALOG_MERGE'&lt;/P&gt;&lt;P&gt;       EXPORTING&lt;/P&gt;&lt;P&gt;            i_program_name         = gv_repid&lt;/P&gt;&lt;P&gt;            i_structure_name       = c_structure&lt;/P&gt;&lt;P&gt;            i_inclname             = gv_repid&lt;/P&gt;&lt;P&gt;            i_bypassing_buffer     = 'X'&lt;/P&gt;&lt;P&gt;       CHANGING&lt;/P&gt;&lt;P&gt;            ct_fieldcat            = lt_fieldcat[]&lt;/P&gt;&lt;P&gt;       EXCEPTIONS&lt;/P&gt;&lt;P&gt;            inconsistent_interface = 1&lt;/P&gt;&lt;P&gt;            program_error          = 2&lt;/P&gt;&lt;P&gt;            OTHERS                 = 3.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Method 2 : With out using structures&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;gv_repid means current prg name, lv_itab means u r internal table, lt_fieldcat is the fielcat internal table&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  CALL FUNCTION 'REUSE_ALV_FIELDCATALOG_MERGE'&lt;/P&gt;&lt;P&gt;       EXPORTING&lt;/P&gt;&lt;P&gt;            i_program_name         = gv_repid&lt;/P&gt;&lt;P&gt;            i_internal_tabname     = lv_itab&lt;/P&gt;&lt;P&gt;            i_inclname             = gv_repid&lt;/P&gt;&lt;P&gt;       CHANGING&lt;/P&gt;&lt;P&gt;            ct_fieldcat            = gt_fieldcat[]&lt;/P&gt;&lt;P&gt;       EXCEPTIONS&lt;/P&gt;&lt;P&gt;            inconsistent_interface = 1&lt;/P&gt;&lt;P&gt;            program_error          = 2&lt;/P&gt;&lt;P&gt;            OTHERS                 = 3.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 03 Dec 2007 05:53:39 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/doubt-in-using-field-catalog-merge-function/m-p/3123770#M741873</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-12-03T05:53:39Z</dc:date>
    </item>
    <item>
      <title>Re: doubt in using field catalog merge function</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/doubt-in-using-field-catalog-merge-function/m-p/3123771#M741874</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi sravya,&lt;/P&gt;&lt;P&gt;   &lt;/P&gt;&lt;P&gt; Check whether the internal table having values or not..&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 03 Dec 2007 05:54:59 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/doubt-in-using-field-catalog-merge-function/m-p/3123771#M741874</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-12-03T05:54:59Z</dc:date>
    </item>
    <item>
      <title>Re: doubt in using field catalog merge function</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/doubt-in-using-field-catalog-merge-function/m-p/3123772#M741875</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello Sravya&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I assume you try to use an itab as input for the function module. In this case your coding needs to fulfill certain prerequisites. For a sample report have a look at &amp;lt;b&amp;gt;ZUS_SDN_FIELDCATALOG_1&amp;lt;/b&amp;gt; in thread&lt;/P&gt;&lt;P&gt;&lt;A class="jive_macro jive_macro_thread" href="https://community.sap.com/" __jive_macro_name="thread" modifiedtitle="true" __default_attr="290829"&gt;&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;However, I do not recommend this approach. Instead define you itab based on one or many DDIC structures. Next create your fieldcatalog by &amp;lt;i&amp;gt;repetitively &amp;lt;/i&amp;gt;calling the function module with the different DDIC structures and afterwards delete all fields that are not required for your list.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;  Uwe&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 03 Dec 2007 05:56:04 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/doubt-in-using-field-catalog-merge-function/m-p/3123772#M741875</guid>
      <dc:creator>uwe_schieferstein</dc:creator>
      <dc:date>2007-12-03T05:56:04Z</dc:date>
    </item>
  </channel>
</rss>

