I have a CSV I\'m importing into our database. One of the \"columns\" contains data that should be an INT but some rows have numbers that only fall in the BIGINT ra
I'm not sure this is the best answer but it is one I came up with earlier on my own. It is possible to catch the exception/error and gracefully continue execution.
Example:
DECLARE @UserIDBigInt BIGINT = 9723021913;
DECLARE @UserID INT;
BEGIN TRY
SET @UserID = @UserIDBigInt;
END TRY BEGIN CATCH
END CATCH
IF @UserID IS NULL BEGIN
SELECT 'Handle it as unreliable data'
RETURN
END
SELECT 'Handle it as reliable data'