蒲江中天置业有限公司:ASP高手来帮偶看看 急死人了

来源:百度文库 编辑:神马品牌网 时间:2024/05/08 17:21:31
Microsoft VBScript 运行时错误 错误 '800a01c2'
错误的参数个数或无效的参数属性值
/userinfo.asp,行 38

老出这个错,下面是代码

<title>用户信息</title>
<%
dim conn
dim strconn

set conn=server.CreateObject ("adodb.connection")
strconn="driver={sql server};server=(local);database=mydb;uid=sa;pwd="
conn.Open strconn
%>
<style type="text/css">
<!--
.STYLE1 {font-weight: bold}
.STYLE2 {
font-size: large;
font-weight: bold;
}
-->
</style>
<body>
<style type="text/css">
<!--
.STYLE1 {
font-size: large;
font-weight: bold;
}
body {
background-image: url(pic/background.jpg);
}
-->
</style>
<p class="STYLE2">用户的注册信息为:</p>
<p class="STYLE1"> </p>
<table width="482" border="1">
<tr>
<td width="160"> <p align="left"><strong>用户名:</strong></p>
</td>
<td width="306" height="30"><p align="left"><input name="username" type="text" id="username">
<%=conn("username")%></p></td>
</tr>
<tr>
<td> <p align="left"><strong>性别:</strong></p>
</td>
<td width="306" height="30"><p align="left"><input name="sex" type="text" id="sex">
<%=conn("sex")%></p></td>
</tr>
<tr>
<td><p><strong>出生日期:</strong></p>
</td>
<td width="306" height="30"><input name="birthday" type="text" id="birthday">
<%=conn("birthday")%></td>
</tr>
<tr>
<td> <p align="left"><strong>密码提示问题:</strong></p>
</td>
<td width="306" height="30"><input name="question" type="text" id="question">
<%=conn("question")%></td>
</tr>
<tr>
<td><p align="left"><strong>密码提示答案:</strong></p>
</td>
<td width="306" height="33"><input name="answer" type="text" id="answer">
<%=conn("answer")%></td>
</tr>
</table>
<p class="STYLE1"> </p>
</body>

没有SQL语句啊,你怎么检索数据库??

至少也要有个select * from table什么的吧,
天知道你那些字段在哪个表中哦

set conn=server.CreateObject ("adodb.connection")
strconn="driver={sql server};server=(local);database=mydb;uid=sa;pwd="
conn.Open strconn
下面添加SQL语句,再执行一下就行了。

只看到数据库连接,
没看到数据查询。
查询数据库的语句在哪?