追加/制作表格问题! [英] Append / Make Table questions!

查看:74
本文介绍了追加/制作表格问题!的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

你好


花了我早上的搜索解决方案,我需要做什么,我有点卡在哪个方向。


这是场景 - 我有一个数据库,其中包含客户端信息(tblClient)及其约会信息(tbl1stAppointment,tbl2ndAppointment等)。

A客户端可以根据需要多次访问服务。这是问题,因为目前某些客户端存在重复记录。考虑到解决这个问题,我偶然发现了append / make table查询。我认为附加查询是正确的解决方案...


我的想法是这样的 - 我可以将客户记录(或可能选择字段)移动到新创建的表(使用追加查询(然后是更新查询从现有位置删除记录/字段)来调用类似tblClosedCases的内容),这样当它再次将它们输入数据库时​​,它将防止重复和现有的ID号可以使用。


我不会发布我的桌子结构和东西,因为我只是在这里大声思考,希望有人可以让我朝着正确的方向前进。


非常感谢

Gareth

Hello

After spending my morning search for a solution to what I need to do, I am a little stuck on which direction to take.

Here is the scenario - I have a database that contains information on clients (tblClient) along with their appointment information (tbl1stAppointment, tbl2ndAppointment etc).
A client can access the service as many times as they like. This is the problem as currently there are duplicate records for some clients. Thinking of a way around this, I stumbled upon append/make table queries. I''m thinking append queries is the right solution though...

My thought is thus - could I move a clients record (or maybe select fields) to a newly created table (called something like tblClosedCases) using an append query (and then an update query to delete the record/fields from their existing place) so that when it comes to entering them into the database again, it will prevent a duplicate and the existing ID number can be used.

I won''t post my table structures and stuff just yet as I''m kind of just thinking out loud here and am hoping someone can set me in the right direction.

Many thanks
Gareth

推荐答案

根据客户端不会有主键ID解决了这个问题?
Wouldn''t a Primary Key based on the Client ID solve this problem?


它已经是主键了!问题是当客户重新参与时,您不能覆盖现有的详细信息(例如,当他们被引用时,GP详细信息,他们被引用的地方,评论等),因为显然先前的信息将丢失。当然,名称,性别,DOB,地址(通常)都是相同的。


我不知道是否有一个更简单的解决方案来满足我的需求,但我愿意听取人们的建议,明显比我知道得多。
It already is a Primary Key! The problem is when a client re-engages, you can''t overwrite the existing details (such as when they were referred, GP details, where they were referred from, comments etc) as obviously the previous information will be lost. Of course, the name, gender, DOB, address (usually) are all the same.

I don''t know if there''s a simpler solution for what I need but I''m willing to listen to suggestions from people clearly a lot more knowledgable than I.


我们需要查看更多详细信息,例如表/字段名称&数据类型,关系,样本数据等
We will need to see more details such as Table/Field Names & Data Types, Relationships, sample data, etc.


这篇关于追加/制作表格问题!的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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