首页 诗词 字典 板报 句子 名言 友答 励志 学校 网站地图
当前位置: 首页 > 教程频道 > 数据库 > SQL Server >

关于用户函数的有关问题

2012-01-18 
关于用户函数的问题我写了一个用户函数GetStr()selectGetStr()得到 a , b当我用select*fromtbwherestrin(d

关于用户函数的问题
我写了一个用户函数GetStr()
select   GetStr()
得到 'a ', 'b '

当我用select   *   from   tb   where   str   in   (dbo.GetStr())的时候得不到数据
但是直接用select   *   from   tb   where   str   in   ( 'a ', 'b ')却可以,是什么原因?

[解决办法]
select * from tb where charindex(str,dbo.getstr())> 0

热点排行
Bad Request.