Adding a line break in MySQL INSERT INTO text

后端 未结 10 2086
太阳男子
太阳男子 2020-12-07 22:07

Could someone tell me how to add a new line in a text that I enter in a MySql table?

I tried using the \'\\n\' in the line I entered with INSERT I

10条回答
  •  一整个雨季
    2020-12-07 22:35

    You can simply replace all \n with
    tag so that when page is displayed then it breaks line.

    UPDATE table SET field = REPLACE(field, '\n', '
    ')

提交回复
热议问题