Power supply connector

The simplest way is to forget the third pin thing, and just use 2 diodes.

 9v +---->|----\
                ----------+
12v +---->|----/