存储过程

create proc test4
@res varchar(10) output
as
select @res=count(*) from Ship_TUser_Info
go

cs文件:

SqlParameter[] paras = new SqlParameter[] { new SqlParameter("@res", SqlDbType.Int) };
         paras[0].Direction = ParameterDirection.Output;
         SqlHelper.ExecuteNonQuery(SqlHelper.ConnectionStringLocalTransaction, CommandType.StoredProcedure, "test4", paras);
         Response.Write(paras[0].Value.ToString());

相关文章:

  • 2021-12-08
  • 2021-06-29
  • 2022-12-23
  • 2022-01-29
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
猜你喜欢
  • 2021-08-27
  • 2021-10-15
  • 2021-11-28
  • 2022-12-23
  • 2022-12-23
  • 2021-11-16
  • 2021-08-19
相关资源
相似解决方案