473,323 Members | 1,570 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,323 software developers and data experts.

Many to Many query help!

Hello,

I have set up my database in access using many to many relationships (it's
the good ol' books and authors one again). I've actually extended it to
include other people who contribute in various ways to the books (e.g.
editors, illustrators etc), so there's more than one many to many
relationship there.

When there's an entry in all the tables relating to the book I want to view,
everything works fine (i.e. there's an author in the author table, an
illustrator in the illustrator table, an editor in the editor table) - my
join tables do their job and there's no problem.

However... when there's say no an illustrator in the illustrator table
relating to the book, I get nothing back at all from my query, no book
details or author.

When I do one to many joins usually changing the sql to use LEFT JOINs
instead of INNER JOINs does the trick, but when I try this here Access tells
me "Join Expression Not Supported".

Any help would be much appreciated. I can post the SQL if it helps.

Thanks,
Phil
Nov 13 '05 #1
1 2579
Phil W.,
The orthodox many-to-many involves three tables. Two of them are the
entities being joined and the third is a two column intersection entity
detailing the instances of the first two entities that are joined. Widget A
is a component of Widgets C, N & P and consists of Widgets B, F, & I, for
example. Brighter lights here with better memories can tell you why it is
considered bad practice to directly join more than one intersection entity
or to have more than two attributes in an intersection entity.
Were I able to design your schema I'd have Books, People & Contribution as
attributes of my intersection entity. That way I can list all my
permutations of a book, a person and the person's role in the book. Given
the four tables--Books, People, Role, & Intersection Entity--I can then
query this and find all the people with a role for a book, all the books a
person had a role in . . . and much more.

"Phil W" <yo******************@hotmail.com> wrote in message
news:41**********@mk-nntp-1.news.uk.worldonline.com...
Hello,

I have set up my database in access using many to many relationships (it's
the good ol' books and authors one again). I've actually extended it to
include other people who contribute in various ways to the books (e.g.
editors, illustrators etc), so there's more than one many to many
relationship there.

When there's an entry in all the tables relating to the book I want to
view,
everything works fine (i.e. there's an author in the author table, an
illustrator in the illustrator table, an editor in the editor table) - my
join tables do their job and there's no problem.

However... when there's say no an illustrator in the illustrator table
relating to the book, I get nothing back at all from my query, no book
details or author.

When I do one to many joins usually changing the sql to use LEFT JOINs
instead of INNER JOINs does the trick, but when I try this here Access
tells
me "Join Expression Not Supported".

Any help would be much appreciated. I can post the SQL if it helps.

Thanks,
Phil

Nov 13 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

5
by: jason | last post by:
I could sure use some conceptualization and query help with a Page Watch System I am building in Access 2000 and Asp. I need to cycle through databae and generate a compiliation query email that...
12
by: jason | last post by:
Access 2000: I have a customer-inventory table I need to loop through and compile a list of all the inventory items the customer is tracking. The problem I am finding is that a simple loop...
6
by: Christian | last post by:
HI, I have a function that is used to constrain a query: Select COl1, Col2 From MyTable WHERE col1 = ... AND col2 = ... And MyFunction(col1) = ... My problem is that MyFunction is executed...
0
by: B. Fongo | last post by:
I learned MySQL last year without putting it into action; that is why I face trouble in formulating my queries. Were it a test, then you would have passed it, because your queries did help me...
8
by: Greg | last post by:
Hello, I've to manage many 'table' (having same scheme) on the same server. And I ask myself what could be the best to do (and if you know, why) : Creating as many database (the name would...
3
by: OM | last post by:
How do I import excel data into 2 joined tables ? The data is fldDate, fldTruck, fldLitres, fldSpeedometer. fldDate goes in a table tblFuelHeader, and the rest goes in tblFuelDetail, with a...
3
by: Carmela | last post by:
Hello Readers, I am trying to update data on a form that is based on a query having a many-to-one-to-many relationship. I found this exciting link that seemed to have the solution for me: ...
5
by: Jean Christophe Avard | last post by:
Hi! I have a query that INNER JOIN's three other tables. All the relation are 1 to 1, except for one, where an Item can have more than one price. I have this query that work fine in MSDE Query...
6
by: OldBirdman | last post by:
I don't really know how to state this problem, as it doesn't make any sense to me. I have a simple "One-to-Many" query, and was updating the Many side. It quit working. I cannot make any changes...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
1
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.