0

I have created a sql server script of a large database table (more than 2 GB). while running the script I got this error: "Unclosed quotation mark after the character string." While trying to debug the issue I have found that there is a strange "NUL" value between text. This "NUL" is only visible in Notepad++.

Anyone knows how to make script of database table without this "NUL". {If I remove this manually script works fine. But I am not able to remove it manually as some tables are more than 10 GB}

enter image description here

Thanks

MaxPayne
  • 1,028
  • 1
  • 12
  • 19

1 Answers1

0

Thanks all I have solved my issue.

I was reading data from NON MS Sql Database and inserting into MS SQL server using asp .net ADO way. During testing of the cause I found that there is invalid data "NUL" in the existing database. So I modified my insertion code and just replaced "NUL" with "Blank" using REGEX.

Regex.Replace(MyDataColumnName, "\x00", "", RegexOptions.IgnoreCase);

Now there is no "NUL".

MaxPayne
  • 1,028
  • 1
  • 12
  • 19