The present invention aims to provide a glucokinase activator useful as a pharmaceutical agent such as an agent for the prophylaxis or treatment of diabetes, obesity and the like.The present invention provides a glucokinase activator containing a compound represented by the formula (I):wherein each symbol is defined in the specification, or a salt thereof or a prodrug thereof.本發明之目的在提供一種適用為藥劑之葡萄糖激酶活化劑,該藥劑為例如:用於預防或治療糖尿病、肥胖等之藥劑。本發明提供一種包含式(I)表示之化合物或其鹽或其前藥之葡萄糖激酶活化劑:其中各代號如說明書中之定義。