All Apps and Add-ons

How to retrieve list of foreign tables in splunk db connect?

vanheer
Explorer

Hi,

I'm trying to query tables from postgres database. All tables there are under Foreign tables and nothing under tables. when I use db connect it get the schema name but it couldn't get the list of tables.

How can I access the foreign tables using db connect?

Labels (2)
0 Karma
1 Solution

VatsalJagani
SplunkTrust
SplunkTrust

Try running the below query in the DB connect:

 

select * from information_schema.foreign_tables

OR 

select * from information_schema.tables

 

View solution in original post

0 Karma

VatsalJagani
SplunkTrust
SplunkTrust

Try running the below query in the DB connect:

 

select * from information_schema.foreign_tables

OR 

select * from information_schema.tables

 

0 Karma

vanheer
Explorer

Thanks @VatsalJagani it works fine.

Actually it was a stupid question, but it was going on the opposite direction all the time and couldn't think good 🙂

0 Karma
Get Updates on the Splunk Community!

Index This | I’m short for "configuration file.” What am I?

May 2024 Edition Hayyy Splunk Education Enthusiasts and the Eternally Curious!  We’re back with a Special ...

New Articles from Academic Learning Partners, Help Expand Lantern’s Use Case Library, ...

Splunk Lantern is a Splunk customer success center that provides advice from Splunk experts on valuable data ...

Your Guide to SPL2 at .conf24!

So, you’re headed to .conf24? You’re in for a good time. Las Vegas weather is just *chef’s kiss* beautiful in ...