如何从 SQL Server 中的列中删除不间断空格? [英] How do I remove non-breaking spaces from a column in SQL server?

查看:41
本文介绍了如何从 SQL Server 中的列中删除不间断空格?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试从表中的字段中删除不间断空格 (CHAR 160).我试过使用像 RTRIM() 这样的函数来摆脱它,但值仍然存在.

I'm trying to remove a non-breaking space (CHAR 160) from a field in my table. I've tried using functions like RTRIM() to get rid of it, but the value is still there.

我需要做什么才能从列中删除不间断空格?

What do I need to do to remove the non-breaking space from the column?

推荐答案

尝试使用 REPLACE

UPDATE Your_Table
SET Your_Column = REPLACE(Your_Column, NCHAR(0x00A0), '')
WHERE Id = x

这篇关于如何从 SQL Server 中的列中删除不间断空格?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆