|
There's really not enough information in your question to give you a good response. Do you know what the tables this data is in look like (e.g., the fields and types)? Do you know which field the "type" is in and what fields need to be ranked? Also, what type of database are you connecting to (MS SQL Server, Oracle, etc.) Are you going to display customers who only have BOTH type A and type B, or do you want to display all customers and do the sums and counts for just those types?
There's probably a way to do this in SQL, but without more info I can't give you a good answer for how to do this.
-Dell
|