A Unified Method for Checking Compatibility and Uniqueness for Finite Discrete Conditional Distributions