<?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: Code to derive the characteristic from attribute in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/code-to-derive-the-characteristic-from-attribute/m-p/2005857#M408841</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Do not use table kay....&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Use "with key" instead.....&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope this solution was helpful&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;PS : Please award points if helpful.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 20 Mar 2007 04:09:33 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2007-03-20T04:09:33Z</dc:date>
    <item>
      <title>Code to derive the characteristic from attribute</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/code-to-derive-the-characteristic-from-attribute/m-p/2005856#M408840</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi there, Please help me with this code , I am trying to derive the profit center from cost center since profit center  is available as attribute of cost center  in the transformation in BI 7.0. Please revise the code and let me know if i can get it resolved&lt;/P&gt;&lt;P&gt;but this code is giving me error as below&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Soniya Kapoor &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;Error&amp;lt;/b&amp;gt;&lt;/P&gt;&lt;P&gt;E:The data object "L_S_COSTCENTER" has no structure and therefore no&lt;/P&gt;&lt;P&gt;component called "PROFIT_CTR". called "PROFIT_CTR".&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;&lt;/P&gt;&lt;P&gt;ABAP Code&amp;lt;/b&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;DATA: l_th_costcenter TYPE HASHED TABLE OF /BI0/QCOSTCENTER&lt;/P&gt;&lt;P&gt;WITH UNIQUE KEY costcenter.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;DATA : l_S_COSTCENTER.&lt;/P&gt;&lt;P&gt;DATA : PROFIT_CTR.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;IF SOURCE_FIELDS-profit_ctr = space.&lt;/P&gt;&lt;P&gt;IF l_th_costcenter[] IS INITIAL.&lt;/P&gt;&lt;P&gt;SELECT * FROM /BI0/QCOSTCENTER INTO TABLE l_th_costcenter&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;WHERE objvers = `A`&lt;/P&gt;&lt;P&gt;AND datefrom &amp;lt;= sy-Cdate&lt;/P&gt;&lt;P&gt;AND dateto &amp;gt;= sy-Cdate.&lt;/P&gt;&lt;P&gt;ENDIF.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;READ TABLE l_th_costcenter INTO l_S_COSTCENTER&lt;/P&gt;&lt;P&gt;WITH TABLE KEY&lt;/P&gt;&lt;P&gt;costcenter = SOURCE_FIELDS-costcenter.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;IF SY-SUBRC = 0.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;RESULT = L_S_COSTCENTER-profit_ctr.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;ELSE.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;RESULT = `DUMMY`&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;END IF.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;ELSE.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;RESULT = SOURCE_FIELDS - profit_ctr.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;ENDIF.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 19 Mar 2007 16:53:21 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/code-to-derive-the-characteristic-from-attribute/m-p/2005856#M408840</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-03-19T16:53:21Z</dc:date>
    </item>
    <item>
      <title>Re: Code to derive the characteristic from attribute</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/code-to-derive-the-characteristic-from-attribute/m-p/2005857#M408841</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Do not use table kay....&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Use "with key" instead.....&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope this solution was helpful&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;PS : Please award points if helpful.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 20 Mar 2007 04:09:33 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/code-to-derive-the-characteristic-from-attribute/m-p/2005857#M408841</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-03-20T04:09:33Z</dc:date>
    </item>
  </channel>
</rss>

