注册 登录
编程论坛 ASP技术论坛

这是ASP代码,怎么写update这个?

uj8yh 发布于 2007-08-30 22:58, 706 次点击

<%@ Language=VBScript %>
<!--#include file="Connections/web.asp" -->
<HTML>
<HEAD>
<meta name="GENERATOR" Content="Microsoft Visual Studio .NET 7.1">
</HEAD>
<body>
<%
dim shuliang
dim bianhao

'从第一个页面中提取 数量 我用的是汉语拼音shuliang
shuliang=request.form("txtshuliang")
'从第一个页面中提取 编号 我用的是汉语拼音bianhao
bianhao=request("txtbianhao")

response.write("第一个页面传来的参数:数量: " &shuliang &",编号: "&bianhao)
%>
<%conn.execute "update kucun set 根据编号更新数据 的数量
<p>
</p>

1 回复
#2
天涯听雨2007-08-30 23:22
conn.execute("update kucun set shuliang="&shuliang&" where bianhao="&bianhao&"")

不知你的编号是什么数据类型,这里按了数字处理,如果是字符就是:

conn.execute("update kucun set shuliang="&shuliang&" where bianhao='"&bianhao&"'")
1