We propose measurements of v,N=0,0→(1,0) transition frequencies of alkali earth-alkali diatomic molecules and alkali earth-hydride molecular ions. We show that the vibrational transitions considered here are useful for detecting a possible variation in the proton-electron mass ratio, possibly at the 10-16 sensitivity level. In the experiments, cold alkali earth-alkali molecules, obtained by binding cold atoms or by molecular laser cooling, are trapped by laser light at a frequency, at which the Stark shift is eliminated. Alkali earth-hydride molecular ions are sympathetically cooled with another ion to form a string crystal at the position, at which the electric field is zero. The vibrational transitions are observed by the Raman transition induced by two lasers with frequencies, at which the Stark shift is eliminated.