Help with Inner Join in Access

xc405

Board Regular
Joined
Jul 2, 2011
Messages
54
I am very new to Access and SQL so apologies.
The database is in SQL Server Management and I am able to use this query just fine to join all the tables:
Code:
SELECT *

FROM FracFocusRegistry.dbo.RegistryUpload

INNER JOIN FracFocusRegistry.dbo.RegistryUploadPurpose on RegistryUpload.pKey = RegistryUploadPurpose.pKeyRegistryUpload

INNER JOIN FracFocusRegistry.dbo.RegistryUploadIngredients on RegistryUploadPurpose.pKey = RegistryUploadIngredients.pKeyPurpose

I created an Access file which links to the SQL Server database using the ODBC option and I am able to view the 3 tables in separate tabs but the query no longer works. I get an error "Cannot find file ...FracFocusRegistry.dbo" when I run this query:
Code:
SELECT *

FROM (FracFocusRegistry.dbo.RegistryUpload

INNER JOIN FracFocusRegistry.dbo.RegistryUploadPurpose on RegistryUpload.pKey = RegistryUploadPurpose.pKeyRegistryUpload)

INNER JOIN FracFocusRegistry.dbo.RegistryUploadIngredients on RegistryUploadPurpose.pKey = RegistryUploadIngredients.pKeyPurpose

Hopefuly someone can help me with my problem, thanks in advance.
 

Excel Facts

Show numbers in thousands?
Use a custom number format of #,##0,K. Each comma after the final 0 will divide the displayed number by another thousand
In case you don't get an answer soon, here's my guess (I confess to being mostly ignorant of MySql or SQL server).
I'm assuming you copied a sql server sql statement and dumped it into an Access query. If so, it will never work because of the multiple dots (.) in your table reference. The dot is the delimiter between table and field (tblName.FieldName) in Access. If you can open the table in datasheet view from Access, go to query design and attempt to recreate the query using the UI. You may have to give the table and/or field names aliases for Access to work with it.
Sorry if I've missed the mark.
 
Last edited:
Upvote 0
Yes Sir lol copy and paste! I'm trying to recreate it using the query wizard but so far no success.
 
Upvote 0
I'm not sure that will help you if you need alias names.
 
Upvote 0
Upvote 0

Forum statistics

Threads
1,223,268
Messages
6,171,100
Members
452,379
Latest member
IainTru

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top