访问导入 - 在原始数据外添加字段 [英] Access Import - Adding Fields Outside the Raw Data

查看:117
本文介绍了访问导入 - 在原始数据外添加字段的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有每日文件需要附加到同一个Access表中。我需要将文件名和日期/时间添加到我导入的每个每日文件的每个记录的末尾(...所以我们可以区分记录的时间和文件的来源)。



问题:如何在导入时将文件名和导入日期/时间添加到每条记录的末尾?注意:我会将每日文件附加到同一个表中。

I have daily files that need to be appended to the same Access table. I need to add the file name and date/time to the end of each record of each daily file I import(...so we can distinguish the records as to when and which file they came from).

Question: How do I add the File Name and the Import Date/Time to the end of each record when I import? Note: I will be append the daily files to the same table.

推荐答案

我猜想没有聪明的方法可以做到这一点。所以你要做以下事情



首先,你需要桌子上的列。每条记录都需要一个名称和时间戳。每个都可以为空。



导入将导入新记录。



导入后进行更新在名称和时间戳为空的所有记录上,您使用文件中的数据。列为空的事实允许您查找正确的记录。
I would guess there is no clever way to do this. So you do the following

First of course you need the columns on the table itself. Each record needs a name and timestamp. Each is nullable.

The import will import the new records.

After the import do an update on all records where the name and timestamp are null an you use the data from the file. The fact that columns are null allow you to find the correct records.


这篇关于访问导入 - 在原始数据外添加字段的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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