We use our homebrew shop system together with Salesforce and Financialforce. Invoices are created and send by our shop system. After an invoice is created it will be transmitted to related Salesforce account by SOAP-API (we can also use REST). Invoices are stored in Salesforce/FF object c2g__codaInvoice__c, related line items in c2g__codaInvoiceLineItem__c. Next year we want to use Salesforce for billing (for another shop we use it already).
Unfortunately transmission of account currency by SOAP had a bug, now we have many Salesforce accounts with wrong currency, e.g. EUR in shop / USD in Salesforce/FF. Since invoices for many affected accounts are already posted, we cannot edit accounts currency fields CurrencyIsoCode and c2g__CODAAccountTradingCurrency__c.
So, is there any way to change affected accounts currency by Apex code? Loss of invoices is acceptable (they are stored in our shop), but I would not like to delete and recreate accounts.