<?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 hashed alg in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/hashed-alg/m-p/3174230#M755355</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;what is hashed algorithm,&lt;/P&gt;&lt;P&gt;pls answer this question,&lt;/P&gt;&lt;P&gt;amruth.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 13 Dec 2007 08:59:29 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2007-12-13T08:59:29Z</dc:date>
    <item>
      <title>hashed alg</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/hashed-alg/m-p/3174230#M755355</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;what is hashed algorithm,&lt;/P&gt;&lt;P&gt;pls answer this question,&lt;/P&gt;&lt;P&gt;amruth.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 13 Dec 2007 08:59:29 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/hashed-alg/m-p/3174230#M755355</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-12-13T08:59:29Z</dc:date>
    </item>
    <item>
      <title>Re: hashed alg</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/hashed-alg/m-p/3174231#M755356</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 these out (general information):&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hash function&lt;/P&gt;&lt;P&gt;Hash table&lt;/P&gt;&lt;P&gt;Hash list&lt;/P&gt;&lt;P&gt;Hash tree&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;if you want a internal table which allows faster reading then you should go for hashed table , but the disadvantage is that you cannot use index to read the hashed itab.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;you have to use keys.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;sample declratin of hashed table.&lt;/P&gt;&lt;P&gt;data:cc_text TYPE HASHED TABLE OF /bi0/tcostcenter WITH UNIQUE KEY co_area costcenter langu .&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;to read entries from the hashed table.&lt;/P&gt;&lt;P&gt;READ TABLE cc_text INTO wa_cc_text WITH KEY&lt;/P&gt;&lt;P&gt;co_area = coarea&lt;/P&gt;&lt;P&gt;costcenter = cctr&lt;/P&gt;&lt;P&gt;langu = sy-langu .&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hash table access time dosent increase based on the number of records, its constant.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;check out the ABAP key work documentation for different types of internal table and their usages. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;gt; How Hash Algorithm and Logarithmic Algorithm works&lt;/P&gt;&lt;P&gt;&amp;gt; to fetch the data ?&lt;/P&gt;&lt;P&gt;Fetching part is the same as standard internal table, only when you work with the internal table, than it's different.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;gt; What the basic things we have to keep in mined when&lt;/P&gt;&lt;P&gt;&amp;gt; we select the Internal table ?&lt;/P&gt;&lt;P&gt;Eg Performance.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;gt; Any rule for selecting the internal table which&lt;/P&gt;&lt;P&gt;&amp;gt; should be followed ?&lt;/P&gt;&lt;P&gt;Standard table is quite easy to use, but you might loose performance with it. Most of the time hash table is the fastest.&lt;/P&gt;&lt;P&gt;Using standard table and sort it is a good choice, when you access in READ TABLE via BINARY SEARCH.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Check 'ABAP for Power Users' SAP tutorial in SDN, it very good explains this topic in detail.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="http://www.sap.info/public/en/category.php4/Category-28943c61b1e60d84b/page/0/article/Article-11988425e684a338ff/en" target="test_blank"&gt;http://www.sap.info/public/en/category.php4/Category-28943c61b1e60d84b/page/0/article/Article-11988425e684a338ff/en&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Reward points if found helpful&amp;#133;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Cheers,&lt;/P&gt;&lt;P&gt;Chandra Sekhar.&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;&lt;/P&gt;&lt;P&gt;If you use only partial key to search in a hash table, this would take as long as standard table (based on my experience). You must specify all key fields in your READ statement get the benefit of hash table. In case you only had first few fields of a key that you want to search by, you should use SORTED table instead of a HASH table.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Example:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;data:cc_text TYPE HASHED TABLE OF /bi0/tcostcenter WITH UNIQUE KEY co_area costcenter langu.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If you performed your READ the following way, the performance would be constant.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;READ TABLE cc_text INTO wa_cc_text WITH KEY&lt;/P&gt;&lt;P&gt;co_area = coarea&lt;/P&gt;&lt;P&gt;costcenter = cctr&lt;/P&gt;&lt;P&gt;langu = sy-langu .&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If you performed your READ the following way, the performance would be much slower.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;READ TABLE cc_text INTO wa_cc_text &amp;lt;b&amp;gt;WITH KEY&lt;/P&gt;&lt;P&gt;co_area = coarea.&amp;lt;/b&amp;gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 15 Dec 2007 11:01:24 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/hashed-alg/m-p/3174231#M755356</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-12-15T11:01:24Z</dc:date>
    </item>
  </channel>
</rss>

