关系。有没有人使用它们? [英] Relationships. Does anyone use them?

查看:57
本文介绍了关系。有没有人使用它们?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我很好奇你对建立关系的看法。


当我在Access中设计我的第一个应用程序时,我会去工具/关系和

设置关系。随着时间的推移,我会走进窗户,看看

关系意大利面....桌子/查询都在这里和那里之间有很多

关系线。


在第一个应用程序之后我没有做关系。如果我有查询,我会定义这种关系。
很多时候,当我创建一个新查询

并将两个表一起添加时,它会在两个表之间创建正确的关系。我相信这是因为使用了与

同名的外键。我不关心级联删除或级联更新或

关系类型,所以关系窗口是干净的表格。


如果我需要,我''将通过代码动态创建查询。再次,我设置了

的关系。我知道这些查询不是为了优化而编译的。

就像querydef但运行良好。


我的应用似乎没有受到任何关系的影响。速度很快

可以接受,结果一样。创建一个应用程序和不必要的设置关系就更多了......或者你相信应用程序

是否应该定义所有关系?


I''m curious about your opinion on setting relationships.

When I designed my first app in Access I''d go to Tools/Relationships and
set the relationships. Over time I''d go into the window and see
relationship spaghetti....tables/queries all overthe place with lots of
relationship lines between here and there.

After that first app I didn''t do relationships. If I had a query, I
defined the relationship. Many of the times when I create a new query
and add 2 tables together it creates the correct relationship between
the two tables. I believe this is due to using a foreign key with the
same name. I cared not about cascading deletes or cascading updates or
the type of relationship so the relationships window is clean of tables.

And if I need to, I''ll create a query on the fly via code. Again, I set
the relationships. I know these queries aren''t compiled for optimacy
like a querydef but operate well.

My apps don''t appear to suffer from no relationships. Speeds very
acceptable, the results the same. So is setting relationships just more
overhead in creating an app and unnecessary...or do you believe the app
should have all relationships defined?


推荐答案

salad< oi*@vinegar.com>在新闻中写道:Sow4g.7230
salad <oi*@vinegar.com> wrote in news:Sow4g.7230


BS2.6977

@ newsread1.news.pas.earthlink.net:
BS2.6977
@newsread1.news.pas.earthlink.net:
我很好奇你对设置关系的看法。

当我在Access中设计我的第一个应用程序时,我会去工具/关系并设置关系。随着时间的推移,我会走进窗户,看到
关系意大利面....桌子/查询都在这里和那里之间有很多
关系线。

在第一个应用程序之后,我没有做关系。如果我有查询,我确定了这种关系。很多时候,当我创建一个新查询并将两个表一起添加时,它会在两个表之间创建正确的关系。我相信这是因为使用了具有相同名称的外键。我不关心级联删除或级联更新或关系类型,所以关系窗口是干净的表格。

如果我需要,我会创建一个查询通过代码飞。再次,我设置了关系。我知道这些查询不是为了优化而编译的,而是像querydef一样运行良好。

我的应用程序似乎没有任何关系。速度非常可接受,结果相同。创建应用程序和不必要的设置关系只是更多的开销......或者你相信应用程序应该定义所有关系吗?
I''m curious about your opinion on setting relationships.

When I designed my first app in Access I''d go to Tools/Relationships and
set the relationships. Over time I''d go into the window and see
relationship spaghetti....tables/queries all overthe place with lots of
relationship lines between here and there.

After that first app I didn''t do relationships. If I had a query, I
defined the relationship. Many of the times when I create a new query
and add 2 tables together it creates the correct relationship between
the two tables. I believe this is due to using a foreign key with the
same name. I cared not about cascading deletes or cascading updates or
the type of relationship so the relationships window is clean of tables.

And if I need to, I''ll create a query on the fly via code. Again, I set
the relationships. I know these queries aren''t compiled for optimacy
like a querydef but operate well.

My apps don''t appear to suffer from no relationships. Speeds very
acceptable, the results the same. So is setting relationships just more
overhead in creating an app and unnecessary...or do you believe the app
should have all relationships defined?




关系是数据库!没有别的可说了。


这不是意见问题,也不是争论的议题。


- < br $>
Lyle Fairfield



Relationships are the Database! There is nothing else to say.

This is not a matter of opinion and it is not an item for debate.

--
Lyle Fairfield




salad写道:

salad wrote:
我很好奇你的关于设置关系的意见。
I''m curious about your opinion on setting relationships.




好​​吧,除非你写SP来强制执行你所有的参与规则,否则我认为* b $ b会认为*不执行RI与人际关系是一个PITA。 IMO,让你更方便地为你做这件事。



Well, unless you write SPs to enforce all your participation rules, I
would think *not* enforcing RI with relationships is a PITA. It''s much
easier, IMO, to have Access do it for you.


这篇关于关系。有没有人使用它们?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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