“Schwein haben” is a really common colloquial phrasing for being lucky in a specific situation, particularly situations where you escape “bad luck”.
Like, for example you get to the train station too late but turns out the train also has a delay. In that situation you could say:
- “Puh, Schwein gehabt.”
- “Phew, that was lucky.”
That’s actually the most common way of using the phrase – after a particular instance of being lucky.
In more general contexts, people would use the word Glück instead.
- Thomas hat immer Glück beim Daten.
- Thomas is always lucky with dating.