Skip to Content
author's profile photo Former Member
Former Member

Currency Conversion - Logic in Variable

Hi All,


Im working with Currency Conversion in RSCUR transaction, we were using 0CALDAY as time reference but i need to modify this logic, for example:

-The user execute a report and fill a Time Reference variable (for example 01.01.2012)


-Then i have to compare :

IF ( 0CALDAY date from the current record is LE Time Reference variable )

Use 0CALDAY date to currency conversion

ELSE

Use TIME REFERENCE date to currency conversion

ENDIF

Any way to apply this logic in Currency Conversion?

Regards !!

Add a comment
10|10000 characters needed characters exceeded

Related questions

2 Answers

  • Best Answer
    Posted on Aug 19, 2012 at 02:46 AM

    Hi Marcus,

    Create a variable in Bex on 0CALDAY and write exit in CMOD as per your requirement. Now use this created variable in RSCUR under 'Time Reference from Variable'

    Regards
    Chandu

    Add a comment
    10|10000 characters needed characters exceeded

    • Former Member Chandra Sekhar

      Thanks again for your quick response but may be i did not explain very weel, my doubt is :

      *From CMOD in Customer Exit Variable, how can i access the 0CALDAY value from every record? because i have to compare the Time Reference Value (bex variable ready for imput) to the 0CALDAY value from every record in order to know which date is the correct date to use in Currency Conversion.

      Example:

      Time Reference Value (Bex variable Ready For Iimput) : 03/10/2012

      Record 0CALDAY CORRECT VALUE TO USE IN CURR.CONVERSION

      1 03/09/2012 03/09/2012 because 0CADALY is less than 03/10/2012

      2 03/11/2012 03/11/2012 because 0CADALY is greather than 03/10/2012

      3 03/15/2012 03/11/2012 because 0CADALY is greather than 03/10/2012

      Regards !!

  • Posted on Aug 21, 2012 at 03:45 AM

    Hi,

    I don't see how it can be done using exits, because exits cannot access the query output data. You can try it with Virtual Chars/Key Figs, but that may not be very desirable considering performance.

    A third option that might work is below.

    First create two currency conversion types. Let's call them CT1 and CT2. When defining CT1 in RSCUR, in the Time Ref tab make it based on 0CALDAY. For CT2, make it based on the "Time Reference variable".

    Then in your output, create CKF1 that uses CT1 and another CKF2 that uses CT2. Hide both of them. Create another CKF, which chooses from CKF1 or CKF2 based on the comparison of the dates. It would be something like (Time Ref Var > 0CALDAY )*( CKF2 ) + (Time Ref Var <= 0CALDAY )*( CKF1 )

    Regards,

    Suhas

    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.