database 如何将数据从 foxpro 数据库导出到 excel(.xls)?
声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow
原文地址: http://stackoverflow.com/questions/2281041/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me):
StackOverFlow
How can I export data from a foxpro database to excel(.xls)?
提问by ravirajsahu
I want to enter the data in FoxPro but save the data in .xls format.
我想在 FoxPro 中输入数据,但以 .xls 格式保存数据。
回答by Leom Burke
You can use EXPORT TO *FILENAME* TYPE XLS
您可以使用 EXPORT TO *FILENAME* TYPE XLS
回答by ravirajsahu
COPY TO is more flexible: FIELDS LIKE or FIELDS EXCEPT.
COPY TO 更灵活:FIELDS LIKE 或 FIELDS EXCEPT。
But do use XL5, for newer Excel 5 format. XLS creates XLS and users will be asked to change formats when they save with new Excel.
但是对于较新的 Excel 5 格式,请使用 XL5。XLS 创建 XLS,用户在使用新 Excel 保存时将被要求更改格式。
回答by DRapp
Additionally, you can use COPY TO and specify the specific fields and field sequence, something like
此外,您可以使用 COPY TO 并指定特定字段和字段序列,例如
COPY TO SomeFileName fields MyFld1, MyFld2, MyFld3 type XLS
回答by krishna
for exmple ossep12.dbf file
例如 ossep12.dbf 文件
COPY TO "c:\kbk.xls" NEXT 50000 FIELDS Ossep12.uniqueid,Ossep12.crmacct,Ossep12.billno,Ossep12.ll,Ossep12.bb,Ossep12.sc,Ossep12.st,Ossep12.os,Ossep12.bldt,Ossep12.classcode,Ossep12.acsubtype,Ossep12.name,Ossep12.add1,Ossep12.add2,Ossep12.add3,Ossep12.city,Ossep12.pin,Ossep12.inactdt,Ossep12.status,Ossep12.phone,Ossep12.exgcode,Ossep12.bldate,Ossep12.inactivedt TYPE XL5