2016-06-02 14 views

Antwort

3

erstellen Stored Procedure

Create procedure MyProcedure 
(@id varchar(20),@search varchar(20)) -- these are the parameters to this procedure 
as 

begin 

    select * from yourTable where [email protected] 

end 

oder (ohne Parameter)

Create procedure MyProcedure 
as 

begin 

    select * from yourTable where ID=10 

end 

eine gespeicherte Prozedur mit Entity Framework

// tbl_CompMgmt is a class which look exctly like the result returned 
var mgtList = db.ExecuteStoreQuery<tbl_CompMgmt>("exec GetSortedManagement @Companay_ID=" + compID).ToList(); 
+0

Danke für die Infos suchen Arun, Bitte helfen Sie mir, wie gespeicherte Prozedur von asp.net aufrufen, ich habe eine Auswahl erstellt gespeicherte Prozedur, jetzt, wie man es nennt –

+1

Bitte verweisen Sie diese Seite http://www.codeproject.com/Articles/748619/ADO-NET-How-to-call-a-stored-procedure-with-output –

+0

wenn Sie haben Ärger einfach hier posten –

Verwandte Themen