<?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 Aging report in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/aging-report/m-p/2589905#M592887</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;hi I am developing a aging report for which I am getting fields from the tables EKPO and EKKO based on &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;
s_gjahr  FOR bsid-gjahr  OBLIGATORY.    "Document Fiscal year

p_date   TYPE vbak-aedat OBLIGATORY,    "A/P Open items

p_bukrs  TYPE t001-bukrs OBLIGATORY.    "Company

s_ekorg  FOR mepo1222-ekorg OBLIGATORY, "Purchasing Organization
                s_ekgrp  FOR mepo1222-ekgrp,            "Purchasing group
                s_zterm  FOR bseg-zterm,                "Terms
                s_ebeln  FOR bseg-ebeln,                "Purchase order
                s_hkont  FOR bseg-hkont,                "Reconciliation Account.
                s_blart  FOR invfo-blart OBLIGATORY,    "Document type
                s_date   FOR bseg-zfbdt NO-DISPLAY. 



  SELECT * FROM ekko INTO TABLE tbl_ekko WHERE bukrs = p_bukrs
                                         AND   zterm IN s_zterm
                                         AND   ekorg IN s_ekorg
                                         AND   ekgrp IN s_ekgrp.

  IF tbl_ekko[] IS NOT INITIAL.

    SELECT * FROM ekpo INTO TABLE tbl_ekpo FOR ALL ENTRIES IN tbl_ekko
                                           WHERE ebeln = tbl_ekko-ebeln
                                           AND   bukrs = p_bukrs
                                           AND   repos = 'X'
                                           AND   werks IN s_werks. "additonal.

ENDIF.

&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;Now my problem is I need to combine the data I have selected from EKKO with a table which has EBELN, I found BSIK but that doesnt have the EBELN field filled.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Can you tell me some table other than BSEG ( performace issue ) which I can use to select my entries with Inner join... only BSIK has BLART not BSEG..&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I will definitely award points for all the helpful answers&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 30 Jul 2007 15:10:51 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2007-07-30T15:10:51Z</dc:date>
    <item>
      <title>Aging report</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/aging-report/m-p/2589905#M592887</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;hi I am developing a aging report for which I am getting fields from the tables EKPO and EKKO based on &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;
s_gjahr  FOR bsid-gjahr  OBLIGATORY.    "Document Fiscal year

p_date   TYPE vbak-aedat OBLIGATORY,    "A/P Open items

p_bukrs  TYPE t001-bukrs OBLIGATORY.    "Company

s_ekorg  FOR mepo1222-ekorg OBLIGATORY, "Purchasing Organization
                s_ekgrp  FOR mepo1222-ekgrp,            "Purchasing group
                s_zterm  FOR bseg-zterm,                "Terms
                s_ebeln  FOR bseg-ebeln,                "Purchase order
                s_hkont  FOR bseg-hkont,                "Reconciliation Account.
                s_blart  FOR invfo-blart OBLIGATORY,    "Document type
                s_date   FOR bseg-zfbdt NO-DISPLAY. 



  SELECT * FROM ekko INTO TABLE tbl_ekko WHERE bukrs = p_bukrs
                                         AND   zterm IN s_zterm
                                         AND   ekorg IN s_ekorg
                                         AND   ekgrp IN s_ekgrp.

  IF tbl_ekko[] IS NOT INITIAL.

    SELECT * FROM ekpo INTO TABLE tbl_ekpo FOR ALL ENTRIES IN tbl_ekko
                                           WHERE ebeln = tbl_ekko-ebeln
                                           AND   bukrs = p_bukrs
                                           AND   repos = 'X'
                                           AND   werks IN s_werks. "additonal.

ENDIF.

&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;Now my problem is I need to combine the data I have selected from EKKO with a table which has EBELN, I found BSIK but that doesnt have the EBELN field filled.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Can you tell me some table other than BSEG ( performace issue ) which I can use to select my entries with Inner join... only BSIK has BLART not BSEG..&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I will definitely award points for all the helpful answers&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 30 Jul 2007 15:10:51 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/aging-report/m-p/2589905#M592887</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-07-30T15:10:51Z</dc:date>
    </item>
    <item>
      <title>Re: Aging report</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/aging-report/m-p/2589906#M592888</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;U need to read the EKBE table here you should fine the FI invoices linked to PO&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Max&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 30 Jul 2007 15:13:04 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/aging-report/m-p/2589906#M592888</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-07-30T15:13:04Z</dc:date>
    </item>
    <item>
      <title>Re: Aging report</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/aging-report/m-p/2589907#M592889</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;RSEG was the missing table which I needed to connect EKBE with BSIK&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 08 Aug 2008 09:55:27 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/aging-report/m-p/2589907#M592889</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-08-08T09:55:27Z</dc:date>
    </item>
  </channel>
</rss>

