搜索xml数据时出错 [英] while searching xml data getting error

查看:77
本文介绍了搜索xml数据时出错的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

" 一个或多个字符从xml到目标排序规则的sql转换 "

在我的项目中有一个搜索框,当用户键入内容时,其结果如下.
1>帖子标题:-varchar
2>发布内容:-xml
3>日期:-日期
工作正常,
现在我更改标题的数据类型
从varchar到xml,它给了我上面的错误

"sql conversion of one or more characters from xml to target collation impossible"

in my project there is a search box and when user type something it gives results as follows.
1>post title:-varchar
2>post content:- xml
3>Date:- date
it was working fine,
now i change data type of title
from varchar to xml it gives me above error

推荐答案

当您在XML中具有Unicode字符并且试图将其转换为varchar值时,会发生此错误.如果您在任何地方都进行了此类转换,请将varchar更改为nvarchar.请参阅链接 http://nerdwords.blogspot.in/2010/01 /sql-server-error-conversion-of-xml.html [
This error occurs when you have unicode charactors in the XML and you are trying to convert it to a varchar value. If you have such conversions anywhere change varchar to nvarchar. See the link http://nerdwords.blogspot.in/2010/01/sql-server-error-conversion-of-xml.html[^]


这篇关于搜索xml数据时出错的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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