关于Access:ASP可将视图当存储过程用,ASP.NET怎么写法?
如题
谢谢!
------解决方案--------------------OleDbConnection conn = new OleDbConnection(conntionstring);
OleDbCommand cmd = conn.CreateCommand();
cmd.CommandText = "select * from table where ID=@id ";
cmd.CommandType = CommandType.StoredProcedure;
cmd.Parameters.Add( "@id ", OleDbType.Integer).Value = 100;
conn.Open();
........
------解决方案--------------------不好意思,发错了.
OleDbConnection conn = new OleDbConnection(conntionstring);
OleDbCommand cmd = conn.CreateCommand();
cmd.CommandText = "查询名 ";
cmd.CommandType = CommandType.StoredProcedure;
cmd.Parameters.Add( "@id ", OleDbType.Integer).Value = 100;
conn.Open();
........