数据库对比求助,小数点的问题
提问:我有一段代码,是对比两个数据库用的,两个数据库中的数值都是小数点后两位,但是执行这个程序后生成的库是小数点后一位,请帮忙看一下,代码如下:cd\tc
clea
close all
set safe off
km=spac(2)
set colo to 6+/g
@4,40 say '职工统筹对比程序' font '宋体',30
do whil .t.
@12,10 say '请输入工资数据库月份(如01):' font '楷体',16 get km font '楷体',18
read
if .not.file("zg"+"&km"+".dbf")
wait '无此数据库,重新输入!'
loop
@10,40 clea
else
exit
endi
endd
use zg&km
copy to zg
use zg
alte tabl zg add colu hj n(5,1) null
repl all hj with ylkj+ylbxkj+sybxkj
use tc&km
copy to tc
use tc
dele all for dwbh<>[004]
pack
alte tabl tc add colu tchj n(5,1) null
repl all tchj with yl+yil+sy
use
sele zg.gzdw,zg.ldhth,zg.xm,zg.yfgz,zg.hj,tc.dwbh,tc.tchj from zg,tc;
wher (zg.ldhth=tc.ldhth and zg.hj<>tc.tchj) into tabl xy1
sele zg.gzdw,zg.ldhth,zg.xm,zg.hj from zg;
wher zg.ldhth not in (sele tc.ldhth from tc) into tabl xy2
sele tc.dwbh,tc.ldhth,tc.xm,tc.tchj from tc;
wher tc.ldhth not in (sele zg.ldhth from zg) into tabl xy3
clos all
use xy1
*dele all for yfgz<=300
pack
brow titl "合同号一样,统筹扣款不等"
copy to xya&km
copy to xya&km xl5
use xy2
*dele all for yfgz<=300
pack
brow titl "工资库有,统筹库没有"
copy to xyb&km xl5
use xy3
brow titl "统筹库有,工资库没有"
*copy to "C:\Documents and Settings\zjl\桌面\xyc&km" xl5
copy to xyc&km xl5
clos all
set safe on
dele file tc.dbf
dele file zg.dbf
dele file xy?.dbf
dele file *.bak
retu