1 Reply Latest reply on Oct 11, 2018 4:44 PM by Patrick A Van Der Hyde

    Able to access pg_largeobject using pgAdmin4 but there is an exception when accessing the same using pgsql JDBC

    Mayur Khera

      I have a Tableau Server 2018.1.2 installed on one of our AWS instances. I took the necessary steps to give relevant permissions to the 'readonly' user on pg_largeobject schema for the workgroup database. I used the following query to do so:

       

      GRANT SELECT ON ALL TABLES IN SCHEMA pg_catalog TO readonly;

       

      I am able to run a SELECT query on pg_largeobject after this by logging in as 'readonly' user using pgAdmin4. However, when I run  a query using JDBC from my Java Web Application, I get an error: permission denied for large object 22451.

       

      Below is the query I am trying to run:

      select  loid, c.name || '.twb' || case when substring(data from 1 for 2) =  'PK' then 'x' else '' end filename, content, data,  (select sum(length(data)) from pg_largeobject where pg_largeobject.loid =  repository_data.content) size from  workbooks c inner join repository_data  on (repository_data.tracking_id =c.reduced_data_id)  inner join projects on (c.project_id = projects.id) inner join sites on  (sites.id = projects.site_id) inner join pg_largeobject on  (repository_data.content = pg_largeobject.loid)

       

      The same process worked well for Tableau 10.x and also Tableau Server 2018.1.1. Would appreciate any help from anyone who might have any pointers.

       

      Thanks,

      Janak Mehta