【问题标题】:Search unicode-characters in sql server在 sql server 中搜索 unicode-characters
【发布时间】:2014-11-19 20:34:21
【问题描述】:

我必须搜索所有记录,其中 BodyTxt 属性包含 unicode \uDE8F

如何在 Like-Statement 中使用字符 \uDE8F

【问题讨论】:

    标签: sql-server unicode


    【解决方案1】:

    使用charindex

    select * from tablename where charindex('\uDE8F',columnname)>0
    

    或使用like

    select * from tablename where columnname like '%\uDE8F%'
    

    【讨论】:

    • 谢谢 - 但文字 \uDE8F 应该被解释为 Unicode 字符。我该怎么做?
    • @ThomasKehl 那么每个字符的 unicode 将作为整数存储在列中吗?
    • 不,但我有我必须搜索的 Unicode 字符的整数值
    猜你喜欢
    • 1970-01-01
    • 2015-05-16
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2010-09-14
    • 1970-01-01
    • 2013-08-05
    • 1970-01-01
    相关资源
    最近更新 更多