<?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: Small query regarding sub-routine pgm for a script in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/small-query-regarding-sub-routine-pgm-for-a-script/m-p/1656303#M291308</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;1)&lt;/P&gt;&lt;P&gt;Instead of TRANSPORTING NO FIELDS..use INDEX 1...If you say transporting no fields..No fields will be moved to the header line.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;READ TABLE in_par &amp;lt;b&amp;gt;INDEX 1&amp;lt;/b&amp;gt;.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;2) The customer can be in multiple company codes..&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If you want the first company code..Use the following..&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;DATA: V_BUKRS LIKE KNB1-BUKRS&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SELECT SINGLE BUKRS FROM KNB1&lt;/P&gt;&lt;P&gt;       INTO V_BUKRS&lt;/P&gt;&lt;P&gt;       WHERE KUNNR = 'CUSTOMER NUMBER'.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Naren&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 08 Nov 2006 15:57:11 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2006-11-08T15:57:11Z</dc:date>
    <item>
      <title>Small query regarding sub-routine pgm for a script</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/small-query-regarding-sub-routine-pgm-for-a-script/m-p/1656302#M291307</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi all...&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;iam new to this group. i am writing a sub-rotuine for a form. But in that one select query was bouncing. and one more thing is there any way to get BUKRS based on KUNNR.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;And please correct my code.&lt;/P&gt;&lt;P&gt;PROGRAM  ZDUNNING_TEST.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;FORM DUNNING_TEST TABLES in_par STRUCTURE itcsy&lt;/P&gt;&lt;P&gt;                        out_par STRUCTURE itcsy.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;DATA: w_po_line_ds LIKE out_par,&lt;/P&gt;&lt;P&gt;      w_kunnr      LIKE mhnd-kunnr,&lt;/P&gt;&lt;P&gt;      w_wrbtr  type bsid-wrbtr,&lt;/P&gt;&lt;P&gt;      l_index like sy-tabix,&lt;/P&gt;&lt;P&gt;      sum like bsid-wrbtr,&lt;/P&gt;&lt;P&gt;      w_wrbtr1(15) type c,&lt;/P&gt;&lt;P&gt;      w_wrbtr2(15) type c.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;CONSTANTS:    c_waers_eur(5) type C value 'EUR',&lt;/P&gt;&lt;P&gt;              c_waers_usr(5) type C value 'USR',&lt;/P&gt;&lt;P&gt;              c_bukrs(4) type c value '5E50'.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;data: begin of itab occurs 0,&lt;/P&gt;&lt;P&gt;      waers like bsid-waers,&lt;/P&gt;&lt;P&gt;      wrbtr like bsid-wrbtr,&lt;/P&gt;&lt;P&gt;      end of itab.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;data: begin of wa_itab,&lt;/P&gt;&lt;P&gt;      waers like bsid-waers,&lt;/P&gt;&lt;P&gt;      wrbtr like bsid-wrbtr,&lt;/P&gt;&lt;P&gt;end of wa_itab.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;CONSTANTS:  c_line(15) TYPE c VALUE 'W_DUN_AMT'    .&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;READ TABLE in_par TRANSPORTING NO FIELDS.&lt;/P&gt;&lt;P&gt;  w_kunnr = in_par-value.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;*select single bukrs from bsid into w_bukrs where kunnr  = w_kunnr.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;select  waers&lt;/P&gt;&lt;P&gt;        wrbtr&lt;/P&gt;&lt;P&gt;        from bsid&lt;/P&gt;&lt;P&gt;        into table itab&lt;/P&gt;&lt;P&gt;        where kunnr = w_kunnr&lt;/P&gt;&lt;P&gt;        and   bukrs = c_bukrs.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;clear sum.&lt;/P&gt;&lt;P&gt;sort itab by waers.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;loop at itab into wa_itab.&lt;/P&gt;&lt;P&gt;l_index = sy-tabix.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;sum = sum + wa_itab-wrbtr.&lt;/P&gt;&lt;P&gt;at end of waers.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;read table itab into wa_itab index l_index.&lt;/P&gt;&lt;P&gt;wa_itab-wrbtr = sum.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;move wa_itab-wrbtr to w_wrbtr2.&lt;/P&gt;&lt;P&gt;*write:/ wa_itab-cur,wa_itab-amt.&lt;/P&gt;&lt;P&gt;clear sum.&lt;/P&gt;&lt;P&gt;endat.&lt;/P&gt;&lt;P&gt;endloop.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 08 Nov 2006 15:53:03 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/small-query-regarding-sub-routine-pgm-for-a-script/m-p/1656302#M291307</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-11-08T15:53:03Z</dc:date>
    </item>
    <item>
      <title>Re: Small query regarding sub-routine pgm for a script</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/small-query-regarding-sub-routine-pgm-for-a-script/m-p/1656303#M291308</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;1)&lt;/P&gt;&lt;P&gt;Instead of TRANSPORTING NO FIELDS..use INDEX 1...If you say transporting no fields..No fields will be moved to the header line.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;READ TABLE in_par &amp;lt;b&amp;gt;INDEX 1&amp;lt;/b&amp;gt;.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;2) The customer can be in multiple company codes..&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If you want the first company code..Use the following..&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;DATA: V_BUKRS LIKE KNB1-BUKRS&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SELECT SINGLE BUKRS FROM KNB1&lt;/P&gt;&lt;P&gt;       INTO V_BUKRS&lt;/P&gt;&lt;P&gt;       WHERE KUNNR = 'CUSTOMER NUMBER'.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Naren&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 08 Nov 2006 15:57:11 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/small-query-regarding-sub-routine-pgm-for-a-script/m-p/1656303#M291308</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-11-08T15:57:11Z</dc:date>
    </item>
    <item>
      <title>Re: Small query regarding sub-routine pgm for a script</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/small-query-regarding-sub-routine-pgm-for-a-script/m-p/1656304#M291309</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;You can get the company code of the customer from table KNB1.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Rich Heilman&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 08 Nov 2006 15:57:25 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/small-query-regarding-sub-routine-pgm-for-a-script/m-p/1656304#M291309</guid>
      <dc:creator>RichHeilman</dc:creator>
      <dc:date>2006-11-08T15:57:25Z</dc:date>
    </item>
    <item>
      <title>Re: Small query regarding sub-routine pgm for a script</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/small-query-regarding-sub-routine-pgm-for-a-script/m-p/1656305#M291310</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Narendran...&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks for the reply. But it is bouncing on the select query only.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;please check this and corect that.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;thanks &amp;amp; regards,&lt;/P&gt;&lt;P&gt;Arjun Jain&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 08 Nov 2006 16:00:26 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/small-query-regarding-sub-routine-pgm-for-a-script/m-p/1656305#M291310</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-11-08T16:00:26Z</dc:date>
    </item>
    <item>
      <title>Re: Small query regarding sub-routine pgm for a script</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/small-query-regarding-sub-routine-pgm-for-a-script/m-p/1656306#M291311</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;Try calling the FM CONVERSION_EXIT_ALPHA_INPUT..&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;CALL FUNCTION 'CONVERSION_EXIT_ALPHA_INPUT'&lt;/P&gt;&lt;P&gt;EXPORTING&lt;/P&gt;&lt;P&gt;INPUT = W_KUNNR&lt;/P&gt;&lt;P&gt;IMPORTING&lt;/P&gt;&lt;P&gt;OUTPUT = W_KUNNR.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Naren&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 08 Nov 2006 16:03:23 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/small-query-regarding-sub-routine-pgm-for-a-script/m-p/1656306#M291311</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-11-08T16:03:23Z</dc:date>
    </item>
    <item>
      <title>Re: Small query regarding sub-routine pgm for a script</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/small-query-regarding-sub-routine-pgm-for-a-script/m-p/1656307#M291312</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;i got of my own...thanks for the help guys...&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 25 Jul 2008 15:31:01 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/small-query-regarding-sub-routine-pgm-for-a-script/m-p/1656307#M291312</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-07-25T15:31:01Z</dc:date>
    </item>
  </channel>
</rss>

