I have a column of a table located on a Linked Server (from Oracle) that exceeds the varchar (Max) of a column in a SQl Server table. I need to cut the values to the Max of the column in order to pass the data through a SQL Server Job. This is the query I have in the step of Job:
TRUNCATE TABLE SMARTCLOUD.DBO.COMMLOG
INSERT INTO SMARTCLOUD.DBO.COMMLOG
SELECT [COMMLOGID]
,[SENDTO]
,[SENDFROM]
,[SUBJECT]
,[CREATEBY]
,[CREATEDATE]
,[COMMLOGUID]
,[MESSAGE]
FROM [SMARTCLOUD]..[MAXIMO].[COMMLOG]
The column that exceeds the maximum is [MESSAGE]