This paper investigates the factors influencing banks' decision to engage in advanced risk management, from both a theoretical and an empirical perspective. In recent decades, credit risk management in banks has become highly sophisticated and banks have become more active and advanced in the management of credit risks. We identify two driving factors for risk management: bank competition and sector concentration in the loan market. We find empirical support for our hypotheses, using a unique data set of 249 German banks; parts of the data set are hand-collected. Bank competition pushes banks to implement advanced risk management. Sector concentration in the loan market promotes credit portfolio modeling, but inhibits credit risk transfer.