Microsoft JET Database Engine (0x80040E14)
<select name="type" class="form">
<%
dim id
id="旋转接头"
set sql=server.CreateObject("adodb.recordset")
sql.open "select * from pclass where select='"&id&"' order by time desc ",conn,1,1
do while not sql.EOF%>
<option value="<%=sql("type")%>"><%=sql("type")%></option>
<%
sql.movenext
loop
sql.close
set sql=nothing
%>
</select>
出现问题:
错误类型:
Microsoft JET Database Engine (0x80040E14)
语法错误。 在查询表达式 'select='旋转接头'' 中。
第 117 行
参考答案:select是保留的关键字,如果字段名是select,就用方括号给括起来.
sql.open "select * from pclass where [select]='"&id&"' order by time desc ",conn,1,1