S
stephen.h.dow
So, I have a series of loans (eg, mortgages) in one table - the loan
data include credit scores for the holders of the loan). In another
table, I have segments based on credit score. I need to create a query
that groups the loans by segment. So..
Loan Table:
ID FICO_1 FICO_2 Amount
1 750 699 100,000
2 650 700 200,000
3 750 710 222,000
4 676 699 300,000
5 720 729 150,000
Segment Table:
FICO_1 FICO_2 Segment
720 700 Good
700 680 OK
680 660 Fair
660 640 Warning
640 620 Bad
So, i need a query that puts a loan into the highest segment based on
meeting both scores:
Segment Amount
Good 373,000
OK 100,000
Fair 0
Warning 300,000
Bad 200,000
Thanks for any help - much appreciated.
data include credit scores for the holders of the loan). In another
table, I have segments based on credit score. I need to create a query
that groups the loans by segment. So..
Loan Table:
ID FICO_1 FICO_2 Amount
1 750 699 100,000
2 650 700 200,000
3 750 710 222,000
4 676 699 300,000
5 720 729 150,000
Segment Table:
FICO_1 FICO_2 Segment
720 700 Good
700 680 OK
680 660 Fair
660 640 Warning
640 620 Bad
So, i need a query that puts a loan into the highest segment based on
meeting both scores:
Segment Amount
Good 373,000
OK 100,000
Fair 0
Warning 300,000
Bad 200,000
Thanks for any help - much appreciated.