You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Aug 29, 2025. It is now read-only.
Repository navigation
This repository was archived by the owner on Aug 29, 2025. It is now read-only.
Query tab not available after connecting to Oracle #516
After connecting to a oracle db (screen grays, blue button says connected), I am unable to select the QUERY tab, and clicking it socialites no screen changes. It does not appear to register as a link because the mouse remains in its pointing state when hovering. Logs do not reveal anything notable. Postgres and sqllite connects work fine.
I don't see any errors on the log. One reason to be unable to open the Query panel (despite a successful connection) can be that the user doesn't have access to any tables in the database.
I can use the database just fine with Sql Developer. It is a large database, serveral TBs, not sure if that has anything to do with it. Does Falcon iterate through all of the schema to find tables?
Falcon runs the following query to get a list of tables:
SELECT*FROM user_all_tables
WHERE
table_name NOT LIKE'%$%'AND
(table_type IS NULLOR table_type <>'XMLTYPE') AND
(num_rows IS NULLOR num_rows >0) AND
secondary ='N'
Do you get a list of tables when you run the above query in SQL Developer?
It also runs a query to get a list of columns and data types (but, if I remember correctly, only after opening the query panel):
SELECTc.table_name,
c.column_name,
c.data_typeFROM
user_tab_columns c,
user_all_tables t
WHEREc.table_name=t.table_nameANDt.table_name NOT LIKE'%$%'AND
(t.table_type IS NULLORt.table_type<>'XMLTYPE') AND
(t.num_rows IS NULLORt.num_rows>0) ANDt.secondary='N'
Okay, this is starting to make sense. My database user has no tables, but I have grants to various schemas within the database that I write my queries against. Could something like the following be used instead?
SELECT*FROM all_all_tables
WHERE owner not in ('SYS', 'SYSTEM') and
table_name NOT LIKE'%$%'AND
(table_type IS NULLOR table_type <>'XMLTYPE') AND
(num_rows IS NULLOR num_rows >0) AND
secondary ='N'
I've tested the change you've proposed and it works for me too. But I'd also like to exclude tables owned by MDSYS. Otherwise the database overview is crowded with system tables.
Something like this works for me:
SELECT table_name FROM all_all_tables
WHERE
owner not in ('SYS', 'SYSTEM', 'MDSYS') and
table_name NOT LIKE'%$%'AND
(table_type IS NULLOR table_type <>'XMLTYPE') AND
(num_rows IS NULLOR num_rows >0) AND
secondary ='N'
And for the function schemas:
SELECTc.table_name,
c.column_name,
c.data_typeFROM
all_tab_columns c,
all_all_tables t
WHEREt.owner not in ('SYS', 'SYSTEM', 'MDSYS') andc.table_name=t.table_nameANDt.table_name NOT LIKE'%$%'AND
(t.table_type IS NULLORt.table_type<>'XMLTYPE') AND
(t.num_rows IS NULLORt.num_rows>0) ANDt.secondary='N'
I forked, tried the above, and did a build. It appeared to have solved the issue. Shall I do a PR?
PR #518 - I also had to concat the schema to the table name, otherwise not all queries work work. If you wouldn't mind editing the PR to also include MDSYS, I missed that inclusion.
Activity
n-riesco commentedon Aug 23, 2018
I don't see any errors on the log. One reason to be unable to open the Query panel (despite a successful connection) can be that the user doesn't have access to any tables in the database.
n-riesco commentedon Aug 23, 2018
Re #465
bkief commentedon Aug 23, 2018
I can use the database just fine with Sql Developer. It is a large database, serveral TBs, not sure if that has anything to do with it. Does Falcon iterate through all of the schema to find tables?
n-riesco commentedon Aug 23, 2018
Falcon runs the following query to get a list of tables:
Do you get a list of tables when you run the above query in SQL Developer?
It also runs a query to get a list of columns and data types (but, if I remember correctly, only after opening the query panel):
bkief commentedon Aug 23, 2018
Okay, this is starting to make sense. My database user has no tables, but I have grants to various schemas within the database that I write my queries against. Could something like the following be used instead?
bkief commentedon Aug 23, 2018
Oracle docs for reference
n-riesco commentedon Aug 23, 2018
I can't test this today, But I'll come back to you as soon as I do.
bkief commentedon Aug 23, 2018
I forked, tried the above, and did a build. It appeared to have solved the issue. Shall I do a PR?
n-riesco commentedon Aug 24, 2018
I've tested the change you've proposed and it works for me too. But I'd also like to exclude tables owned by
MDSYS. Otherwise the database overview is crowded with system tables.Something like this works for me:
And for the function
schemas:That'd be great! Thanks.
bkief commentedon Aug 27, 2018
PR #518 - I also had to concat the schema to the table name, otherwise not all queries work work. If you wouldn't mind editing the PR to also include MDSYS, I missed that inclusion.
oracle: show tables from other schemas (#518)
n-riesco commentedon Aug 29, 2018
Closed via #518