If one or both of your data sets are in MySQL already, there may be no need to do the comparison in PHP. Just use IN() or INNER JOIN. Or is there some particular reason why neither of these will work in your case?

Cheers,

Mattias

On 09/16/2011 05:36 AM, Dare Williams wrote:
Dear PHP Group,

I need a Function of any category in  either PHP or MySQL RDBMS customize 
Function, Class, Methods or anything that could help me compare a particular 
set of number and return their matching result. e.g If I have a 5 Digits set of 
number  and need to match it with another set of five  digits and return how 
many number are match and the figures that are match.

1.    (62,39,47,25,14) - (14,39,62,25,47) - match 5 (all)
2.    (55,11,27,62,39) - (66,39,12,13,27) - match 2 (27,39)
3.    (20,04,56,17,16) - (16,01,17,04,79) - match 3 (16,17,04)

Any Help will be appreciated.

Thank you.




--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to