程序代码:
CREATE CURSOR abc (bh C(15), rec I, abc C(1)) CREATE CURSOR tmp (bh C(15), rec I, abc C(1)) SELECT tmp APPEND FROM a.dbf REPLACE rec WITH RECNO(), abc WITH "a" ALL SELECT abc APPEND FROM DBF("tmp") SELECT tmp ZAP APPEND FROM b.dbf REPLACE rec WITH RECNO(), abc WITH "b" ALL SELECT abc APPEND FROM DBF("tmp") SELECT tmp ZAP APPEND FROM c.dbf REPLACE rec WITH RECNO(), abc WITH "c" ALL SELECT abc APPEND FROM DBF("tmp") CALCULATE MAX(rec) TO MaxRec MaxRec = LEN(TRANSFORM(MaxRec)) INDEX ON PADL(rec, MaxRec, "0") + abc TAG Recabc BROWSE