I have multiple 9s, 40s, and 45s, I like all. I take a slightly different stance on this entire issue than most. I actually don't view the 40 as competing with 9, I view it as competing with 45. So, in my case the 45 is the odd man out and I don't really shoot it much and I use 9 and 40. The 40 has all the capability of 45 if for whatever reason I wanted something better than 9 for barriers. Vs. soft targets the 3 are are comparable with good ammo.
Why 40 over 45 for ME, two reasons:
1. More capacity
2. The glocks share holsters with the 9's and other accessories, like sights, with the 9's.
3. AMMO availability during panics
So in a nutshell, my 19/17 are my core but I have a 22 and 27 on stand bye. My 45's don't come out much. The FBI and DEA are both going back to 9 by the way.