sqlserver join query value is NULL

Today, when the join query is performed in sqlserver, the value of the right table field is NULL, so record it.
The reason is that the data in the right table was manually copied and pasted from excel, which resulted in the carriage return and line feed (\r\n) being copied in the copy, and the carriage return and line feed of the corresponding field needs to be removed.

UPDATE table name
SET field name = REPLACE(field name, CHAR(13) + CHAR(10), '')

Guess you like

Origin blog.csdn.net/qsyjrz206/article/details/115431201