Hi
I have a slight problem with my job cost database where I have been caught out with two sums summing inaccurately to a third figure. I think it is to do with rounding.
Before anyone shouts I do store calculated totals in a table since I have to be able to recreate an invoice on demand (for clients, accountant, records, tax etc) and so having not just a snapshot file of the individual invoices but also the calculated data seems sensible. I know it does not tie in with normalisation.
I have a query which draws relevant time sheet entries and produces a by line invoice value (i.e. time * rate). This can easily lead to a value of £14.783p which rounds to £14.78
I then have a similar process to list expense costs - which are always straight currency figures say £10.00.
My invoice then totals these two figures to give a nett sum, in this simple case £24.78.
I then need to add 17.5% VAT which is calculated off the nett sum and gives, in this case £4.3365p which rounds to £4.34
My invoice is thus £29.12 which is fine.
However, if there are a lot of time sheet entries then the roundings can get complex and I end up with the rounded nett sum, and the rounded VAT sum coming to less than the total invoice sum. It was only out by 1p but that does not invoke confidence in an accounting system.
Can anyone point me in a direction that would help me to resolve this? I am happy to drop my calculated table if I can find a more robust way of meeting all my requirements.
Any help would be much appreciated.
I have a slight problem with my job cost database where I have been caught out with two sums summing inaccurately to a third figure. I think it is to do with rounding.
Before anyone shouts I do store calculated totals in a table since I have to be able to recreate an invoice on demand (for clients, accountant, records, tax etc) and so having not just a snapshot file of the individual invoices but also the calculated data seems sensible. I know it does not tie in with normalisation.
I have a query which draws relevant time sheet entries and produces a by line invoice value (i.e. time * rate). This can easily lead to a value of £14.783p which rounds to £14.78
I then have a similar process to list expense costs - which are always straight currency figures say £10.00.
My invoice then totals these two figures to give a nett sum, in this simple case £24.78.
I then need to add 17.5% VAT which is calculated off the nett sum and gives, in this case £4.3365p which rounds to £4.34
My invoice is thus £29.12 which is fine.
However, if there are a lot of time sheet entries then the roundings can get complex and I end up with the rounded nett sum, and the rounded VAT sum coming to less than the total invoice sum. It was only out by 1p but that does not invoke confidence in an accounting system.
Can anyone point me in a direction that would help me to resolve this? I am happy to drop my calculated table if I can find a more robust way of meeting all my requirements.
Any help would be much appreciated.