Not showing partition tables

Hello Team,

I am using Helical Insight application 5.1 GA and i have connected with Postgres database, while creating the metadata it is listing my PARTITION tables as well which are 6000+ in numbers and because of that BROWSER is hanging up and becoming unresponsive. I want that in metadata page it shows only TABLES present under my schema and not partition tables. How to solve this?

Thank You,
Snow.

Hello,

In order to avoid listing PARTITION TABLES, please follow below steps :

  1. Open the file postgresql.efwd file present in the location “..\hi\hi-repository\System\Admin\DbConfig
  2. In this file you will see this below SQL present which is responsible for listing the tables at the metadata page
<![CDATA[      
                       SELECT table_name as tables,table_schema as schemas, table_catalog as catalogs FROM information_schema.tables
WHERE table_schema = ${schemas} and table_catalog=${catalog}
UNION
SELECT matviewname as tables,${schemas} as schemas, ${catalog} as catalogs FROM pg_matviews where schemaname = ${schemas}

                ]]>

Now we have to replace this above SQL with this new below SQL

<![CDATA[
                SELECT table_name as tables,table_schema as schemas, table_catalog as catalogs FROM information_schema.tables
WHERE table_schema = ${schemas} and table_catalog=${catalog}
                                AND table_name NOT IN (
    SELECT table_name
    FROM information_schema.tables
WHERE  table_schema = ${schemas} AND table_catalog = ${catalog}
      AND table_name IN (select inhrelid::regclass::text from pg_inherits)
  )
UNION
SELECT matviewname as tables,${schemas} as schemas, ${catalog} as catalogs FROM pg_matviews where schemaname = ${schemas}
                ]]>
  1. Save this file. Then login into Helical Insight in a private browser (make sure you close all existing sessions) to avoid browser cache. Then login at home page as hiadmin and from the home page delete the cache. Now try creating fresh metadata and you will not see any partition tables.

Thank You,
Helical Insight.