Mobility matches open housing markets. With constrained mobility and partially open housing markets, market responses reflect the constraints. We study this mechanism by examining disparity in access to public schools across socio-economic groups, focusing on properties near primary schools accessible to migrant students under social integration policies in a Chinese megacity. Using a difference-in-differences approach, we uncover complex spatial and market dynamics: while house prices close to ordinary primary schools remained relatively stable, house prices farther away declined markedly. This differential impact suggests the interaction between a potential "peer effect" and an "amenity effect." The rental rates showed little change from the migrant inflow and native flights. The reform also triggered a decrease in second-hand house sales, coupled with increased rental activities. This study highlights the effect of school enrollment policies on urban spatial dynamics, with significant implications for policymakers seeking to promote social integration in megacities.