none
Issue in SQL job RRS feed

  • Question

  • HI All,

    we are pulling the data from source to our MS SQL server by using API. 

    the problem is when we are trying to pull the data into our tables. some times column length size more than 100.

    But have indicated var char 100 at our end. 

    that column have more than 50000 Millions records and table contains 150 Columns. 

    Same problem with 50 columns.

    What is the best solution to change. ?

    Regards,

    Rajesh.K

    Friday, November 15, 2019 12:30 PM

All replies

  • varchar(100) means variable length *up to* 100 characters.

    If some of your incoming columns are more than 100 characters in length, then you need to increase the length of destination columns to accommodate the longer lengths of data coming into them.

    For example, increase destination columns to varchar(150) or varchar(200).

    HTH,


    Phil Streiff, MCDBA, MCITP, MCSA

    Friday, November 15, 2019 12:40 PM
  • Hi Rajeshk00091,

    Please find the column is needed to changed. And then , please try following script.

    ALTER TABLE table_name ALTER COLUMN column_name datatype
    

    Best Regards,

    Rachel 


    MSDN Community Support
    Please remember to click "Mark as Answer" the responses that resolved your issue, and to click "Unmark as Answer" if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to MSDN Support, feel free to contact MSDNFSF@microsoft.com.

    Monday, November 18, 2019 7:39 AM
  • Hi ,

     

    I am writing to follow up this thread with you. Have you solved your issue? If you have solved your issue ,in order to close this thread, please kindly mark helpful replies as answers. By doing so, it will benefit all community members who are having this similar issue.  Your contribution is highly appreciated.

     

    Best Regards,

    Rachel


    MSDN Community Support
    Please remember to click "Mark as Answer" the responses that resolved your issue, and to click "Unmark as Answer" if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to MSDN Support, feel free to contact MSDNFSF@microsoft.com.

    Tuesday, November 19, 2019 8:47 AM