Get stock quotes for specified date

Stefan Söffing soeffing at
Sat Dec 10 06:05:36 EST 2016

John, David,

that's indeed the script I had in mind. Obviously it was too late when I
wrote this so not only did I forget to include the link, but also did
not notice the subtle difference between Finance::QuoteHist and
Finance::Quote. I understand that QuoteHist is more limited in most
respects compared to F::Q.

As David states, however, the QuoteHist module seems still to be working
as-is, I tried for some of my stocks and was immediately able to
retrieve historic prices. John, where did you take the information that
it is unmaintained since 2013? In CPAN bug tracking I see the last patch
was being included 5 month ago (this year).


Am 10.12.2016 um 07:42 schrieb David T.:
> John,
> It may be that Stefan refers
> to As you note, it
> uses Finance::QuoteHist instead of F::Q. Finance::QuoteHist does still
> work with the sources you mention, although I cannot comment about the
> wiki script, since I do not have Python bindings enabled on my Mac.
> Cheers,
> David
>> On Dec 10, 2016, at 3:32 AM, John Ralls <jralls at
>> <mailto:jralls at>> wrote:
>>> On Dec 9, 2016, at 1:30 PM, Stefan Söffing <soeffing at
>>> <mailto:soeffing at>> wrote:
>>> All,
>>> the price editor currently is able to retrieve today's stock quote for
>>> the price db. Sometimes it can be useful to retrieve stock quotes for a
>>> specified historic date, e.g. to update the prices for the last day of
>>> the financial year as a basis for reporting using the "Nearest in time"
>>> price source.
>>> I'd like to suggn time"
>>> price source.
>>> I'd like to suggest to add this feature by introducing a new pop-up
>>> window with a date selector to the "Get Quotes" button (similar to the
>>> "remove old" pop-up). I understand that there is an example script
>>> delivered with GnuCash to serve a similar purpose, i.e. retrieving a
>>> series of quotes over a given time-period, so obviously the
>>> Finance::Quote part is able to handle historic data as well.
>>> If this is considered a worthwhile enhancement I'd be happy to assist in
>>> implementation. Unfortunately, however, I figured out that the relevant
>>> part is scripted in Scheme. While I do have some (long-forgotten)
>>> experience with C, that scm language thing looks quite cryptic to me.
>>> Nevertheless if someone was willing to adapt the scheme part I'd like to
>>> try my best in supporting the C development part as much as possible...
>>> Thanks for listening.
>> Stefan,
>> Sorry, you're misinformed. There is no such example script and
>> Finance::Quote [1] is able to retrieve only the latest price. There
>> is in CPAN a package called Finance::QuoteHist [2], but it hasn't
>> been maintained since 2013 and so is unlikely to work as-is. Note as
>> well that it has only two modules, Yahoo and Google, far fewer that
>> Finance::Quote gnc-fq-helper, a perl applet, would need to be
>> modified to optionally call QuoteHist instead of Quote when a date is
>> provided and to format the results for quotes.scm. The latter would
>> need only a change to pass the selected date to gnc-fq-helper. The UI
>> changes would be in C, to src/gnome/dialog-price-edit-db.c, and in
>> XML, to src/gnome/gtkbuilder/
>> Regards,
>> John Ralls
>> [1]
>> <>
>> [2]
>> <>
>> _______________________________________________
>> gnucash-devel mailing list
>> gnucash-devel at gnucash.or <mailto:gnucash-devel at gnucash.or>

More information about the gnucash-devel mailing list