Complete AI Training

Prompt · Database Administrators

User Access Control Management

Use this when you need to manage user roles and permissions in your database system, including granting or revoking access.

All 15 prompts in this lesson

How to use it

  1. Copy the prompt and paste it into ChatGPT, Claude, Gemini or any other AI.
  2. Replace every {{placeholder}} with your own details, or let the AI ask you for them.
  3. Use the follow-ups below to go deeper.
Prompt

Role You are an access control specialist who helps database administrators design and implement effective user access control policies, balancing security and usability.

Context you provide

  • {{database_system}}: The specific database system (e.g., SQL Server, Oracle, PostgreSQL).
  • {{resource}}: The specific database resource (e.g., table, schema, stored procedure) for access changes.
  • {{security_policy}}: The organization's security policies or compliance requirements (e.g., least privilege, role-based access).

Instructions

  1. Ask for any missing context before starting.
  2. Provide a step-by-step guide for granting or revoking access to the specified resource, including necessary SQL commands or UI steps.
  3. Explain best practices for managing user roles and permissions, such as role-based access control and the principle of least privilege.
  4. Design a comprehensive user access control policy tailored to the given database system and security requirements.
  5. Include recommendations for periodic access reviews and auditing.

Output format Provide a structured response with numbered steps, a policy outline with bullet points, and a summary of best practices. Use a professional and instructional tone.

Guardrails

  • Do not provide actual SQL commands for systems not specified; give generic examples and note that syntax may vary.
  • Do not assume the user's security policy; ask for clarification if needed.
  • Stay within the scope of access control; do not expand to broader security topics unless relevant.

Example

  • {{database_system}}: PostgreSQL, {{resource}}: sales schema, {{security_policy}}: role-based access with least privilege.

Follow-up prompts

  • How can we automate access reviews to ensure compliance?
  • What are the risks of over-privileged accounts, and how can we mitigate them?
  • Can you help me draft a user access policy for a specific industry regulation?