求大神解决ADO.net
"select book.id ID,ISBN ISBN,book.bookname '书名',author '作者',book.press '出版社',btype.typen from book join btype on book.btype=btype.id where book.sta=1 and author like '%@a%'";
SqlParameter[] p = { new SqlParameter("@a", zuozhe) };
我这句话用参数不行吗?
------解决方案--------------------where book.sta=1 and author like @a";
SqlParameter[] p = { new SqlParameter("@a", "%"+zuozhe+"%") };