我是PHP语言的新手,我有2个csv文件,其中包含:前2列,第一列带有一些国家/地区前缀,第二列带有通讯国家名称。
第二列有2列,第一列有电话号码,第二列是通讯国家。
如果我找到匹配的前缀,我需要对这2个文件进行比较,我需要删除这个号码,并将其余的电话号码添加到另一个文件中。
例如:
First File x.csv Second file y.csvprefix country country phone number 4474 UK UK 44793245683... 347466 Spain Spain 34746689211345 3278 Belgium Belgium 324568845212..... Switzerland 4189544562131... UK 4474321546588464... Italy 39324566546548345 UK 4478564684151... </pre>
So I want in another fil z.csv this output:
country phone number UK 44793245683...This means that in this numbers has found match of prefixes: Country Phone NUmber Match Prefix Spain 34746689211345 347466 UK 4474321546588464 4474
Belgium 324568845212..... Switzerland 4189544562131... Italy 39324566546548345 UK 4478564684151...
谢谢!