web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

No record found.

News and Announcements icon
Community site session details

Community site session details

Session Id :
Microsoft Dynamics CRM (Archived)

Scheduling Recalculation of Open Opportunities

(0) ShareShare
ReportReport
Posted on by 150

Hi Everyone,

We are looking at entering opportunities for currencies other than our "base" currency.  I can set all that up and can manually retrieve each open opportunity and recalculate to set the opportunity "base" value on the current exchange rate recorded in the currency table (as opposed to the exchange rate last time the opportunity was recalculated).

However, we would like to automate this recalculation process, every time the currency table has been updated.

Has anyone done this before?

Thanks,

Michael

*This post is locked for comments

I have the same question (0)
  • Michael Thorne Profile Picture
    150 on at

    Should have mentioned environment - CRM 2011 UR13

  • Verified answer
    purwar purwar Profile Picture
    2,836 on at

    The “Amount” field of the Collection entity is a money field, CRM will internally add the following fields.

    •Amount_base: Tracks the amount collected in organization’s base currency.

    •Transaction currency: Tracks the currency in which the amount was collected.

    •Exchange rate: Tracks the exchange rate that will be used to calculate the base currency value.

    Notes:

    * The transaction currency and the exchange rate are created once per entity. All money fields on a single record would use the same transaction currency and exchange rate.

    Updating the exchange rate doesn’t change anything in the transaction – the value of the Estimated Revenue field on our hypothetical opportunity above doesn’t change, only that of the Estimated Revenue_base field

    Without plugin/custom wf you can not archive this.

    1. ‘UpdateOpportunityExchangeRate’ class has the logic to fetch opportunities and related entities like opportunity forecasts and opportunity products.

    2. By default the fetch query in CRM has a limit on the total number of records that can be fetched in a query. In order to by pass this one has to use ‘fetchXml’ and pass in the cookie to keep track of records fetched. This solution uses the same approach to fetch all the opportunities keeping track of the records being fetched.

    3. An important aspect of the ‘money’ fields is that whenever a record is saved and one of the money fields is updated all the ‘money’ fields in the record are updated by CRM system. This is important to understand as this implies that all the ‘base_amounts’ are recalculated once a particular field is updated on a record.

    4. Workflow uses the principle described in Step-3 to maximum as in-order to update all ‘money’ base value fields we just fetch and update one ‘money’ field. Doing this reduces the information flow to a great extent. This results in significant impact on the optimization of the overall code because this allows updating all ‘money’ fields without having to fetch and update each one of them.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Stars!

Meet the Microsoft Dynamics 365 Contact Center Champions

We are thrilled to have these Champions in our Community!

Congratulations to the April Top 10 Community Leaders

These are the community rock stars!

Leaderboard > 🔒一 Microsoft Dynamics CRM (Archived)

#1
ScottDurow Profile Picture

ScottDurow 2

#2
GJones Profile Picture

GJones 1

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans