It's recognising what you say: whatever decisions you take there will always be a cost. You'll miss out on something somewhere because it's not possible to know and do and afford everything.
I'm not sure where the phrase originated, but I came across it in this book.