# Using RLS enables POSTGRESQL db in the Quick DataSource

**URL:** <https://community.amazonquick.com/t/using-rls-enables-postgresql-db-in-the-quick-sight-datasource/49009>\
**Category:** Q&A\
**Tags:** error, data-source, Business-Intelligence-Engineer, quick-sight\
**Created:** [August 8, 2025, 1:02pm UTC](https://community.amazonquick.com/t/using-rls-enables-postgresql-db-in-the-quick-sight-datasource/49009 "2025-08-08T13:02:52Z")\
**Posts on this page:** 1\
**Showing post:** 2

<div class="post-metadata">

**Author:** ![Xclipse](https://d2orw1595917va.cloudfront.net/user_avatar/community.amazonquick.com/xclipse/32/20455_2.png) [@Xclipse](https://community.amazonquick.com/u/Xclipse)\
**Post date:** [August 9, 2025, 4:30pm UTC](https://community.amazonquick.com/t/using-rls-enables-postgresql-db-in-the-quick-sight-datasource/49009/2 "2025-08-09T16:30:25Z")

</div>

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.

> **[Using row-level security in Amazon Quick Suite - Amazon Quick Suite](https://docs.aws.amazon.com/quicksuite/latest/userguide/row-level-security.html)**
>
> Restrict access to datasets in Amazon Quick Suite by configuring row-level security.

> [@Action Required: Amazon Quick Sight Introduces Rules Datasets Flag for Row Level Security (RLS) Datasets](https://community.amazonquick.com/t/action-required-amazon-quicksight-introduces-rules-datasets-flag-for-row-level-security-rls-datasets/44650):
>
> Action Required: Amazon Quick Sight Introduces Rules Datasets Flag for Row Level Security (RLS) Datasets Summary: On March 31st 2025, Amazon Quick Sight launched a new feature that distinguishes between regular datasets and Rules datasets used for Row Level Security (RLS). This distinction for Rules dataset has been automatically flagged (both console and API) for RLS datasets applied to regular datasets before March 31 2025. This change requires action from dataset authors and admins when deal…

---

_[View the full topic](https://community.amazonquick.com/t/using-rls-enables-postgresql-db-in-the-quick-sight-datasource/49009)._
