zwei1121

博客园 首页 新随笔 联系 订阅 管理

Foo((object)new object[]{ (object)"1", (object)"2" }));
string[] strings = new string[] { "Test1", "Test2", "Test3" };

var myList = new List<KeyValuePair<string, object>>();
Test(myList.ToArray());

 

db.ExecuteScalar<string>("exec P_GetCode @0,@1,@2,@3,@4,@5",);


using (var db = new Database("test"))
{
SqlParameter[] para = {
new SqlParameter("@m",SqlDbType.NVarChar),
new SqlParameter("@v",SqlDbType.NVarChar),
new SqlParameter("@o",SqlDbType.Int)
};
para[0].SqlValue = m;
para[1].SqlValue = c;
para[2].Direction = ParameterDirection.Output;
db.Execute(" EXEC test @0,@1,@2 OUTPUT", para);
o = int.Parse(para[2].Value.ToString());
}

 

 

var list= db.Fetch<student>("EXEC test @id", new { id = "1" });

posted on 2016-10-14 11:05  zwei  阅读(340)  评论(0编辑  收藏  举报