When metal X replaces metal Y from its respective salts, X is above in the reactivity series.
The reactivity power of X is stronger than Y which ensures this replacement.
If it would be below than Y, no reaction would take place as it would not displace Y.