Two answers:
9 or 4,294,967,296
9 is only in Pokémon Go, so that's the joke answer.
But for the main series games, the pattern variations are calculated by Personality Values, which is a 32bit number, which is why the odds of finding two exactly alike Spinda is 1 in 4,294,967,296.
Source