用空格替换非字母数字字符,而忽略postgres中的引号吗?

时间:2018-07-08 12:36:11

标签: regex postgresql

我想用空格替换字段中的所有非字母数字字符。

select 'Gishath, Sun''s Avatar', lower(regexp_replace('Gishath, Sun''s Avatar', '[^-a-zA-Z0-9_]+', ' '))

我期望结果为gishath sun s avatar,但返回的是gishath sun's avatar。为什么?

1 个答案:

答案 0 :(得分:0)

NVM,问题在于缺少g标志。

System.Windows.Forms.MessageBox.Show(x.Name, "Form Title");

解决了问题

相关问题