分页:
上一页 1 [2] 3 4 5 6 7 8 9 下一页
set talk off
dimension unchange(3)
store "y" to ans,conti
use p2db
count to rno
r=1
do while conti="y"
clear
@ 2,2 say "修改第几条记录?" get r range 1,rno
read
go r
**********************found************************
scatter to unchange &&原句为store to unchange
@ 4,10 say "学号" get unchange(1) picture "999999"
@ 6,10 say "姓名" get unchange(2)
@ 8,10 say "所属z系" get unchange(3)
**********************found************************
read &&原句为store to unchange
@ 10, 2 say "准备存入你修改过的记录吗?(Y/N) " get ans
read
if upper(ans)="Y"
**********************found*************************
gather from unchange &&原句为append from to unchange
endif
@ 12,2 say "继续吗?" get conti
read
if upper(conti)<>"Y"
exit
endif
enddo
set talk on
return
(资料来源:Http://www.eastedu.com.cn)
第三题:给定程序MODI1.PRG的功能是:根据银行流水帐,同时修改银行和个人帐目。P3DB1为银行数据库,包括:支行号,名称,现有资金三个字段。P3DB2是个人数据库,包括:帐号,姓名,密码,余额四个字段。P3DB3是银行流水帐数据库,包括:帐号,支行号,日期,金额,存取,其中“存取”字段为逻辑型数据,存入其值为真T,取出其值为假F。另外,假设所有银行的初始资金为800000元,所有个人的初始资金为20000元,修改调试如下程序,使之能正确运行。
sele 1
use p3db1
replace all 现有资金with 800000
index on 支行号to id1
sele 2
use p3db2
replace all 余额with 20000
分页:
上一页 1 [2] 3 4 5 6 7 8 9 下一页