I have been shooting IDPA for a number of years and have used several Glock pistols, 17, 19, 22 and 23. The 17 and the 22 work just fine but I did notice that I do better with the 19 and 23 as they are a bit faster on the target. Most of the shooting is done at 10 yards and less so a long sight radius is of little value. On a few occasions I have used my Glock 26 just to get practice with my carry gun and I found that it works fine. IDPA is the same as other shooting sports in that you need a tool that you are comfortable with and then a lot of practice both live and dry fire. You need to practice your draw and magazine changes (especially the retention change) which can be done at home. Enjoy it and remember it is just a game.
Get a decent holster, and matching dual mag pouches (I like Kydex).