Model::find()->createCommand()->getRawSql();或者$model->find()->createCommand()->getRawSql();PHP中文网,有大量免费的Y