如何将数据从.dbf文件追加到现有访问表 [英] How to append data from .dbf files to existing access table

查看:80
本文介绍了如何将数据从.dbf文件追加到现有访问表的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

大家好,

我有一个访问数据库,其中有四个表,这些表是通过将dbf文件中的数据剥离为四个目录而创建的. 1.手动将dbf文件导入数据库. 2.对每个dbf文件运行附加查询,并将数据附加到称为"newjunodata"的单个表中.然后,我运行四个宏以将数据剥离到表中.
我通过查看最后一条记录的日期来附加数据,然后从那天开始附加数据.我必须为每个dbf文件执行此操作.
谁能告诉我如何
a)导入dbf文件以进行访问
b)将所需的数据追加到表中

c)一次直接将dbf文件中的数据附加到访问表中

预先谢谢您

Hi guys,

I have an access database where I have four tables that I have created by stripping data from dbf files to four catagories.Th way i do it now is this.
1. Manually import the dbf files to the database.
2. Running append query for each dbf file and appending the data to single table called "newjunodata".Then I run four macros to strip the data to tables.

I append the data by looking at the date of the last record and then append the data from that day onwards.I have to do this for each dbf file.
Can anyone please tell me how to
a) Import the dbf files to access
b) Append the needed data to the table
OR
c) Directly append the data from the dbf files to the access table at once

Thank you in advance

推荐答案

如果您在Access中链接DBF文件而不是将其导入,则可以编写代码来从DBF文件中获取信息,而无需担心它是DBF格式.

这有点丑陋和蛮力,但是可以用.

哦……请谅解……我想您将链接到DBF副本,该副本存储在应用程序可以处理DBF来获取更新的位置.当您需要重新运行该应用程序时,只需将主DBF文件复制到该位置进行处理...所以我不建议直接链接到Clipper/xBase正在写入的主DBF文件.应用程序.
If you link the DBF file from within Access rather than importing it you could then write your code to grab the information from the DBF file without needing to worry that it is in DBF format.

It''s a bit ugly and brute force but it would work.

Oh ... please understand ... I''m thinking that you would link to a copy of the DBF that is stored in a location where the application could process the DBF to grab the updates. When you needed to re-run the application, you would simply copy the main DBF files into the location for processing ... so I wasn''t suggesting linking directly to your primary DBF files that are being written to by your Clipper/xBase application.


这篇关于如何将数据从.dbf文件追加到现有访问表的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆