<?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: packed type in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/packed-type/m-p/2628186#M604068</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;this is the error description.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;An internal table field is too short.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 27 Jul 2007 05:33:02 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2007-07-27T05:33:02Z</dc:date>
    <item>
      <title>packed type</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/packed-type/m-p/2628181#M604063</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi experts&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;       I am using this field   &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;       bdmng LIKE resb-bdmng,          *  0.010&lt;/P&gt;&lt;P&gt;       iamng LIKE afpo-iamng,            * 150&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;      it_final-iamng = it_final-bdmng / it_final-psmng.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;       when i do calculations in program the result of iamng &lt;/P&gt;&lt;P&gt;        is supposed to  6.66667E-05, but it assigns iamng = 0.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;       but iamng takes Zero, i don't know why, is this problem with packed type.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;       how to solve this problem and declare this decimal places.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;      Thanks in advance.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;Rajaram&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 27 Jul 2007 04:51:43 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/packed-type/m-p/2628181#M604063</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-07-27T04:51:43Z</dc:date>
    </item>
    <item>
      <title>Re: packed type</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/packed-type/m-p/2628182#M604064</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi&lt;/P&gt;&lt;P&gt;All these are QUAN type field with 3 decimals&lt;/P&gt;&lt;P&gt;If you want integer as output for IAMNG field declare another variable of TYPE I and then move this IAMNG to that variable and display&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;check the values of the fields in debug mode and see&lt;/P&gt;&lt;P&gt;if not it_final-psmng is initial.&lt;/P&gt;&lt;P&gt;it_final-iamng = it_final-bdmng / it_final-psmng.&lt;/P&gt;&lt;P&gt;endif.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;Reward points for useful Answers&amp;lt;/b&amp;gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;Anji&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 27 Jul 2007 05:00:25 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/packed-type/m-p/2628182#M604064</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-07-27T05:00:25Z</dc:date>
    </item>
    <item>
      <title>Re: packed type</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/packed-type/m-p/2628183#M604065</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;actual value of   6.66667E-05 is 0.0000666667 so when you are taking in iamng( which has decimals 3) it only takes first 3 digit after the decimal and gives you the value 0.000. so as per your requirement you have to assign some typ p variable with decimals 5 or more to get the value.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;by default iamng is of decimals 3.. so you declare like that&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;data : result type p decimals 6.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;result = it_final-bdmng / it_final-psmng.&lt;/P&gt;&lt;P&gt;write : / result.&lt;/P&gt;&lt;P&gt;and before doing the calculation check it_final-psmng is non zero value as said by anji.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;regards&lt;/P&gt;&lt;P&gt;shiba dutta&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 27 Jul 2007 05:10:52 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/packed-type/m-p/2628183#M604065</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-07-27T05:10:52Z</dc:date>
    </item>
    <item>
      <title>Re: packed type</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/packed-type/m-p/2628184#M604066</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Its ok but again it give the following error yar&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;An internal table field is too short.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;CX_SY_ARITHMETIC_OVERFLOW'&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;                                 &lt;/P&gt;&lt;P&gt;The name of the field is "BDMNG".&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;how to solve this.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 27 Jul 2007 05:24:23 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/packed-type/m-p/2628184#M604066</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-07-27T05:24:23Z</dc:date>
    </item>
    <item>
      <title>Re: packed type</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/packed-type/m-p/2628185#M604067</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;thank you very much yar&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;and bdmng also gives dump with the following error.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;CX_SY_ARITHMETIC_OVERFLOW'&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;when i try the collect stmt.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;how to solve this.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 27 Jul 2007 05:32:02 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/packed-type/m-p/2628185#M604067</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-07-27T05:32:02Z</dc:date>
    </item>
    <item>
      <title>Re: packed type</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/packed-type/m-p/2628186#M604068</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;this is the error description.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;An internal table field is too short.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 27 Jul 2007 05:33:02 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/packed-type/m-p/2628186#M604068</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-07-27T05:33:02Z</dc:date>
    </item>
    <item>
      <title>Re: packed type</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/packed-type/m-p/2628187#M604069</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;i think you are not clearing properly your field. In somecases it may added or multiply with other value and give you this error just check it ... and if possible please paste the code..&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;regards&lt;/P&gt;&lt;P&gt;shiba dutta&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 27 Jul 2007 05:34:56 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/packed-type/m-p/2628187#M604069</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-07-27T05:34:56Z</dc:date>
    </item>
    <item>
      <title>Re: packed type</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/packed-type/m-p/2628188#M604070</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;when i treid this code, am getting the error.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt; loop at itab1.&lt;/P&gt;&lt;P&gt;    move-corresponding itab1 to it_final.&lt;/P&gt;&lt;P&gt;    collect it_final.&lt;/P&gt;&lt;P&gt;  endloop.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;again problem with bdmng, what could be.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 27 Jul 2007 05:38:55 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/packed-type/m-p/2628188#M604070</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-07-27T05:38:55Z</dc:date>
    </item>
    <item>
      <title>Re: packed type</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/packed-type/m-p/2628189#M604071</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;its may be for the collect statement because it is adding the bdmng field every time when the key field of your int table is repeated. So if it is necessary to add tose bdmng then i think it is not possible by quantity field . If your quantity field does not contain any decimal value(e.g. if your qty 12 whole number) then you have to take it in type n field . If it contains decimal value then you have to assign the sum in a character field. But for both the cases collect will not work you have to do the sum manually.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;regards&lt;/P&gt;&lt;P&gt;shiba dutta&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 27 Jul 2007 05:47:08 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/packed-type/m-p/2628189#M604071</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-07-27T05:47:08Z</dc:date>
    </item>
    <item>
      <title>Re: packed type</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/packed-type/m-p/2628190#M604072</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;no collect is working for some data with quan field ,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;but some of the cases it is not working, i don't know why.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;see this error description.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt; An exception occurred. This exception will be dealt with in more detail                &lt;/P&gt;&lt;P&gt; below. The exception, assigned to the class 'CX_SY_ARITHMETIC_OVERFLOW', was           &lt;/P&gt;&lt;P&gt;  not caught, which                                                                     &lt;/P&gt;&lt;P&gt;  led to a runtime error. The reason for this exception is:                             &lt;/P&gt;&lt;P&gt; The COLLECT statement stores totals in the internal table                              &lt;/P&gt;&lt;P&gt;  "\PROGRAM=Z_PGM\DATA=IT_FINAL[]",                                                     &lt;/P&gt;&lt;P&gt; but the values are too large for the type P field intended to store them               &lt;/P&gt;&lt;P&gt; .                                                                                &lt;/P&gt;&lt;P&gt;The name of the field is "BDMNG".&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 27 Jul 2007 05:57:14 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/packed-type/m-p/2628190#M604072</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-07-27T05:57:14Z</dc:date>
    </item>
    <item>
      <title>Re: packed type</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/packed-type/m-p/2628191#M604073</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;as per my previous thread i have told due to collect the addition of bdmng is overflowing the capacity of type p variable..&lt;/P&gt;&lt;P&gt;so declare a inttable like that..&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;data : begin of itab,&lt;/P&gt;&lt;P&gt;aufnr like afpo-aufnr,&lt;/P&gt;&lt;P&gt;sum(40).&lt;/P&gt;&lt;P&gt;end of itab.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;now suppose your data is present in iafpo with aufnr posnr and bdmng.&lt;/P&gt;&lt;P&gt;sort iafpo by aufnr posnr.&lt;/P&gt;&lt;P&gt;loop at iafpo.&lt;/P&gt;&lt;P&gt;itab-sum = itab-sum + iafpo-bdmng.&lt;/P&gt;&lt;P&gt;itab-aufnr = iafpo-aufnr.&lt;/P&gt;&lt;P&gt;at end of aufnr.&lt;/P&gt;&lt;P&gt;append itab.&lt;/P&gt;&lt;P&gt;endat.&lt;/P&gt;&lt;P&gt;endloop.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;i think because of collect statement the error is coming...&lt;/P&gt;&lt;P&gt;just try like the above code (make adjustment as per need that is only an idea)...&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;regards&lt;/P&gt;&lt;P&gt;shiba dutta&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 27 Jul 2007 06:05:41 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/packed-type/m-p/2628191#M604073</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-07-27T06:05:41Z</dc:date>
    </item>
    <item>
      <title>Re: packed type</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/packed-type/m-p/2628192#M604074</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;ok yar&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt; thank you very much, let me check and revert back you soon.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;Rajaram&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 27 Jul 2007 07:09:33 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/packed-type/m-p/2628192#M604074</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-07-27T07:09:33Z</dc:date>
    </item>
  </channel>
</rss>

