帮我写一个sql,1-10求和
时间: 2024-06-06 17:08:31 浏览: 154
sql中分组和求和重点介绍
SELECT SUM(numbers) FROM (SELECT 1 AS numbers UNION SELECT 2 UNION SELECT 3 UNION SELECT 4 UNION SELECT 5 UNION SELECT 6 UNION SELECT 7 UNION SELECT 8 UNION SELECT 9 UNION SELECT 10) AS t;
阅读全文