Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support In Memory Rollup: Multicurrency calculates on corporate currency and not record currency. Issues arises with rounding values after applying exchange rate. #284

Open
patvachon77 opened this issue Jan 15, 2016 · 14 comments

Comments

@patvachon77
Copy link

Described in this video.
https://www.youtube.com/watch?v=z5ylMzp9tBc

@afawcett
Copy link
Collaborator

Yeah so i've been round the loop on this before with Salesforce support, it has to do with how SOQL Aggregate functions work over Currency fields. If the tool where to read the records itself and do the additions in memory it would arrive at the correct value, however this is obviously less efficient data volumes wise.

Here is some other GitHub issues, #217, #57

@afawcett
Copy link
Collaborator

This is post also gives an explanation of what SOQL Aggregate functions do with currencies and is what the tool is doing to convert to the parent current.

@afawcett
Copy link
Collaborator

I guess i could add an option in the rollup to have it not use SOQL Aggregate queries, retrieve all child records and add up in Apex code, but honestly i'm not sure this is really going to help much when the volumes go up and it starts causing governor and/or performance issues.

@AllisonJames
Copy link

TBH, I'm of help in how Apex does or doesn't work. What I do know is that in my situation I will only ever be dealing no more than a few records to rollup at a time, then I'm not sure there's any issue with governor and/or performance.

Can you add this other option and warn user when this option is chosen?

@afawcett afawcett changed the title Multicurrency calculates on corporate currency and not record currency. Issues arises with rounding values after applying exchange rate. Support In Memory Rollup: Multicurrency calculates on corporate currency and not record currency. Issues arises with rounding values after applying exchange rate. Feb 20, 2016
@afawcett
Copy link
Collaborator

Yep, that works, marked as enhancement!

@RobLofaro
Copy link

This seems to still be an issue in our org - and we are using the rolled up fields to produce customer facing quotes. Anyone in the UK will have incorrect values since they are GBP and corporate is in USD. Is there a workaround or fix?

@afawcett
Copy link
Collaborator

afawcett commented Feb 3, 2018

Yes, basically i need to merge this PR, #591 do some testing and release it. I'll bump the priority of this item for my next round of work on this.

@afawcett
Copy link
Collaborator

See #82

@afawcett
Copy link
Collaborator

Added some comments to PR before merging, #591

@harrisoe69
Copy link

@afawcett Where is the final resolution for this?

@Fr33zm4n
Copy link

Still having this issue. Any idea at a deadline to fix this?

@nickanderson86
Copy link

I am also having this issue. Would love an update. Thanks!

@afawcett
Copy link
Collaborator

afawcett commented Dec 28, 2019

So... i read on another issue someone say they created a Formula Currency field to shadow the physical currency field. They then used the formula field as the source of the aggregate and that resolved their issue. Thought I would share here. 👍 #859

@afawcett
Copy link
Collaborator

afawcett commented Apr 6, 2020

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

8 participants