I need to compare price lists for telephony calls between several (2-n where n will not exceed 8) providers and select the best route.
The received price lists can be like the examples below (only each is actually between 5,000 and 20,000 prefixes):
The information should be imported via a php page, where I would have the following options:
1. "Upload" price lists one by one (csv files).
2. "Finish" uploading the price lists.
3. Select the "Prefered" provider (at the end of the import process).
4. Set the prefered provider's "Margin" (percetange).
Luanch the "Compare" process.
The comparison rules should take into consideration the following criterias:
1. The prefered provider's price should be reduced by the allowed margin prior to the comparison.
2. Prefixes that are deeper (more digits) that appear in one or more lists, but not in all other list should be compared to the shorter prefix in the lists in which they are not listed. For example, in the lists above, 33601 in the first list doesn't appear in the other lists, so it should be compared to 336 in the other lists.
3. For prefixes that are listed in less than all the list, only the relevant lists should be considered. In the above example, prefix 34 should automatically give list 1 as best, because the others do not provide it.
The result table should generate a new variable (based on the number of providers uploaded) list that would include the following information:
1. The full list of prefixes.
2. The price column of each provider.
3. The price difference between each provider and the selected best route.
4. The column number of the best provider.
The result for the example above would be (considering that the margin is 0%):
Prefix Cost1 Diff1 Cost2 Diff2 Cost3 Diff3 Best
The project needs to be developed in php/MySQL.
Preference would be given to those that would be aable to complete it very rapidly (price is also very important).
I'm available for any clarifications that may be required.