|I'm trying to manipulate some data so that i can determine how many companies in our database have different country classifications between our different financial products (different products have different rules which make us classify companies differently).|
each row of this table i am working with in SQL is company based. the table is unique on our internal identifier ("symbol") and the product code (product_id). so there can be multiple MSFT's in the table but only one MSFT in product 211 for example.
anyway, i'm trying to determine which companies have different country classifications ("p_ctrycode") between the products they are in. if a company is constant across the board (most will be) then i don't want it in my results.
in addition to knowing which companies have different classifications i would also like to know what classifications are in which products for the ones that differ.
i've never encountered this issue before - it seems like i need to re-map/restructure product_id to be the column names (maybe?) or something to that extent.
it's kind of driving me nuts. any help would be appreciated.
thanks in advance.