0

不太了解 MYSQL 只是想将这个 SQLSERVER 代码转移到 MYSQL 中工作

Select [SALARY],[BONUS],[COMM],
SUM (SALARY + BONUS + COMM)AS 
'Total Compensation'
FROM [Enterprise].[dbo].[Employee]
Where ED_LVL >= '16'
group by [SALARY],[BONUS],[COMM]

我显然切换了表名以适应 mysql

4

1 回答 1

3

消除[]

SELECT SALARY,BONUS,COMM,
SUM (SALARY + BONUS + COMM) AS 'Total Compensation'
FROM databaseName.Employee
WHERE ED_LVL >= 16
GROUP BY SALARY,BONUS,COMM
于 2013-10-29T05:05:20.307 回答