Where should relationships be created?

L

lpierce819

I am trying to clarify where the prefered location is for relationships. I
am working as a contract employee to "cleanup" a database created by someone
else. All relationships have been created using queries. Are queries the
correct place the create realtionships. Basically no relationships between
the tables were created and most of the tables have not had a primary key set.

I have always thought and perhaps I am incorrect the the proper place to
create relationships is between tables and to use query relationships as
additional no primary relationship. Is this incorrect? Thank you in advance
for your assistance.
 
K

KARL DEWEY

See post by ThomasAJ and responses 10/24/2009
Where to define Relationships - FE or BE?
 
F

Fred

Karl,

I think the OP was asking about table level vs. queries, not FE vs. BE.

- - - -

Dear, Lpierce,


I don't know the best/official way, but I create them at the table level and
refine/specialize/modify them at the query level as needed.
 
G

Gina Whipp

lpierce819,

I have never used Queries to create relationships as the Queries include
tables. I have only used Tables when creating relationships. Now, that
being said, there might be legitimate reasons to use queries, I just can't
hink of one. I should also note that tables can have a PK (Primary Key)
and/or FK (foreign Key) but do not have to have both. Personally, I like
all my tables to have a PK whether I use it or not is another long story.

If you need help determining which tables should have what type of Key, you
can post table names with what you think may be the FK and/or PK and we can
further assist.

--
Gina Whipp

"I feel I have been denied critical, need to know, information!" - Tremors
II

http://www.regina-whipp.com/index_files/TipList.htm
 
F

Fred

Gina,

Did you mean that:

- you never use a query as one side of a relationship? or

- you never create relationships in the query design screen?


Thanx

Fred
 
G

Gina Whipp

Fred,

After REreading my reply I see where you came up with your question. I
meant I have never used a query as one side of a relationship. However,
that does not mean there may not be a legitimate reason for doing so, just
that I have never done it.

However your second question... You cannot *create* a relationship in the
Query Design Grid. You can use preexisting relationships *created* in the
Relationship Diagram Window. OR did I misunderstand your second question?

--
Gina Whipp

"I feel I have been denied critical, need to know, information!" - Tremors
II

http://www.regina-whipp.com/index_files/TipList.htm
 
R

Rick Brandt

Gina,

Did you mean that:

- you never use a query as one side of a relationship? or

- you never create relationships in the query design screen?

The lines between tables and queries that you see in the query designer
are not "relationships". They are "joins".
 
F

Fred

Yeah, but it is because Fred is trying to learn from your expertise, not
commenting on the the thoroughness of your answer.

And would still like to know the answer. :)

Thanks

fred
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top