Home Forums Programming General Avoid Statement Termination due to possible string truncation. RE: Avoid Statement Termination due to possible string truncation.

  • Thanks Thom,

    But this would just disappear the warning. Let me make it more clear about what i am looking for

    create table TEST_INSERT
    (id int , name varchar (3))

    GO 

    INSERT INTO TEST_INSERT
    SELECT 1, 'FOUR'

    In case the warnings are on i get the error, otherwise it says completed successfully and in both cases nothing gets inserted.
    What I am looking for is to have the first 3 characters inserted and the rest ignored.
    I cannot use a LEFT/SUBSTRING function as I am trying to fetch data from a linked server.

    Thanks.