Query giving no results

lloydmav

Registered User.
Local time
Today, 04:01
Joined
Nov 15, 2002
Messages
75
I am almost a complete beginner when it comes to queries and am in need of help.

I have a number of tables all linked together like so:

'Product Master Table' contains Product ID (Autonumber field, primary key), this links to 'ProductBasicData1' table (Long Integer foriegn key).This table contains the foriegn key BasicData1 ID (Long Integer) which links to the table 'BasicData1' with the BasicData1 ID (Autonumber). So the ProductBasicData1 table is the link table between Product Master Table and BasicData one and its two foriegn keys I a joint primary key for this link table

I created a query so that I could bring back all the information from Master Table and BasicData1 table. But it will not bring back any results. If I create a query for just one of the tables with no links to another I get a result. So the problem is something to do with the relationships but I'm stuck

Someone please help if you can!
 
Post your original query.

RV
 
Here's the SQL for the query


SELECT [Product Material Master].[Product ID], [Basic data 1].[BasicData1 ID], [Basic data 1].[Product Type (eg Finished)], [Basic data 1].[Base unit of measure], [Basic data 1].[Material group], [Basic data 1].[Old material number], [Basic data 1].[Ext matl group], [Basic data 1].Division, [Basic data 1].[Lab/office], [Basic data 1].[Product Allocation], [Basic data 1].[Prod hierachy], [Basic data 1].[X-plant matl status], [Basic data 1].[Valid from], [Basic data 1].GenItemCatGroup, [Basic data 1].[Authorization group], [Basic data 1].[Matl grp pack]
FROM [Basic data 1] INNER JOIN ([Product Material Master] INNER JOIN ProductBasicData1 ON [Product Material Master].[Product ID] = ProductBasicData1.[Product ID]) ON ([Product Material Master].[BasicData1 ID] = [Basic data 1].[BasicData1 ID]) AND ([Basic data 1].[BasicData1 ID] = ProductBasicData1.[BasicData1 ID]);

thanks
 

Users who are viewing this thread

Back
Top Bottom