The present invention provides a useful medicament for the treatment and/or prophylaxis of a disease associated with the enhancement of OPN production including cancer, which comprises a compound of formula: wherein R 1 , R 2 , R 3 , R 4 , R 5 , R 6 , R 7 , m, n, p, X, and Y are as defined in the specification, or a pharmaceutically acceptable salt thereof.