本文介绍了呼叫商店程序的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
这是我的商店采购信息
This is my store procure
crate proc [dbo].[SP_BP_pingGenrated]
(
@ID bigint,
@MemberID bigint,
@SponsorID bigint,
@BoardID bigint,
@SerialID bigint,
@RankLevel bigint,
@PlanID varchar(50),
@createDate datetime,
@ModifiedDate datetime,
@status bit
)
AS
declare @Count int
SELECT @Count=COUNT(ID) from BP_pinGenrated
if @Count >13
BEGIN
SELECT @MemberID= MemberID from BP_pinGenrated WHERE SponsorID >1
--declare @mid int
--@mid=MemberID
--@MemberID
update BP_pinGenrated SET SerialID=11,RankLevel=2 where MemberID=@MemberID
end
我想像这样在ON.CS页面上调用
I want call ON .CS page Like this
adp = new SqlDataAdapter("SP_BP_pingGenrated", con);
adp.SelectCommand.CommandType = CommandType.StoredProcedure;
scd = new SqlCommandBuilder(adp);
SqlCommand cmd = new SqlCommand("SP_BP_pingGenrated");
cmd.CommandType = CommandType.StoredProcedure;
但我没有得到ans
我该如何打电话给我的商店采购请帮助我
[edit]删除喊话,添加了代码块-OriginalGriff [/edit]
But I not getting ans
How can i call my store procured help me please
[edit]SHOUTING removed, Code block added - OriginalGriff[/edit]
推荐答案
SqlConnection con = new SqlConnection(strConnect);
con.Open();
SqlCommand com = new SqlCommand("myStoredProcedure", con);
com.CommandType = CommandType.StoredProcedure;
SqlParameter name = new SqlParameter("@Name", SqlDbType.VarChar, 100);
name.Direction = ParameterDirection.Output;
com.Parameters.Add(name);
com.ExecuteNonQuery();
这篇关于呼叫商店程序的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!