mjvm / csv2qif

script to convert Caixa Directa CSV file to QIF
6 stars 1 forks source link

Caixa Geral changed the csv format #1

Closed pingomister closed 12 years ago

pingomister commented 12 years ago

First of all, thanks, I've been using your script for more than a year. Obrigado! Should I speak in portuguese here? Don't know. Second, just to let you know that CGD changed some little stuff in the csv layout, so your script is not working anymore. I would be very grateful if you find the time to update it soon. Again, muito obrigado.

mjvm commented 12 years ago

It works for me, can you give me an example so I can fix the script ?

pingomister commented 12 years ago

I click on the "xls" icon, in CGD Online, and download the file. After running the script, the outputted qif file is 0 kb in size: it has no content.

Are you sure that the script is working for you, currently? Caixa Directa's site has been completely renewed, and the xls's layout is quite different than before. Am I doing something wrong? Is your xls file not different than before? Mine has a new column, "Saldo disponível", less headers, and the footer (saldo) is placed differently.

Thanks for your assistance.

mjvm commented 12 years ago

I ran the script and it have parsed the file as usually and I didn't notice any difference in the format.

Can you please, give an example of the main part of the file. Ex:

"Data mov.";"Data valor";"Descrição";"Débito";"Crédito";"Saldo contabilístico"

"01-01-1970";"01-01-1970";"LEVANTAMENTO";"10,00";"";"1.000,00"
pingomister commented 12 years ago

Data mov. ;Data valor ;Descrição ;Débito ;Crédito ;Saldo contabilístico ;Saldo disponível ;

The header reads like this:

Consultar saldos e movimentos à ordem - 01-01-1970

Conta XXXXXXXXXXXXXX- EUR - Conta Caderneta
Data de início 01-01-1970 Data de fim 01-01-1970

Which is, as you may recognize, different than before.

I'm wondering... have they updated your caixa directa site to the new format, or are they doing it bit a bit on some clients only? Is the site completely different to you than a few days ago, or the same? This is the only explanation that I can think of...

pingomister commented 12 years ago

Also, the outputted file is named "comprovativo.csv" instead of the previous "globalstatement.csv", which is another difference but, of course, is not the reason why the script isn't working.

mjvm commented 12 years ago

I pushed a new version, can you try it ?

The name of the outputted file is the same of the imputed file with qif extension.

pingomister commented 12 years ago

Thank you, it seems to be working good now. I did two conversions and both turned out fine.

mjvm commented 12 years ago

Cool, thanks for your input, keep it coming.