26. Row-Level Security (RLS)
The Pune manager should see only Pune data, the Nashik manager only Nashik – and the report is the same. That is Row-Level Security. In this module we look at static and dynamic RLS, testing and the important rules. This topic comes up a lot in interviews.
Pune च्या manager ला फक्त Pune चा data दिसला पाहिजे, Nashik च्या manager ला फक्त Nashik चा – आणि report एकच. हेच Row-Level Security. या module मध्ये static आणि dynamic RLS, testing आणि महत्त्वाचे नियम बघू. Interview मध्ये हा topic खूप वेळा येतो.
Pune के manager को सिर्फ़ Pune का data दिखना चाहिए, Nashik के manager को सिर्फ़ Nashik का – और report एक ही. यही Row-Level Security है. इस module में static और dynamic RLS, testing और ज़रूरी नियम देखेंगे. Interview में यह topic बहुत बार आता है.
What you will learn in this module
- What RLS is and why it is needed
- Creating static roles
- Dynamic RLS with USERPRINCIPALNAME and a security table
- Testing roles in Desktop and assigning members in the Service
Live story: Shraddha must see only Nashik
Suppose the same report goes to six city managers. Shraddha (Nashik) must see only Nashik. Ravindra (Pune) only Pune. Rani, the state head, sees all. Six copies of the report would be a maintenance nightmare. This chapter builds row-level security once, tests it with View as, and assigns it in the Service.
All numbers in this story are fictional practice data.
Live story: Shraddha ला फक्त Nashik दिसलं पाहिजे
समजा तोच report सहा city managers ना जातो. Shraddha (Nashik) ला फक्त Nashik दिसलं पाहिजे. Ravindra (Pune) ला फक्त Pune. Rani, state head, ना सगळं. Report च्या सहा copies म्हणजे maintenance चं दुःस्वप्न. हा chapter row-level security एकदाच बनवतो, View as ने test करतो, आणि Service मध्ये assign करतो.
या story मधले सगळे आकडे काल्पनिक practice data आहेत.
Live story: Shraddha को सिर्फ़ Nashik दिखना चाहिए
मान लीजिए वही report छह city managers को जाती है. Shraddha (Nashik) को सिर्फ़ Nashik दिखना चाहिए. Ravindra (Pune) को सिर्फ़ Pune. Rani, state head, को सब. Report की छह copies maintenance का सिरदर्द होंगी. यह chapter row-level security एक बार बनाता है, View as से test करता है, और Service में assign करता है.
इस story के सारे आँकड़े काल्पनिक practice data हैं.
Concepts in this chapter
- 26.1What is RLS?
- 26.2Static RLS
- 26.3Dynamic RLS With USERPRINCIPALNAME
- 26.4Testing RLS
- 26.5Important Rules
- 26.6Object-Level Security
Review and practice
The chapter recap is at the end of the last concept page.
Ravi Sir's Cards: 9 revision, interview and comparison cards for this chapter · मराठी cards