To produce the behaviour you want you have to replace `commodity` by `commodity(scrub(display_amount))` in the csv format string⁽¹⁾. Search `src/report.h` for `csv_format_` for the default. You can pass a custom format string via the `--csv-format` option.
(1) I'm not sure if the call to `scrub` is necessary. On Thu, Jan 2, 2014 at 1:04 PM, Steve Purcell <[email protected]> wrote: > On 2 Jan 2014, at 11:16, Steve Purcell <[email protected]> wrote: > > > I can use —exchange to convert a register report into a given currency, > but if I want to export that data as CSV using the csv command, then the > —exchange option apparently has no effect. > > > > Am I missing something obvious? > > > Aha! — it turns out that the amount *is* converted to the target currency, > but the “currency” column of the CSV report always shows the *original* > currency. That’s probably a minor ledger bug. > > -Steve > > -- > > --- > You received this message because you are subscribed to the Google Groups > "Ledger" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to [email protected]. > For more options, visit https://groups.google.com/groups/opt_out. > -- --- You received this message because you are subscribed to the Google Groups "Ledger" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. For more options, visit https://groups.google.com/groups/opt_out.
