I am not a mySQL expert (obviously), my limited SQL experience is with
MS SQL where stored procedures and views are an option.
This is with mySQL 4.x, so no views.
I'm no an expert too, but even if the algorithm is right and seems to
bring some optimization I think mysql way of do
Does anyone have a mysql query that will compare a number
from the asterisk cdr to a table of international country+city codes to determine
the closest match?
The two fields are;
Asterisk mysql cdr dst
field sample record value 011441316551212
rate table data like this
What are the contents of your database? If you can put in a regex
expression then I can tell you exactly how to do it, otherwise I can
tell you close. In ASTPP, I'm doing it similar to how ASTCC does it.
I'll lay it out here:
Pattern field in CDR
^1403.* will match anything beginning with