New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Error: Database does not have any tables ... but it does #35
Comments
Hm, thats strange. Are you running pgAdmin locally or inside vagrant ? |
I'm running pgAdmin on my Windows Host machine, and connecting to the IP address of the Vagrant machine, exactly the same as I'm trying to do with pgweb. |
The Linux version running on the VM does exactly the same thing:
shows this:
|
Ok, seems like something is broken. Im going to test with vagrant to replicate the issue. |
The Vagrant box is running Ubuntu 14.04 LTS and Postgres 9.3 installed from the package manager. |
Just tested on vagrant box. Works fine. Can you run the following on your host machine:
And when connection is established, this:
Output should include all available tables in the database. |
Running Here is the query shown in the query log when I run
|
Im not sure what could cause this. Can you try to run pgweb with url from this gist: https://gist.github.com/sosedoff/20f1799215d35e2bfc32 |
I am able to run pgweb with that URL, from both my Windows machine and my Vagrant VM. |
I can post my postgresql config files somewhere if that helps. |
Yes please, i would like to see your |
Same here. Its because of: Line 14 in bf2df4e
Also; Why do we need tables to start the UI? Maybe you want to run |
@Jellyfrog The default schema is named |
Here are my config files: https://gist.github.com/kohenkatz/d53eeafa27e33fb623ed Other than adding two access lines in |
I tried turning off SSL on the server so that I could use WireShark on the connection to see if that shows anything. (This requires adding I'll see if that turns up anything interesting. |
@kohenkatz any luck ? |
I am able to reproduce the problem when I use an user that doesn't have permissions to see the 'public' schema.
Either way, @sosedoff I think it would be better to rewrite the query for schemas and tables, in order to list tables from all available schemas, not only from public (which is not always accessible, as it looks to be the issue here). If you already have this on the roadmap or maybe I am doing something wrong, then I apologize, I just stumbled upon this here and had very little time to look around so far ;) |
@fijosh This makes sense, although its not a quick fix and requires a few evenings of work. |
@fijosh Actually, you are right that running that exact command gives no output. The query only returns results when I run it as the However, it doesn't seem that granting access to the
What I found that I had to do in the end is explicitly set |
9.x has |
@sosedoff agreed on that, definitely not a small fix, but it will bring so much value to this tool :) |
Closing this since i was not able to reproduce the issue on most common setups (local and remote). |
I am trying to connect to a database running on another machine on the network. When I connect with pgAdmin it works perfectly, so I know that it should work.
I try to run pgweb with the following command:
Here is the error that it returns:
I turned on connection logging on the server, and here is what I got:
When I run that query (
SELECT table_name FROM information_schema.tables WHERE table_schema = 'public' ORDER BY table_schema,table_name;
) in pgAdmin, it returns the list of tables, as expected.What is causing this?
Is there any other information that can be used to troubleshoot?
The text was updated successfully, but these errors were encountered: