A simple, fast response and aggregation-induced emission (AIE) fluorescent chemical sensor 2,2′-(hydrazine-1,2-diylidenebis(methaneylylidene))diphenol (SX) based on o-hydroxybenzaldehyde had been designed and synthesized. Interestingly, the increase of water content, the color of the SX solution changed from colorless to bright yellow in solution, and the chemical sensor SX showed the unique AIE properties. The chemical sensor SX exhibited high selectivity and sensitivity to Zn2+ without Cu2+ in DMSO/H2O (4:1, v/v) solution, and the limit of detection was 6. 8 × 10−8 M. In addition, the in situ generated [SX + Zn2+] system was used for the relay detection of Cu2+ without separation and purification and exhibited a new fluorescence quenching signal under the same conditions, and limit of detection [SX + Zn2+] to Cu2+ was 2.3 × 10−8 M. Furthermore, the chemical sensor SX had been successfully applied to detect and analyze Zn2+ and relay detect Cu2+ in environmental water samples.