CREATE CURSOR B表 (xh C(4),xm C(10),;
生产情况 C(20),;
数量 N(10,2))
CREATE CURSOR A表 (xh C(4),xm C(10),;
综合小时产出 N(10,2),;
达标小时产量 N(10,2),;
实际标准数量 N(10,2),;
工艺加工 N(10,2),;
纯手动加工 N(10,2))
INSERT INTO A表 VALUES("1001","张一",100,600,100,100,100)
INSERT INTO A表 VALUES("1002","李军",400,500,400,400,400)
SCAN
FOR i=3 TO FCOUNT("A表")
INSERT INTO B表 VALUES (;
EVALUATE("A表."+FIELD(1,"A表")),;
EVALUATE("A表."+FIELD(2,"A表")),;
FIELD(i,"A表"),;
EVALUATE("A表."+FIELD(i,"A表")))
ENDFOR
ENDSCAN
SELECT * FROM B表 ORDER BY 生产情况