1 |
originally posted 2014-06-27 |
In any Excel cell that needs line-breaks, instead of using ALT-ENTER, put a placeholder {NL} in the Excel cell’s text.
Example: 123 Maple St{NL}Apt 2{NL}Sacramento,CA{NL}95818
Paste the Excel data into the SQL table as normal.
Execute this SQL statement to change the placeholders to SQL line-break characters:
update [tablename] set [fieldname] = replace([fieldname],'{NL}',CHAR(13))