<?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 currency conversion in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/currency-conversion/m-p/2368808#M524661</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;my problem is iam validating us currency and korea currency one is having no decimals and another one is having decimals i have to validate and update in database table iam using wrbtr field this one is packed ,&lt;/P&gt;&lt;P&gt;iam updating us currency exactly when iam updating korea currency problem is coming if iam declaring currency field as numeric unicode compatability with this while updating in database table.&lt;/P&gt;&lt;P&gt;any solution let me know &lt;/P&gt;&lt;P&gt;Thanks &lt;/P&gt;&lt;P&gt;Ramana Reddy&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 07 Jun 2007 09:14:04 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2007-06-07T09:14:04Z</dc:date>
    <item>
      <title>currency conversion</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/currency-conversion/m-p/2368808#M524661</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;my problem is iam validating us currency and korea currency one is having no decimals and another one is having decimals i have to validate and update in database table iam using wrbtr field this one is packed ,&lt;/P&gt;&lt;P&gt;iam updating us currency exactly when iam updating korea currency problem is coming if iam declaring currency field as numeric unicode compatability with this while updating in database table.&lt;/P&gt;&lt;P&gt;any solution let me know &lt;/P&gt;&lt;P&gt;Thanks &lt;/P&gt;&lt;P&gt;Ramana Reddy&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 07 Jun 2007 09:14:04 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/currency-conversion/m-p/2368808#M524661</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-06-07T09:14:04Z</dc:date>
    </item>
    <item>
      <title>Re: currency conversion</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/currency-conversion/m-p/2368809#M524662</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;HI,&lt;/P&gt;&lt;P&gt;Sample Program&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;DATA: gd_fcurr TYPE tcurr-fcurr,
      gd_tcurr TYPE tcurr-tcurr,
      gd_date  TYPE sy-datum,
      gd_value TYPE i.

gd_fcurr = 'EUR'.
gd_tcurr = 'GBP'.
gd_date  = sy-datum.
gd_value = 10.

PERFORM currency_conversion USING gd_fcurr
                                  gd_tcurr
                                  gd_date
                         CHANGING gd_value.



* Convert value to Currency value 
*&amp;amp;---------------------------------------------------------------------*
*&amp;amp;      Form  currency_conversion
*&amp;amp;---------------------------------------------------------------------*
*       text
*----------------------------------------------------------------------*
*      --&amp;gt;P_GD_FCURR  text
*      --&amp;gt;P_GD_TCURR  text
*      --&amp;gt;P_GD_DATE   text
*      &amp;lt;--P_GD_VALUE  text
*----------------------------------------------------------------------*
FORM currency_conversion  USING    p_fcurr
                                   p_tcurr
                                   p_date
                          CHANGING p_value.

  DATA: t_er        TYPE tcurr-ukurs,
        t_ff        TYPE tcurr-ffact,
        t_lf        TYPE tcurr-tfact,
        t_vfd       TYPE datum,
        ld_erate(12)   TYPE c.

  CALL FUNCTION 'READ_EXCHANGE_RATE'
    EXPORTING
*       CLIENT                  = SY-MANDT
      date                    = p_date
      foreign_currency        = p_fcurr
      local_currency          = p_tcurr
      TYPE_OF_RATE            = 'M'
*       EXACT_DATE              = ' '
   IMPORTING
      exchange_rate           = t_er
      foreign_factor          = t_ff
      local_factor            = t_lf
      valid_from_date         = t_vfd
*       DERIVED_RATE_TYPE       =
*       FIXED_RATE              =
*       OLDEST_RATE_FROM        =
   EXCEPTIONS
     no_rate_found           = 1
     no_factors_found        = 2
     no_spread_found         = 3
     derived_2_times         = 4
     overflow                = 5
     zero_rate               = 6
     OTHERS                  = 7
            .
  IF sy-subrc EQ 0.
    ld_erate = t_er / ( t_ff / t_lf ).
    p_value = p_value * ld_erate.
  ENDIF.
ENDFORM.                    " currency_conversion
&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt; Sudheer&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 07 Jun 2007 09:17:24 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/currency-conversion/m-p/2368809#M524662</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-06-07T09:17:24Z</dc:date>
    </item>
    <item>
      <title>Re: currency conversion</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/currency-conversion/m-p/2368810#M524663</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;hi sudheer my problem is not to convert amount value. if it is korea amount iam updating korea amount with korean currency but it is not having decimals where is us currency is having decimals and field is packed so with this  how to update both type of currencys in database table after uploadind data and validate the data.&lt;/P&gt;&lt;P&gt;Thanks &lt;/P&gt;&lt;P&gt;ramana reddy&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 07 Jun 2007 09:31:47 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/currency-conversion/m-p/2368810#M524663</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-06-07T09:31:47Z</dc:date>
    </item>
    <item>
      <title>Re: currency conversion</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/currency-conversion/m-p/2368811#M524664</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi sv ramana reddy,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SAP connects every currency value field (type CURR) in a DDIC structure with a currency key field of type CUKY. The determination and correct handling of decimals is determined by currency. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I think it works with USD as this currency is defined with 2 decimals which is default for currency fields.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Check existing database values stored with WON and other currencies in debugger and do necessary adjustments  (multiply/divide by 10 or 100) to your input upload values.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You will find the number of decimals configured for each currency in one of the TCUR* tables.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Clemens&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 07 Jun 2007 11:16:45 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/currency-conversion/m-p/2368811#M524664</guid>
      <dc:creator>Clemenss</dc:creator>
      <dc:date>2007-06-07T11:16:45Z</dc:date>
    </item>
  </channel>
</rss>

