Re: [GNC] Scripted price editing and adding

2020-01-19 Thread Raymond Smith
Thanks to all for the inputs and suggestions. It sounds like I could make this work with a number of different paths, but I'll follow the "read, but don't write" suggestion and defer more of the analysis to the post-reading side and rely less on things like the built-in net worth time plot in

Re: [GNC] Scripted price editing and adding

2020-01-17 Thread D via gnucash-user
A few versions back, I pieced together a Perl script that rebuilt the price history for a Gnucash SQL file, replacing the existing history table with monthly prices for the duration that a given commodity was held. It worked fine for me, and cleaned up years of erratic pricing info, although it

Re: [GNC] Scripted price editing and adding

2020-01-17 Thread Adrien Monteleone
If I recall, the general advice is you can read, but don’t write. GnuCash is not yet a true database app. (that is a long term goal) Until then, writing could be potentially very destructive. There are some projects out there designed specifically to query an sqlite backend of GnuCash for

Re: [GNC] Scripted price editing and adding

2020-01-17 Thread Peter West
I’m curious about using sql scripts for read and update operations on Gnucash data when that data is maintained in such a database. For XML, similar things could be accomplished using XSLT or XQuery. Has anything along these lines been done? -- Peter West p...@pbw.id.au Moved with pity, he

Re: [GNC] Scripted price editing and adding

2020-01-17 Thread Jon Schewe
On 1/14/20 10:28 PM, Raymond Smith wrote: Hi, Gnucash list. I'm interested in using a script to add and edit prices in my Gnucash file. For example, I'd like to (a) loop over a file containing historical price data and add prices for dates where the price is missing because I didn't do a quote

[GNC] Scripted price editing and adding

2020-01-14 Thread Raymond Smith
Hi, Gnucash list. I'm interested in using a script to add and edit prices in my Gnucash file. For example, I'd like to (a) loop over a file containing historical price data and add prices for dates where the price is missing because I didn't do a quote retrieval in Gnucash that day (b) loop over