<?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: RFC_READ_TABLE in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/rfc-read-table/m-p/4822633#M1128558</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;I hope you are aware that RFC_READ_TABLE was only supposed to be used for training! To be more precise, it is used by learners to see how you access the database directly. I remember reading somewhere that this function is not supported by SAP (although it is included in software releases).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Also be aware that the authorization needed to run this function includes a few admin level authorization objects - something which you will normally never get for client projects. The ability to use this function gives you complete power to read any table from the database.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Try and use something else to access the data rather than this module.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;T00th.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 05 Dec 2008 10:12:12 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2008-12-05T10:12:12Z</dc:date>
    <item>
      <title>RFC_READ_TABLE</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/rfc-read-table/m-p/4822626#M1128551</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;I created a program to display a field ( BURKS)  from the table KNB5. &lt;/P&gt;&lt;P&gt;This table is in R / 3, and I want to call it from another system. I used the Funtion Module "RFC_READ_TABLE " but I do not know what do I make in the parameters of this function.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The FM look like this:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;CALL FUNCTION 'RFC_READ_TABLE'&lt;/P&gt;&lt;P&gt;destination 'destination'&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;EXPORTING&lt;/P&gt;&lt;P&gt;       QUERY_TABLE = 'KNB5' &lt;/P&gt;&lt;P&gt;TABLES&lt;/P&gt;&lt;P&gt;       OPTIONS =  ???&lt;/P&gt;&lt;P&gt;       FIELDS = ???&lt;/P&gt;&lt;P&gt;       DATA = ???&lt;/P&gt;&lt;P&gt;EXCEPTIONS&lt;/P&gt;&lt;P&gt;      TABLE_NOT_AVAILABLE = 1&lt;/P&gt;&lt;P&gt;      TABLE_WITHOUT_DATA = 2&lt;/P&gt;&lt;P&gt;      OPTION_NOT_VALID = 3&lt;/P&gt;&lt;P&gt;      FIELD_NOT_VALID = 4&lt;/P&gt;&lt;P&gt;      NOT_AUTHORIZED = 5&lt;/P&gt;&lt;P&gt;      DATA_BUFFER_EXCEEDED = 6&lt;/P&gt;&lt;P&gt;      OTHERS = 7.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;How can I use this FM ?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thank you.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;mll mat.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 02 Dec 2008 11:43:37 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/rfc-read-table/m-p/4822626#M1128551</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-12-02T11:43:37Z</dc:date>
    </item>
    <item>
      <title>Re: RFC_READ_TABLE</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/rfc-read-table/m-p/4822627#M1128552</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;Refer to this link...&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;A class="jive_macro jive_macro_message" href="https://community.sap.com/" __jive_macro_name="message" modifiedtitle="true" __default_attr="3954395"&gt;&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;A class="jive_macro jive_macro_message" href="https://community.sap.com/" __jive_macro_name="message" modifiedtitle="true" __default_attr="3335043"&gt;&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Edited by: avinash kodarapu on Dec 2, 2008 5:19 PM&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 02 Dec 2008 11:47:56 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/rfc-read-table/m-p/4822627#M1128552</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-12-02T11:47:56Z</dc:date>
    </item>
    <item>
      <title>Re: RFC_READ_TABLE</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/rfc-read-table/m-p/4822628#M1128553</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;check this:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt; DATA: options TYPE TABLE OF rfc_db_opt .&lt;/P&gt;&lt;P&gt;  DATA: fields TYPE TABLE OF rfc_db_fld  .&lt;/P&gt;&lt;P&gt;DATA: data TYPE TABLE OF tab512 .&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;CALL FUNCTION 'RFC_READ_TABLE'&lt;/P&gt;&lt;P&gt;           DESTINATION rfc_target_destination&lt;/P&gt;&lt;P&gt;    EXPORTING&lt;/P&gt;&lt;P&gt;         query_table                = node_query_tab&lt;/P&gt;&lt;P&gt;         delimiter                  = ' '&lt;/P&gt;&lt;P&gt;         no_data                    = ' '&lt;/P&gt;&lt;P&gt;         rowskips                   = 0&lt;/P&gt;&lt;P&gt;         rowcount                   = 0&lt;/P&gt;&lt;P&gt;       TABLES&lt;/P&gt;&lt;P&gt;          options                    = options&lt;/P&gt;&lt;P&gt;          fields                     = fields&lt;/P&gt;&lt;P&gt;          data                       = data&lt;/P&gt;&lt;P&gt;      EXCEPTIONS&lt;/P&gt;&lt;P&gt;         table_not_available        = 1&lt;/P&gt;&lt;P&gt;         table_without_data         = 2&lt;/P&gt;&lt;P&gt;         option_not_valid           = 3&lt;/P&gt;&lt;P&gt;         field_not_valid            = 4&lt;/P&gt;&lt;P&gt;         not_authorized             = 5&lt;/P&gt;&lt;P&gt;         data_buffer_exceeded       = 6&lt;/P&gt;&lt;P&gt;         OTHERS                     = 7.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Edited by: AD on Dec 2, 2008 12:48 PM&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Edited by: AD on Dec 2, 2008 12:50 PM&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 02 Dec 2008 11:48:08 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/rfc-read-table/m-p/4822628#M1128553</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-12-02T11:48:08Z</dc:date>
    </item>
    <item>
      <title>Re: RFC_READ_TABLE</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/rfc-read-table/m-p/4822629#M1128554</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Matt,&lt;/P&gt;&lt;P&gt;you can see the sample example given in th link below:&lt;/P&gt;&lt;P&gt;&lt;A href="http://www.sap-integration.net/Default.aspx?tabid=405&amp;amp;forumid=181&amp;amp;postid=49657&amp;amp;view=topic&amp;amp;language=fr-FR" target="test_blank"&gt;http://www.sap-integration.net/Default.aspx?tabid=405&amp;amp;forumid=181&amp;amp;postid=49657&amp;amp;view=topic&amp;amp;language=fr-FR&lt;/A&gt;.&lt;/P&gt;&lt;P&gt;Hope it helps,&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Rahul&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 02 Dec 2008 11:48:27 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/rfc-read-table/m-p/4822629#M1128554</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-12-02T11:48:27Z</dc:date>
    </item>
    <item>
      <title>Re: RFC_READ_TABLE</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/rfc-read-table/m-p/4822630#M1128555</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;PRE&gt;&lt;CODE&gt;DATA T_DATA TYPE STANDARD TABLE OF TAB512.

CALL FUNCTION 'RFC_READ_TABLE' destination 'destination'
  EXPORTING
     QUERY_TABLE = 'KNB5'
  TABLES
*     OPTIONS = ???
*     FIELDS = ???
     DATA = T_DATA
  EXCEPTIONS
     TABLE_NOT_AVAILABLE = 1
     TABLE_WITHOUT_DATA = 2
     OPTION_NOT_VALID = 3
     FIELD_NOT_VALID = 4
     NOT_AUTHORIZED = 5
     DATA_BUFFER_EXCEEDED = 6
    OTHERS = 7.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The query result is stored in the internal table T_DATA.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;U need to transfer OPTIONS only if u need to create a filter in oder to select certain records, u need to transfer FIELDS only if u nedd to extract the data of certain fields of KNB5&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;See this sample:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;DATA: T_OPTIONS TYPE TABLE OF RFC_DB_OPT WITH HEADER LINE.
DATA: T_FIELDS  TYPE TABLE OF RFC_DB_FLD WITH HEADER LINE.
DATA: T_DATA    TYPE TABLE OF TAB512     WITH HEADER LINE.



PERFORM FILL_OPTIONS USING: 'KUNNR' '0000000001' 'AND',
                            'BUKRS' 'MAAB' SPACE.
PERFORM FILL_FIELDS USING: 'KUNNR', 'BUKRS', 'MAHNA'.

CALL FUNCTION 'RFC_READ_TABLE'
  EXPORTING
    QUERY_TABLE                = 'KNB5'
*   DELIMITER                  = ' '
*   NO_DATA                    = ' '
*   ROWSKIPS                   = 0
*   ROWCOUNT                   = 0
  TABLES
    OPTIONS                    = T_OPTIONS
    FIELDS                     = T_FIELDS
    DATA                       = T_DATA.

LOOP AT T_DATA.
  WRITE / T_DATA.
ENDLOOP.



*&amp;amp;---------------------------------------------------------------------*
*&amp;amp;      Form  FILL_OPTIONS
*&amp;amp;---------------------------------------------------------------------*
*       text
*----------------------------------------------------------------------*
*      --&amp;gt;P_FIELD  text
*      --&amp;gt;P_VALUE  text
*      --&amp;gt;P_OPT  text
*----------------------------------------------------------------------*
FORM FILL_OPTIONS USING    P_FIELD
                           P_VALUE
                           P_OPT.
  DATA: VALUE(15).

  CONCATENATE '''' P_VALUE '''' INTO VALUE.
  CONCATENATE P_FIELD '=' VALUE P_OPT INTO T_OPTIONS SEPARATED BY SPACE.
  APPEND T_OPTIONS.
ENDFORM.                    " FILL_OPTIONS
*&amp;amp;---------------------------------------------------------------------*
*&amp;amp;      Form  FILL_FIELDS
*&amp;amp;---------------------------------------------------------------------*
*       text
*----------------------------------------------------------------------*
*      --&amp;gt;P_0045   text
*----------------------------------------------------------------------*
FORM FILL_FIELDS USING   P_FIELD.

T_FIELDS-FIELDNAME = P_FIELD.
APPEND T_FIELDS.

ENDFORM.                    " FILL_FIELDS&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The table T_FIELDS is usually empty, but u should consider the system store the data in a string of 512 char.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Anyway how to call this fm depends on from u need to call it&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Max&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 02 Dec 2008 11:51:05 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/rfc-read-table/m-p/4822630#M1128555</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-12-02T11:51:05Z</dc:date>
    </item>
    <item>
      <title>Re: RFC_READ_TABLE</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/rfc-read-table/m-p/4822631#M1128556</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi mat,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  Check the thread below:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;A class="jive_macro jive_macro_message" href="https://community.sap.com/" __jive_macro_name="message" modifiedtitle="true" __default_attr="6202353"&gt;&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;With luck,&lt;/P&gt;&lt;P&gt;Pritam.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 02 Dec 2008 12:18:37 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/rfc-read-table/m-p/4822631#M1128556</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-12-02T12:18:37Z</dc:date>
    </item>
    <item>
      <title>Re: RFC_READ_TABLE</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/rfc-read-table/m-p/4822632#M1128557</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;Thank you very match for your replay.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If I want to read the data from the table STMP_DOKHL with a condition, I put this code:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;loop at T_DATA where kunnr = '651'.&lt;/P&gt;&lt;P&gt;      write:/ T_DATA.&lt;/P&gt;&lt;P&gt;endloop.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;But a message appears indicating that No component exists with the name Knnr.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;mll mat.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 05 Dec 2008 10:03:37 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/rfc-read-table/m-p/4822632#M1128557</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-12-05T10:03:37Z</dc:date>
    </item>
    <item>
      <title>Re: RFC_READ_TABLE</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/rfc-read-table/m-p/4822633#M1128558</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;I hope you are aware that RFC_READ_TABLE was only supposed to be used for training! To be more precise, it is used by learners to see how you access the database directly. I remember reading somewhere that this function is not supported by SAP (although it is included in software releases).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Also be aware that the authorization needed to run this function includes a few admin level authorization objects - something which you will normally never get for client projects. The ability to use this function gives you complete power to read any table from the database.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Try and use something else to access the data rather than this module.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;T00th.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 05 Dec 2008 10:12:12 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/rfc-read-table/m-p/4822633#M1128558</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-12-05T10:12:12Z</dc:date>
    </item>
    <item>
      <title>Re: RFC_READ_TABLE</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/rfc-read-table/m-p/4822634#M1128559</link>
      <description>&lt;P&gt;REPORT Z_TEST2.&lt;/P&gt;&lt;P&gt;data: it_data TYPE STANDARD TABLE OF TAB512, "TABLES PARAM&lt;BR /&gt; wa_data LIKE LINE OF it_data .&lt;BR /&gt;&lt;BR /&gt;DATA: options TYPE TABLE OF rfc_db_opt .&lt;BR /&gt;&lt;BR /&gt;DATA: fields TYPE TABLE OF rfc_db_fld .&lt;BR /&gt; DATA : it_data1 TYPE REF TO cl_salv_table.&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;CALL FUNCTION 'RFC_READ_TABLE'&lt;BR /&gt; EXPORTING&lt;BR /&gt; query_table = 'ADR6' " Table read&lt;BR /&gt;* delimiter = SPACE " Sign for indicating field limits in DATA&lt;BR /&gt;* no_data = SPACE " If &amp;lt;&amp;gt; SPACE, only FIELDS is filled&lt;BR /&gt;* rowskips = 0&lt;BR /&gt;* rowcount = 0&lt;BR /&gt; TABLES&lt;BR /&gt; options = options "*" " Selection entries, "WHERE clauses" (in)&lt;BR /&gt; fields = fields " Names (in) and structure (out) of fields read&lt;BR /&gt; data = it_data " Data read (out)&lt;BR /&gt; EXCEPTIONS&lt;BR /&gt; table_not_available = 1&lt;BR /&gt; table_without_data = 2&lt;BR /&gt; option_not_valid = 3&lt;BR /&gt; field_not_valid = 4&lt;BR /&gt; not_authorized = 5&lt;BR /&gt; data_buffer_exceeded = 6&lt;BR /&gt; others = 7&lt;BR /&gt; .&lt;BR /&gt;&lt;BR /&gt;IF sy-subrc &amp;lt;&amp;gt; 0.&lt;BR /&gt; MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno&lt;BR /&gt; WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.&lt;BR /&gt;ENDIF.&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;CALL METHOD CL_SALV_TABLE=&amp;gt;FACTORY&lt;BR /&gt;* EXPORTING&lt;BR /&gt;* LIST_DISPLAY = IF_SALV_C_BOOL_SAP=&amp;gt;FALSE&lt;BR /&gt;* R_CONTAINER =&lt;BR /&gt;* CONTAINER_NAME =&lt;BR /&gt; IMPORTING&lt;BR /&gt; R_SALV_TABLE = it_data1&lt;BR /&gt; CHANGING&lt;BR /&gt; T_TABLE = it_data.&lt;BR /&gt;it_data1-&amp;gt;display( ).&lt;/P&gt;</description>
      <pubDate>Tue, 20 Jul 2021 13:21:01 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/rfc-read-table/m-p/4822634#M1128559</guid>
      <dc:creator>former_member733010</dc:creator>
      <dc:date>2021-07-20T13:21:01Z</dc:date>
    </item>
  </channel>
</rss>

