Arithmetic overflow error when summing an INT, how do I cast it as a BIGINT?
Try converting it before summing. eg.
SELECT SUM(CONVERT(bigint, columnname)) FROM tablename
or
SELECT SUM(CAST(columnname AS BIGINT)) FROM tablename
Try converting it before summing. eg.
SELECT SUM(CONVERT(bigint, columnname)) FROM tablename
or
SELECT SUM(CAST(columnname AS BIGINT)) FROM tablename