Discussion:
importing transaction comments
Evgenii Sovetkin
2018-11-16 20:55:12 UTC
Permalink
I am looking for a way to import transactions *together with comments* from
a hledger file to a csv.

So, for instance,

2018/11/16 something
; :tag:
Expenses 100 EUR
; comment1
Assets -100 EUR
; comment2

will be imported as

"txnidx","date","code","description","account","amount","total","comment"
"1","2018/11/16","","something","Expenses","100 EUR","100 EUR",":tag:
comment1"
"1","2018/11/16","","something","Assets","-100 EUR","0","":tag: comment2"

Is it possible to do it with the command like this: `hledger register -o
output.csv` ?
--
You received this message because you are subscribed to the Google Groups "hledger" group.
To unsubscribe from this group and stop receiving emails from it, send an email to hledger+***@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Simon Michael
2018-11-16 21:51:51 UTC
Permalink
I see that the print command includes transaction and posting comments in its csv output, but the register command includes neither. This will require a code change in Register.hs. I welcome a pull request or issue for this. It's not completely obvious what it should do about "transaction comments", which are usually considered to be inherited by the postings.
I am looking for a way to import transactions *together with comments* from a hledger file to a csv.
So, for instance,
2018/11/16 something
Expenses 100 EUR
; comment1
Assets -100 EUR
; comment2
will be imported as
"txnidx","date","code","description","account","amount","total","comment"
"1","2018/11/16","","something","Expenses","100 EUR","100 EUR",":tag: comment1"
"1","2018/11/16","","something","Assets","-100 EUR","0","":tag: comment2"
Is it possible to do it with the command like this: `hledger register -o output.csv` ?
--
You received this message because you are subscribed to the Google Groups "hledger" group.
For more options, visit https://groups.google.com/d/optout <https://groups.google.com/d/optout>.
--
You received this message because you are subscribed to the Google Groups "hledger" group.
To unsubscribe from this group and stop receiving emails from it, send an email to hledger+***@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Evgenii Sovetkin
2018-11-16 22:40:36 UTC
Permalink
Post by Simon Michael
I see that the print command includes transaction and posting comments in its
csv output, but the register command includes neither. This will require a code
change in Register.hs. I welcome a pull request or issue for this. It's not
completely obvious what it should do about "transaction comments", which are
usually considered to be inherited by the postings.
thanks, I didn't know about print command csv conversions!

I'll consider submitting a pull request for the register.
--
You received this message because you are subscribed to the Google Groups "hledger" group.
To unsubscribe from this group and stop receiving emails from it, send an email to hledger+***@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Loading...