Import stock price history from QIF?

Derek Atkins derek at ihtfp.com
Sat Sep 10 07:39:36 EDT 2011


Hi,

On Fri, September 9, 2011 10:46 pm, prl wrote:
> On 10/09/11 11:51, prl wrote:
>> ...
>> I'm planning on writing a Perl script to translate QIF closing prices
>> into GnuCash "last" prices
>> ...
[snip]
> I guess the comment at the beginning really means what it says:
> # This schema is non-normative; files emitted by gnucash <= 2.0 (and
> perhaps
> # later) that do not validate against it likely represent a problem with
> the
> # schema, not the file.

This comment is 100% correct.  GnuCash does not use a schema; it has
hand-written parsers and generators, and those change over time.  We try
to make sure that the XML is "well-formed" but it does not "validate".  If
you need to learn about the XML then you need to read the source code.

Also note that editing the XML from outside GnuCash is "not supported".

To do what you want you should really use the Scheme or Python bindings to
write an application to load your historical quotes into GnuCash.  Or you
could write something in C, of course!  This way you can use the GnuCash
API.

> Peter

> Please remember to CC this list on all your replies.
> You can do this by using Reply-To-List or Reply-All.

-derek

-- 
       Derek Atkins                 617-623-3745
       derek at ihtfp.com             www.ihtfp.com
       Computer and Internet Security Consultant



More information about the gnucash-user mailing list