Sample Header Ad - 728x90

SQL Bulk Insert Saves extra character

-1 votes
1 answer
89 views
i use this code for Bulk Insert BULK INSERT [Table] FROM 'D:\phones.txt' WITH ( ROWTERMINATOR = '0x0a' ) My data has only one column of 10 characters For example | 1234567890 | | 1234567891 | | 1234567892 | After saving in the database, by running the following code, it shows the length of the data more SELECT TOP (1) [Phone] ,LEN([Phone]) AS Phonelength FROM [Table] result | Phone | Phonelength | | ---------- | ----------- | | 1234567891 | 11 | The extra character added to the end of the field is the new line Why is the new line added?
Asked by ioxoi (9 rep)
Apr 12, 2024, 08:04 PM
Last activity: Apr 13, 2024, 08:44 AM