After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 314554 - Advanced-Portfolio different currencies
Advanced-Portfolio different currencies
Status: VERIFIED FIXED
Product: GnuCash
Classification: Other
Component: Reports
1.8.x
Other All
: Normal major
: ---
Assigned To: Chris Lyttle
Chris Lyttle
Depends on:
Blocks:
 
 
Reported: 2005-08-26 10:08 UTC by Florian
Modified: 2018-06-29 20:53 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Handle multiple currencies better in several reports (26.28 KB, patch)
2006-02-08 07:11 UTC, Mike Alexander
committed Details | Review

Description Florian 2005-08-26 10:08:02 UTC
Please describe the problem:
There is a problem if the report lists stock of different currencies. 
E.g. if there is a fund in $ and the general currency is Euro the report reports 
everything in Euro, which is fine. 
The value column contains the right value (i.e. the value of the $ fund in Euro
).
However, the money in (and probably mone out, too) show the amount in Euro, 
which actually was in $ (obviously, since the stock-account is a $ account).

Steps to reproduce:



Actual results:


Expected results:


Does this happen every time?


Other information:
I assume that there just has to be added a currency exchange computation. Which 
probably (by default, at least) should be use the currency value of the time 
nearest to the date of the transaction.

I also looked at the advanced-portfolio.scm file, unfortunately I am not into 
that language at all, so I wasn't able to understand to much of what is going on 
there :-). But I assume that it can be easily fixed, I hope...
Comment 1 Christian Stimming 2006-01-09 09:47:55 UTC
Other bugs concerning the Advanced Portfolio report are bug#105466, bug#115267 (maybe both are duplicates of this one), bug#311549, bug#312049 , bug#326150
Comment 2 Mike Alexander 2006-02-08 07:11:01 UTC
Created attachment 58901 [details] [review]
Handle multiple currencies better in several reports

This patch helps the problem described in this bug, as well as several other problems with reports containing multiple currencies.  It is a bit of a kitchen sink patch (for which I apologize) but the changes are mostly related to currencies and prices in reports.  The patch adds a currency option to the two portfolio reports and the transaction report and converts things to that currency.  If you specify use of the nearest price, it picks the price nearest to the transaction, not nearest to the date of the report.  It also uses noon on the day of the transaction to find the nearest price instead of midnight the night before (making it more likely it will get a price on the same day instead of the previous day).
Comment 3 Derek Atkins 2006-02-12 21:47:06 UTC
Okay, I've applied this to SVN, r13244.  Thanks!

Note that it didn't quite apply cleanly because of some other patches I've applied, so you might want to:
  a) check my work, and
  b) make sure your checkout doesn't have merge conflicts.

I also found some paren imbalances in advanced-portfolio..  I /think/ I fixed it properly, but I don't have a test data file with stocks so I can't actually test the change.

Thanks!
Comment 4 Derek Atkins 2006-02-13 05:00:24 UTC
Actually, the advanced-portfolio patch is broken, so I'm reverting it in SVN.  Any chance you could re-form the patch against current SVN?  Right now it just doesn't work at all.. it has mismatched parens.. and it seems to have lost some functionality (e.g. the include-empty flag doesn't do anything anymore).
Comment 5 Andrew Sackville-West 2006-02-14 22:45:22 UTC
I have ground my way through the parens and fixed this patch and provided unified diffs along with my display options patch over at http://bugzilla.gnome.org/show_bug.cgi?id=330577
and this should fix this situation. Note that I don't work in multiple currencies, so whether Mike's patch, as fixed by me actually does what it's supposed to, I don't know. However, it does now run. ;)

patch attached to other bug... sorry to make people jump links, but hey...

A
Comment 6 Andrew Sackville-West 2006-02-14 22:46:09 UTC
I have ground my way through the parens and fixed this patch and provided unified diffs along with my display options patch over at http://bugzilla.gnome.org/show_bug.cgi?id=330577
and this should fix this situation. Note that I don't work in multiple currencies, so whether Mike's patch, as fixed by me actually does what it's supposed to, I don't know. However, it does now run. ;)

patch attached to other bug... sorry to make people jump links, but hey...

A
Comment 7 Derek Atkins 2006-02-15 00:02:27 UTC
Commited Andrew's patch to SVN r13264.
Comment 8 Andrew Sackville-West 2006-02-18 20:40:15 UTC
OKay, I'm revisiting this thing as it seems to me, upon reading, to not be a bug at all. please help me figure this out. more below

> Please describe the problem:
> There is a problem if the report lists stock of different currencies. 
> E.g. if there is a fund in $ and the general currency is Euro the report reports 
> everything in Euro, which is fine. 

okay, you've got mixed currencies in account and have set the display to show everything in Euro's, right?

> The value column contains the right value (i.e. the value of the $ fund in Euro
> ).

okay, so its converted the value of the fund into Euros and shown it. good.

> However, the money in (and probably mone out, too) show the amount in Euro, 
> which actually was in $ (obviously, since the stock-account is a $ account).
> 

the report has been set to show Euro's, so why show a $ amount? If you have a moneyin column that has both euros and $ in it, then your totals are meaningless. How do you decide which currency to diplay your totals in? DO you want to see the individual line item in one currency but the totals in another? 

IOW, I don't think, based on your description, that this is a bug. so please enlighten me :).

A
Comment 9 Andrew Sackville-West 2006-03-12 19:06:13 UTC
thre are continued issues with this report. most I think are fixed in: http://bugzilla.gnome.org/show_bug.cgi?id=334338

I don;'t think there is any need to reopen, just putting this in the record.

A
Comment 10 John Ralls 2018-06-29 20:53:38 UTC
GnuCash bug tracking has moved to a new Bugzilla host. This bug has been copied to https://bugs.gnucash.org/show_bug.cgi?id=314554. Please update any external references or bookmarks.