select 'ABC', 'A'
union all select 'MMM', 'S'
union all select 'XYZ', 'A'
union all select 'XYZ', 'B'
union all select 'ABC', 'W'
union all select 'XYZ', 'W'
union all select 'DEF', 'C'
It looks like in your code, you have to need to know all the companies and pay frequencies ahead of time, and...