主题:  查询的问题

ryonick

职务:普通成员
等级:2
金币:1.0
发贴:317
#12002/11/13 0:32:41
<%
connstr="DBQ="+server.mappath("new.mdb")+";DefaultDir=;DRIVER={Microsoft Access Driver (*.mdb)};"
set conn=server.createobject("ADODB.CONNECTION")
set rs=server.createobject("adodb.recordset")
    
    conn.open connstr

sql="select * from new where new like '%"&request("keyword)&"%' order by id desc"
rs.open sql,conn,1,2
%>
我使用该语句查询
怎么老会显示Microsoft VBScript 编译器错误 错误 '800a0408'

无效字符

/p/search.asp, 行8

sql="select * from new where new like '%"&request("keyword)&"%' order by id desc"
-------------------------------------------------------------^



5D荣誉版主

职务:普通成员
等级:1
金币:10.0
发贴:271
#22002/11/13 8:28:39
sql="select * from new where new like '%" & request("keyword") & "%' order by id desc"