Using RLS enables POSTGRESQL db in the Quick Sight DataSource

I have a table with RLS activated in the POSTGRESQL, I am looking to use this table to create analysis in the Quicksight. As i can pass the parameter for the RLS via SET only, and Quicksight is showing syntax error. How can i process further?

Hi @ashikrahman

Quick Sight can’t run SET. Custom SQL in Quick Sight must be a single SELECT statement (no SET, no multi-statements, no stored procs).

Create an RLS rules dataset that maps users/groups to allowed keys, then apply it to your dataset. This is fully supported and maintained by AWS (note the new Rules dataset flag added in 2025).

Please refer to the below documentations this might be helpful for you.

2 Likes