我希望我能弄清楚。我需要生成一个平均值为AVG_AMT(整数)的表,并且没有小数。它可以舍入或截断。这张桌子真的没关系。
这是我试图写的:
SELECT `TC Code`, AVG(ALW_AMT) as int(8,0) AS AVG_AMT FROM OFFICE_Claims_Physicians GROUP BY `TC Code` ORDER BY `TC Code`;
有什么建议?
SELECT `TC Code`, round(AVG(ALW_AMT),0) AS AVG_AMT FROM OFFICE_Claims_Physicians GROUP BY `TC Code` ORDER BY `TC Code`;