zoukankan
html css js c++ java
在.net中接收存储过程返回的值
getCon();
//
连接数据库的方法
int
id
=
35
;
SqlParameter[] par
=
new
SqlParameter[
2
];
par[
0
]
=
new
SqlParameter(
"
@id
"
, SqlDbType.Int);
par[
0
].Value
=
id;
par[
1
]
=
new
SqlParameter(
"
@count
"
, SqlDbType.Int);
par[
1
].Direction
=
ParameterDirection.Output;
//
设置为输出参数
SqlHelper.ExecuteNonQuery(con, CommandType.StoredProcedure,
"
getChildCount
"
, par);
this
.Label1.Text
=
par[
1
].Value.ToString();
//
接收输出的参数
存储过程代码如下:
create
proc
getChildCount
@id
int
,
@count
int
output
as
select
@count
=
babycount
from
yangsCMS_Article_Class
where
id
=
@id
order
by
treekey
查看全文
相关阅读:
开放6379端口
synchronized 实现同步的基础
pythoning—— 5:实战篇(购物车)
pythoning ——3、数据类型(字符串)
pythoning ——2、数据类型(元组、序列)
pythoning ——1、基础篇
暗链/黑链
什么是webshell
获取当前设备IP
生成公钥
原文地址:https://www.cnblogs.com/yangbin1005/p/989865.html
最新文章
linux(centos7)安装docker
各种资源下载地址
svn相关
svn使用
git中ssh报错
SVN初识
git附加
git流程
git初学、安装
eclipse附加任务
热门文章
eclipse附加功能
eclipse项目
spring boot 使用 EnvironmentAware 加载配置文件
httpclientUtils
java 读取外部和source下配置文件
卸载npm
云计算的三种服务模式
docker入门 什么是docker? 为什么使用docker?
linux 安装 fuser
linux安装jdk
Copyright © 2011-2022 走看看