Hi All, I am working on a database which reads call records from a pabx and splits them with associated costs to separate people.
I have one table callrecords which holds all the records, the only thing I need from there is the duration and destination number. To determine the charge for the call I need to lookup the call rate from my rates table which defines the prefix for the number and the rate to charge for the prefix.
My problem is that I want to setup a relationship to do this lookup of the call rate, but, different countries have different prefixes, for example US is 1, but Finland is 358, Germany/Dusseldorf is 49211, how on earth can I match the call rate records in my rates table with prefixes from the callrecords table when the number of characters varies from prefix to prefix ?
Any suggestions would be greatly appreciated, I have been looking for some answers for this for some time. I have considered a calculated field for the relationship, but I will still have the problem of never really knowing the prefix which has been used for each call record.
Regards
Paul