Re: CSV and number formats

2015-02-01 Thread Emile van Sebille
On 1/31/2015 10:45 PM, Frank Millman wrote: If the opening balance is positive, it appears as '+0021.45' If it is negative, it appears as '+0-21.45' My advise is to get cash in payment. :) Emile -- https://mail.python.org/mailman/listinfo/python-list

Re: CSV and number formats

2015-02-01 Thread Skip Montanaro
On Sun, Feb 1, 2015 at 12:45 AM, Frank Millman wrote: > Is this a recognised format, and is there a standard way of parsing it? If > not, I will have to special-case it, but I would prefer to avoid that if > possible. Doesn't look "standard" to me in any fashion. You shouldn't need to special cas

Re: CSV and number formats

2015-02-01 Thread Ethan Furman
On 01/31/2015 11:23 PM, Mark Lawrence wrote: > On 01/02/2015 06:45, Frank Millman wrote: >> >> >> Most transaction amounts are in the format '-0031.23' or '+0024.58' >> >> This can easily be parsed using decimal.Decimal(). >> >> If the opening balance is positive, it appears as '+0021.4

Re: CSV and number formats

2015-01-31 Thread Mark Lawrence
On 01/02/2015 06:45, Frank Millman wrote: Hi all I downloaded some bank statements in CSV format with a view to providing an automated bank reconciliation feature for my accounting software. One of them shows the opening balance in an unusual format. Most transaction amounts are in the format