string sqlstr=”select * from tblname where name like :name”;
var paramvalue = string.Format("%{0}%", keyword);
object param = new { name= paramvalue };
var datas = conn.Query<TAXI_INFO>(sqlstr, param);
时间: 2024-10-14 11:56:49
string sqlstr=”select * from tblname where name like :name”;
var paramvalue = string.Format("%{0}%", keyword);
object param = new { name= paramvalue };
var datas = conn.Query<TAXI_INFO>(sqlstr, param);