Why do I keep getting "Invalid object name 'DB.Table' " when using database explorer ?

113 views (last 30 days)
Andrei Hirtie
Andrei Hirtie on 20 Jan 2017
Answered: Jonathan Kwang on 23 Jan 2017
Hey there I`d appreciate if someone could point what the problem is - I`m using the db. explorer app from MatLab and I`m connected to an SQL server from which I`m trying to extract some data of interest. I can see all the tables from inside this DB however when I want to access some tables I get the "Invalid object name 'DB.Table' when using database explorer" error. Reason given by MatLab is The selected schema name in Database Explorer is incorrect. and the solution is You must select the appropriate schema name in Database Explorer using the Catalog/Schema address bar above the table columns tree.
However, what does this mean I don`t know. I`m navigating to Server\Measurement\Tables\The_Table_I_Want. When I click this table it expands allright showing it's structure but when I click any of the columns I want to retrieve I get the error mentioned.
If I go on the Database Browser and click on the '>' button I have a 'INFORMATION_SCHEMA' folder. If I go on this it is the schema of my database and i can actually see what's in it, however the schema is not what I`m interested in.
I`d appreciate any help. Thanks.

Answers (1)

Jonathan Kwang
Jonathan Kwang on 23 Jan 2017
This error could be occurring because you are selecting a table that is not permitted to your user account.
Please ensure you have the permission to access the column for the table. The default user is "dbo". Make sure to select dbo. You will see the tables populated, that dbo allows to access.

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!