没有合适的资源?快使用搜索试试~ 我知道了~
declare @LikeSql nvarchar(32);–定义一个like变量,如果是存储过程,此处可以存储过程的参数 set @LikeSql = ‘someword%’;–把LikeSql变量赋值,可以赋值成’%xxxxxxxxxxxx%’ declare @SelectSql nvarchar(128)–定义Sql语句,开始拼Sql set @SelectSql = ‘select * from Table where [Column] like @LikePar’;—使用@LikePar变量进行参数化 exec sp_executesql @SelectSql ,N’@LikePa
资源推荐
资源详情
资源评论
![pdf](https://img-home.csdnimg.cn/images/20210720083512.png)
![zip](https://img-home.csdnimg.cn/images/20210720083736.png)
![pdf](https://img-home.csdnimg.cn/images/20210720083512.png)
![doc](https://img-home.csdnimg.cn/images/20210720083327.png)
![pdf](https://img-home.csdnimg.cn/images/20210720083512.png)
![pdf](https://img-home.csdnimg.cn/images/20210720083512.png)
![pdf](https://img-home.csdnimg.cn/images/20210720083512.png)
![zip](https://img-home.csdnimg.cn/images/20210720083736.png)
![txt](https://img-home.csdnimg.cn/images/20210720083642.png)
![txt](https://img-home.csdnimg.cn/images/20210720083642.png)
![text/plain](https://img-home.csdnimg.cn/images/20210720083646.png)
![7z](https://img-home.csdnimg.cn/images/20210720083312.png)
![rar](https://img-home.csdnimg.cn/images/20210720083606.png)
![h](https://img-home.csdnimg.cn/images/20210720083646.png)
![](https://csdnimg.cn/release/download_crawler_static/14834917/bg1.jpg)
在在sp_executesql中使用中使用like字句的方法字句的方法
declare @LikeSql nvarchar(32);–定义一个like变量,如果是存储过程,此处可以存储过程的参数
set @LikeSql = ‘someword%’;–把LikeSql变量赋值,可以赋值成’%xxxxxxxxxxxx%’
declare @SelectSql nvarchar(128)–定义Sql语句,开始拼Sql
set @SelectSql = ‘select * from Table where [Column] like @LikePar’;—使用@LikePar变量进行参数化
exec sp_executesql @SelectSql ,N’@LikePar as varchar(32)’,@LikePar = @LikeSql;–使用sp_executesql来执行
资源评论
![avatar-default](https://csdnimg.cn/release/downloadcmsfe/public/img/lazyLogo2.1882d7f4.png)
![avatar](https://profile-avatar.csdnimg.cn/default.jpg!1)
weixin_38696090
- 粉丝: 4
- 资源: 874
上传资源 快速赚钱
我的内容管理 展开
我的资源 快来上传第一个资源
我的收益
登录查看自己的收益我的积分 登录查看自己的积分
我的C币 登录后查看C币余额
我的收藏
我的下载
下载帮助
![voice](https://csdnimg.cn/release/downloadcmsfe/public/img/voice.245cc511.png)
![center-task](https://csdnimg.cn/release/downloadcmsfe/public/img/center-task.c2eda91a.png)
最新资源
资源上传下载、课程学习等过程中有任何疑问或建议,欢迎提出宝贵意见哦~我们会及时处理!
点击此处反馈
![feedback](https://img-home.csdnimg.cn/images/20220527035711.png)
![feedback](https://img-home.csdnimg.cn/images/20220527035711.png)
![feedback-tip](https://img-home.csdnimg.cn/images/20220527035111.png)
安全验证
文档复制为VIP权益,开通VIP直接复制
![dialog-icon](https://csdnimg.cn/release/downloadcmsfe/public/img/green-success.6a4acb44.png)