| 网站首页 | 业界新闻 | 小组 | 威客 | 人才 | 下载频道 | 博客 | 代码贴 | 在线编程 | 编程论坛
欢迎加入我们,一同切磋技术
用户名:   
 
密 码:  
共有 424 人关注过本帖
标题:cz(i)=rs3("RZSL)-rs2("RZSL") 此处不计算
只看楼主 加入收藏
zhyl19701028
Rank: 1
等 级:新手上路
帖 子:14
专家分:0
注 册:2005-12-9
收藏
 问题点数:0 回复次数:0 
cz(i)=rs3("RZSL)-rs2("RZSL") 此处不计算

<%on error resume next
dim b(600),jh1(600),jingh(600),dbb(600),riqii(600),shij(600),dymcc(600),cengw(600),gany(600),youy(600),taoy(600),peiz(600),shiz(600),cds(600),beiz(600),qsz(600),cz(600)
dim riqi1,riqi2,pz,shz,js,bd1,bd2
bd1=request.form("db1")
bd2=request.form("db2")
y1=request.form("year1")
m1=request.form("month1")
d1=request.form("day1")
y2=request.form("year2")
m2=request.form("month2")
d2=request.form("day2")
riqi1=y1&m1&d1
riqi2=y2&m2&d2

%>
<%
'取井号
exec1="select distinct JH from YS_DBA02 where (DWDM like '3020046%' or DWDM like '3020047%') order by JH"
Set RS1= Server.CreateObject("ADODB.RecordSet")
rs1.Open exec1,Connc,1,2

i=0
do while not rs1.eof
if rs1("JH")<>"" and rs1("JH")<>"0" then
jh1(i)=rs1("JH").value
i=i+1
end if
rs1.movenext
loop
rs1.close
set rs1=nothing

numb=i


i=0
for j=0 to numb-1

exec2="select rzsl from YS_DBA02 where JH='"&jh1(j)&"' and (DWDM like '3020046%' or DWDM like '3020047%') and to_char(rq,'yyyymmdd')='"&riqi1&"'"
Set RS2= Server.CreateObject("ADODB.RecordSet")
rs2.Open exec2,Connc,1,2


exec3="select * from YS_DBA02 where JH='"&jh1(j)&"' and (DWDM like '3020046%' or DWDM like '3020047%') and to_char(rq,'yyyymmdd')='"&riqi2&"'"
Set RS3= Server.CreateObject("ADODB.RecordSet")
rs3.Open exec3,Connc,1,2


if not rs2.eof then
if not rs3.eof then
if Abs(rs3("RZSL")-rs2("RZSL"))>=bd1 and Abs(rs3("RZSL")-rs2("RZSL"))<bd2 then

i=i+1
jingh(i)=rs3("JH").value
dbb(i)=rs3("DWMC").value
riqii(i)=rs3("RQ").value
shij(i)=rs3("SCSJ").value
dymcc(i)=rs3("DYMC").value
cengw(i)=rs3("ZSCW").value
gany(i)=rs3("GXYL").value
youy(i)=rs3("YY").value
taoy(i)=rs3("TY").value
peiz(i)=rs3("RPZSL").value
shiz(i)=rs3("RZSL").value
cds(i)=rs3("PZCDS").value

if rs3("BZ").value<>"" then
beiz(i)=rs3("BZ").value
else
beiz(i)="无"
end if
qsz(i)=rs2("RZSL").value
cz(i)=rs3("RZSL)-rs2("RZSL") 此处不计算
end if
end if
end if
next
num=i
rs2.close
set rs2=nothing

rs3.close
set rs3=nothing

connc.close
set connc=nothing

%>

问题是:
cz(i)=rs3("RZSL)-rs2("RZSL") 此处不计算

这是用asp编的调用的是oracle数据库的number类型数据,我用类型转换函数CSng,formatnumber都不行。
请高手赐教

搜索更多相关主题的帖子: RZSL 
2005-12-09 16:34
快速回复:cz(i)=rs3("RZSL)-rs2("RZSL") 此处不计算
数据加载中...
 
   



关于我们 | 广告合作 | 编程中国 | 清除Cookies | TOP | 手机版

编程中国 版权所有,并保留所有权利。
Powered by Discuz, Processed in 0.107234 second(s), 8 queries.
Copyright©2004-2024, BCCN.NET, All Rights Reserved