<?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: data selection from infotypes in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/data-selection-from-infotypes/m-p/2152331#M454451</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;You can read infotypes like reading standard tables...like PA0001 or PA0003.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You can also use &amp;lt;b&amp;gt;HR_READ_INFOTYPE&amp;lt;/b&amp;gt; FM.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Greetings,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Blag.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 04 Apr 2007 22:03:03 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2007-04-04T22:03:03Z</dc:date>
    <item>
      <title>data selection from infotypes</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/data-selection-from-infotypes/m-p/2152330#M454450</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;The req is that records from one infotype need to be populated, then records from another infotype need to be populated into the same internal table based on the records retrieved from the first infotype. The second infotype has some subtypes also that need to be selected. Can someone suggest a solution with an example?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 04 Apr 2007 21:59:42 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/data-selection-from-infotypes/m-p/2152330#M454450</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-04-04T21:59:42Z</dc:date>
    </item>
    <item>
      <title>Re: data selection from infotypes</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/data-selection-from-infotypes/m-p/2152331#M454451</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;You can read infotypes like reading standard tables...like PA0001 or PA0003.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You can also use &amp;lt;b&amp;gt;HR_READ_INFOTYPE&amp;lt;/b&amp;gt; FM.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Greetings,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Blag.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 04 Apr 2007 22:03:03 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/data-selection-from-infotypes/m-p/2152331#M454451</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-04-04T22:03:03Z</dc:date>
    </item>
    <item>
      <title>Re: data selection from infotypes</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/data-selection-from-infotypes/m-p/2152332#M454452</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello Sandeep&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Have a look at my Code snippet where I have described a&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;a href="https://wiki.sdn.sap.com/wiki/display/Snippets/Unified&lt;EM&gt;Access&lt;/EM&gt;to&lt;EM&gt;All&lt;/EM&gt;HR+Infotypes"&amp;gt;Unified Access to All HR Infotypes&amp;lt;/a&amp;gt;&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>Wed, 04 Apr 2007 22:26:44 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/data-selection-from-infotypes/m-p/2152332#M454452</guid>
      <dc:creator>uwe_schieferstein</dc:creator>
      <dc:date>2007-04-04T22:26:44Z</dc:date>
    </item>
    <item>
      <title>Re: data selection from infotypes</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/data-selection-from-infotypes/m-p/2152333#M454453</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;hey uwe, &lt;/P&gt;&lt;P&gt;thanx for ur response, but could you please give me an example using select statements? also for info types with sub types.&lt;/P&gt;&lt;P&gt;Thank you&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 04 Apr 2007 22:41:20 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/data-selection-from-infotypes/m-p/2152333#M454453</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-04-04T22:41:20Z</dc:date>
    </item>
    <item>
      <title>Re: data selection from infotypes</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/data-selection-from-infotypes/m-p/2152334#M454454</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;yeah the thing is.. i have an internal table and i populated some fields taking values from IT 0002. now for all the values that i took from 0002 i have to populate the corresponding values(ie for all the pernr s) from another infotype 0105. how do u go about doing this. some fields that i need to populate from 0105 have subtypes too.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 04 Apr 2007 22:46:42 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/data-selection-from-infotypes/m-p/2152334#M454454</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-04-04T22:46:42Z</dc:date>
    </item>
    <item>
      <title>Re: data selection from infotypes</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/data-selection-from-infotypes/m-p/2152335#M454455</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Do something like this...&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;
SELECT ENDDA BEGDA BUKRS WERKS 
INTO TABLE T_PA002_0105
FROM ( PA002 INNER JOIN PA0105
            ON PA002~PERNR EQ PA0105~PERNR )
WHERE PERNR EQ P_PERNR.
&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Greetings,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Blag.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 04 Apr 2007 23:21:48 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/data-selection-from-infotypes/m-p/2152335#M454455</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-04-04T23:21:48Z</dc:date>
    </item>
    <item>
      <title>Re: data selection from infotypes</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/data-selection-from-infotypes/m-p/2152336#M454456</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Sandeep,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Programming in HR module is something different, the best is that you use the logical database PNP. Set this value in the Program attribute. Using select statement in HR programming is not advicable. Proper HR programming should be as below:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;
REPORT  yhr_program
       NO STANDARD PAGE HEADING
       LINE-COUNT 60  LINE-SIZE 600.

*----------------------------------------------------------------------*
* tables
*----------------------------------------------------------------------*
TABLES: pernr.

*----------------------------------------------------------------------*
* infotypes.
*----------------------------------------------------------------------*
INFOTYPES: 0000,   "Personal Actions
           0001,   "Org. Assignment
           0002,   "Personal Data
           0105.   "Communication Infotype
*----------------------------------------------------------------------*
* data declaration.
*----------------------------------------------------------------------*
Data: Begin of I_TAB occurs 0,
         PERNR type persno, "employee number
         NACHN type PAD_NACHN, "employee's last name
         USRID_LONG type COMM_ID_LONG, "IT0105 user id
         end of I_TAB.

*-----------------------------------------------------------------------
* START-OF-SELECTION.
*-----------------------------------------------------------------------
START-OF-SELECTION.

*-----------------------------------------------------------------------
* GET FROM LOGICAL DB PNP
*-----------------------------------------------------------------------
GET pernr.

* rp-provide-from-last is an macro used in HR programming can be found in 
* table trmac.
*
* p0002 is the infotype structure
* space is for subtype &amp;lt;-- in this case there is no subtype
* pn-begda is for begin date
* pn-endda is for end date

* getting employee infty 0002 record
  rp-provide-from-last p0002 space pn-begda pn-endda.

* p0105 is the infotype structure
* '0001' is for IT0105 subtype for communication
* pn-begda is for begin date
* pn-endda is for end date

* getting employee infty 0105 record
  rp-provide-from-last p0105 '0001' pn-begda pn-endda.

  i_tab-pernr = pernr-pernr.
  i_tab-nachn = p0002-nachn.
  i_tab-USRID_LONG = p0105-USRID_LONG.
  append i_tab. clear i_tab.

*----------------------------------------------------------------------*
* END-OF-SELECTION
*----------------------------------------------------------------------*
END-OF-SELECTION.

perform print_report.
...... more codes....
&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope it helps.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Benefits:&lt;/P&gt;&lt;P&gt;1) You have all the auth issue settled.&lt;/P&gt;&lt;P&gt;2) Macros shorthen your code&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 05 Apr 2007 03:34:17 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/data-selection-from-infotypes/m-p/2152336#M454456</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-04-05T03:34:17Z</dc:date>
    </item>
    <item>
      <title>Re: data selection from infotypes</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/data-selection-from-infotypes/m-p/2152337#M454457</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thank you for all the inputs.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 18 Jul 2008 21:38:16 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/data-selection-from-infotypes/m-p/2152337#M454457</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-07-18T21:38:16Z</dc:date>
    </item>
  </channel>
</rss>

