Problem 33. Population and Area by Continent проблем със сменянето от int на bigint
това ми е заявката:
SELECT CO.ContinentName, CAST(SUM(C.AreaInSqKm) AS BIGINT) AS [CountriesArea],
CAST(SUM(C.Population) AS BIGINT) AS [CountriesPopulation]
FROM Continents AS CO
LEFT JOIN Countries AS C ON CO.ContinentCode = C.ContinentCode
GROUP BY CO.ContinentName
ORDER BY CAST(SUM(C.Population) AS BIGINT) DESC
Дава ми тази грешка:
Msg 8115, Level 16, State 2, Line 1
Arithmetic overflow error converting expression to data type int.
къде греша