Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

Currency Conversion

Former Member
0 Likes
2,692

Hi,

I m converting Currency from USD to SAR by using FM 'CONVERT_CURRENCY_BY_RATE'.

Even though i m getting wrong value.

I hav gone through many threads to get correct solution..even though my problem not solved yet...

kindly let me knw which FM may help me out.

Regards,

Amar

28 REPLIES 28
Read only

Former Member
0 Likes
2,605

Hi,

Check this Function group "SCUR" for converting Currency Amounts.

Read only

0 Likes
2,605

FM SCUR does not EXIST

Read only

0 Likes
2,605

Thanks guys, my problem got solved with the FM CONVERT_FOREIGN_TO_FOREIGN_CUR

Read only

0 Likes
2,605

hi vekat ,

FM SCUR does not EXIST

How did this help you ?

Read only

0 Likes
2,605

A classic example of a help going in vain

Read only

0 Likes
2,605

Vikranth,

What you said is true.

Read only

0 Likes
2,605

Please mark your thread as answered if your issue got resolved

Read only

0 Likes
2,605

what is happening here ?

Venkat ,

I dont think so my anser solved your problem.

Mark the points appropriately.

You are a member since 2007 😕

Edited by: Keshu Thekkillam on Oct 13, 2009 10:42 AM

Read only

Former Member
0 Likes
2,605

Try this FM "CONVERT_TO_LOCAL_CURRENCY"

Read only

Former Member
0 Likes
2,605

Hi,

Check the FM CONVERT_TO_FOREIGN_CURRENCY

Vikranth

Read only

0 Likes
2,605

Hi Vikranth and Sudhaker,

I tried the above two FM's, but if i pass any date, its giving nothing...no output...

Any other option?

Read only

former_member156446
Active Contributor
0 Likes
2,605
CALL FUNCTION 'CONVERT_TO_FOREIGN_CURRENCY'
        EXPORTING
          date             = <fs_komv>-kdatu
          foreign_currency = komk-waerk
          local_amount     = wa_komp_o-netwr "zwavwr
          local_currency   = <fs_komv>-waers
*          rate             = <fs_komv>-kkurs
*          type_of_rate     = 'M'
        IMPORTING
          foreign_amount   = <fs_komv>-kwert
        EXCEPTIONS
          no_rate_found    = 1
          overflow         = 2
          no_factors_found = 3
          no_spread_found  = 4
          derived_2_times  = 5
          OTHERS           = 6.
Read only

Former Member
0 Likes
2,605

HI,

Check this one CONVERT_AMOUNT_TO_CURRENCY

Read only

0 Likes
2,605

which date i hav to pass?

Read only

0 Likes
2,605

>

> which date i hav to pass?

u can use sy-datum

CALL FUNCTION 'CONVERT_TO_FOREIGN_CURRENCY' is used by SAP in pricing for sales Order and invoices etc..

Read only

0 Likes
2,605

Hi,

If u want today's rate conversion then pass sy-datum.

Read only

0 Likes
2,605

Hi,

I used the FM CONVERT_TO_LOCAL_CURRENCY

This is the input i have passed.

CLIENT 200

DATE 09.10.2009

FOREIGN_AMOUNT 18000

FOREIGN_CURRENCY USD

LOCAL_CURRENCY SAR

RATE 3.75

TYPE_OF_RATE M

READ_TCURR X

Its giving nothing....

even same case for the FM CONVERT_TO_FOREIGN_CURRENCY

Kidly let me knw the solution

Read only

0 Likes
2,605

Venkat,

Go to table TCURR and check if there is any data for DATE you entered between these currencies. If data does not exist there than you will not get any output from FM.

Read only

0 Likes
2,605

Hi,

Maintain exange rate,

Exchange rates maintain daily are stored in TCURR table in R/3

Read only

0 Likes
2,605

>

> even same case for the FM CONVERT_TO_FOREIGN_CURRENCY

>

> Kidly let me knw the solution

Please try this code:

DATA: lv_kwert TYPE kwert.
CALL FUNCTION 'CONVERT_TO_FOREIGN_CURRENCY'
  EXPORTING
    date             = sy-datum
    foreign_currency = 'SAR'  " try changing as per ur req.
    local_amount     = '1800'
    local_currency   = 'SAR'
  IMPORTING
    foreign_amount   = lv_kwert
  EXCEPTIONS
    no_rate_found    = 1
    overflow         = 2
    no_factors_found = 3
    no_spread_found  = 4
    derived_2_times  = 5
    OTHERS           = 6.
WRITE: lv_kwert.

Read only

0 Likes
2,605

Sudhaker,

In TCURR table some of the entries found for USD to SAR.

I passes those dates to the FM.

But i m getting below error.

Exception NO_RATE_FOUND

Message ID: SG Message number: 105

Message: Enter rate 1300 / SAR rate type M for 01.01.2005 in the system settings

I m directly running these frm SE37 only

Edited by: venkat on Oct 9, 2009 7:14 AM

Read only

0 Likes
2,605

Dont try in se37.. some FM's does not work... and work perfect in se38 programs..

Read only

0 Likes
2,605

Hi,

I remember facing this problem when I used the FM.

Didnt quite know what the reason was. So concluded that the SAP system currency conversion rates were not in synch with the third party system.

The FM worked only between USD and INR for me.

Probably, the FM right now works only between few currencies.

Not quite sure, but I guess others will pitch in here and help you out.

Read only

0 Likes
2,605

>

> Probably, the FM right now works only between few currencies.

>

> Not quite sure, but I guess others will pitch in here and help you out.

the currencies need to installed or configured in your system... if they do not exist none of the FM's will work

Read only

0 Likes
2,605

Hi,

If your not sure as to how to maintain the exchange rate, use the FM CONVERT_FOREIGN_TO_FOREIGN_CUR.

check it in SE37 itself

client: your client number

date: 09.10.2009

type of rate: M

from amount: 1800 (Any value)

from_currency: USD

to currency: SAR

local_currency: USD

conversion_mode : X

Check if this works

Also goto the table TCURR and enter from currency as USD and to currency as SAR. Check if any record is maintained

Vikranth

Read only

Former Member
0 Likes
2,605

This message was moderated.

Read only

kesavadas_thekkillath
Active Contributor
0 Likes
2,605

link:[http://wiki.sdn.sap.com/wiki/display/Snippets/FMCurrencyConversion]

Read only

Former Member
0 Likes
2,606

Hi,

Please test the FMs that you are using for currency conversion in SE37. Check if the FM gives the correct value.