copy structure extended 命令示例

以下示例显示了 orders 表的结构,将扩展的结构复制到 temp 表中,浏览 temp 表,从temp 表中创建 backup 表并显示 backup 的结构。

close databases
open database (home(2) + 'data\testdata')
use orders  && opens orders table
clear
display structure
wait window 'structure of the orders table' nowait
copy structure extended to temp
use temp
wait window 'the temp table - 1 row per field in orders' nowait
browse
create backup from temp
use backup
display structure
wait window 'backup.dbf has the same structure as orders' nowait
use
delete file temp.dbf
delete file backup.dbf