?! -4 indicates that you're using the 4 *last* digits... It has nothing to do with prefix in this case :)
Vincent -- Telemaque - NICE Service Technique Tel : +33 4 93 97 71 64 (fax 68) [EMAIL PROTECTED] ----- Original Message ----- From: "Guillaume Cottenceau" <[EMAIL PROTECTED]> To: "Vincent CHAVANIS" <[EMAIL PROTECTED]> Cc: <[email protected]>; "Alexander Malysh" <[EMAIL PROTECTED]> Sent: Tuesday, January 10, 2006 5:51 PM Subject: Re: [PATCH] DLR with field_dst not supported in Mysql/Pgsql > "Vincent CHAVANIS" <vincent 'at' telemaque.fr> writes: > >> [SELECT mask, srvc, url, src, dest, boxc FROM dlr WHERE smsc='SMSC-1' AND >> ts='211205080007' and dest like CONCAT('%',SUBSTRING('number',-4));] > > Are you sure "4" is enough? What about countries with a 3-digit > international prefix? And when you strip too much you also have > the risk of removing too much (after all, some operators use > aliases, not real phone numbers). > > IMHO this solution is too generic, that's why I really prefer the > solution of using a unified prefix. > > -- > Guillaume Cottenceau >
