<?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: Problem with read dataset in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/problem-with-read-dataset/m-p/1482582#M225626</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Abdul,&lt;/P&gt;&lt;P&gt;Thanks for the response. &lt;/P&gt;&lt;P&gt;The sequence of the fields is perfect. If I decalre that field as csqty(14), I can see the correct value. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Sobhan,&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 22 Aug 2006 17:50:02 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2006-08-22T17:50:02Z</dc:date>
    <item>
      <title>Problem with read dataset</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/problem-with-read-dataset/m-p/1482578#M225622</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello All,&lt;/P&gt;&lt;P&gt;I am reading the dataset and tryingto put the value directly in packed decimal. It is not getting the correct value into packed decimal field. It is getting some hexa decimal value. Does anyone kkow how to handle this problem?  &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Here is my code snippet:  &lt;/P&gt;&lt;P&gt;data: begin of wa_file,&lt;/P&gt;&lt;P&gt;        plant(4),&lt;/P&gt;&lt;P&gt;        matnr(18),&lt;/P&gt;&lt;P&gt;        csqty(14) type p decimals 4,          "$010&lt;/P&gt;&lt;P&gt;        sign,&lt;/P&gt;&lt;P&gt;        date(8),&lt;/P&gt;&lt;P&gt;      end of wa_file,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;open dataset f_dsn for input in text mode.&lt;/P&gt;&lt;P&gt;  if sy-subrc &amp;lt;&amp;gt; 0.&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;  Error when opening file&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;    message e000(zfi).&lt;/P&gt;&lt;P&gt;  endif.&lt;/P&gt;&lt;P&gt;while 1 = 1.&lt;/P&gt;&lt;P&gt;    read dataset f_dsn into wa_file.&lt;/P&gt;&lt;P&gt;    if sy-subrc &amp;lt;&amp;gt; 0.&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;    End of  file&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;      exit.&lt;/P&gt;&lt;P&gt;    endif.&lt;/P&gt;&lt;P&gt;I am getting the value of 30303030303030303031343.5303 into wa_file-csqty.  &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Can you tell mw what is the right way to get this value. This data goes to MB1A thru BDC call transaction.  &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Sobhan.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 22 Aug 2006 17:30:38 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/problem-with-read-dataset/m-p/1482578#M225622</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-08-22T17:30:38Z</dc:date>
    </item>
    <item>
      <title>Re: Problem with read dataset</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/problem-with-read-dataset/m-p/1482579#M225623</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Sobhan,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Change the data type declaration of &lt;/P&gt;&lt;P&gt;csqty(14) type p decimals 4, &lt;/P&gt;&lt;P&gt;into &lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;csqty type p decimals 4 in wa_file.&amp;lt;/b&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;data: begin of wa_file,&lt;/P&gt;&lt;P&gt;plant(4),&lt;/P&gt;&lt;P&gt;matnr(18),&lt;/P&gt;&lt;P&gt;&amp;lt;b&amp;gt;csqty type p decimals 4, "$010&amp;lt;/b&amp;gt;&lt;/P&gt;&lt;P&gt;sign,&lt;/P&gt;&lt;P&gt;date(8),&lt;/P&gt;&lt;P&gt;end of wa_file,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Vinay&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 22 Aug 2006 17:35:48 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/problem-with-read-dataset/m-p/1482579#M225623</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-08-22T17:35:48Z</dc:date>
    </item>
    <item>
      <title>Re: Problem with read dataset</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/problem-with-read-dataset/m-p/1482580#M225624</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Vinay,&lt;/P&gt;&lt;P&gt;Thanks for the idea. I tried with that. I have got the value 30303030303.0303 into csqty field. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Sobhan.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 22 Aug 2006 17:44:06 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/problem-with-read-dataset/m-p/1482580#M225624</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-08-22T17:44:06Z</dc:date>
    </item>
    <item>
      <title>Re: Problem with read dataset</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/problem-with-read-dataset/m-p/1482581#M225625</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;hi&lt;/P&gt;&lt;P&gt;check whether the sequence of the fields in your file and your structure wa_file are same.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Cheers,&lt;/P&gt;&lt;P&gt;Abdul Hakim&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 22 Aug 2006 17:45:11 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/problem-with-read-dataset/m-p/1482581#M225625</guid>
      <dc:creator>abdul_hakim</dc:creator>
      <dc:date>2006-08-22T17:45:11Z</dc:date>
    </item>
    <item>
      <title>Re: Problem with read dataset</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/problem-with-read-dataset/m-p/1482582#M225626</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Abdul,&lt;/P&gt;&lt;P&gt;Thanks for the response. &lt;/P&gt;&lt;P&gt;The sequence of the fields is perfect. If I decalre that field as csqty(14), I can see the correct value. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Sobhan,&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 22 Aug 2006 17:50:02 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/problem-with-read-dataset/m-p/1482582#M225626</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-08-22T17:50:02Z</dc:date>
    </item>
    <item>
      <title>Re: Problem with read dataset</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/problem-with-read-dataset/m-p/1482583#M225627</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Sobhan,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Try to OPEN DATASET statement with BINARY MODE and check for results.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;open dataset f_dsn for input in &amp;lt;b&amp;gt;BINARY mode&amp;lt;/b&amp;gt;.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;(or)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If you get the value of cqty exactly by declaring it has character field of cqty(14) then assign this character value back to packed decimal.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Vinay&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 22 Aug 2006 18:30:57 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/problem-with-read-dataset/m-p/1482583#M225627</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-08-22T18:30:57Z</dc:date>
    </item>
    <item>
      <title>Re: Problem with read dataset</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/problem-with-read-dataset/m-p/1482584#M225628</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;hi&lt;/P&gt;&lt;P&gt;then go ahead with that.&lt;/P&gt;&lt;P&gt;once you read into cstqty(14) you can split the value easily..&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Cheers,&lt;/P&gt;&lt;P&gt;Abdul Hakim&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Close the thread if your question has been answered...&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 22 Aug 2006 18:42:07 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/problem-with-read-dataset/m-p/1482584#M225628</guid>
      <dc:creator>abdul_hakim</dc:creator>
      <dc:date>2006-08-22T18:42:07Z</dc:date>
    </item>
  </channel>
</rss>

