Subsonic 执行存储过程,执行sql语句

//存储过程

SubSonic.Schema.StoredProcedure sp = new SubSonic.Schema.StoredProcedure("fenye");
sp.Command.AddParameter("@Id""1");
sp.Command.AddOutputParameter("@Id");
sp.Command.AddReturnParameter();
sp.Execute();
var ov = sp.Command.OutputValues;

 

//sql语句

var sql = new CodingHorror("SELECT * FROM Users WHERE Id > @p1", 0);
sql.ExecuteTypedList<DAL.User>();

 

你可能感兴趣的:(sql语句)