> For the complete documentation index, see [llms.txt](https://docs.datapancake.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.datapancake.com/guides/how-to-guides-script-builder/admin-guides/how-to-grant-account-level-privileges-to-datapancake.md).

# How to Grant Account Level Privileges to DataPancake

Build a script to grant DataPancake the necessary account-level and Cortex AI privileges required for scanning and schema discovery the Cortex AI assisted data dictionary builder.

### 1. Navigate to the admin page

![](https://ajeuwbhvhr.cloudimg.io/https://colony-recorder.s3.amazonaws.com/files/2025-05-19/89188d00-21ab-4232-a513-85ea03baeb33/ascreenshot.jpeg?tl_px=0,189\&br_px=1376,959\&force_format=jpeg\&q=100\&width=1120.0\&wat=1\&wat_opacity=1\&wat_gravity=northwest\&wat_url=https://colony-recorder.s3.amazonaws.com/images/watermarks/FB923C_standard.png\&wat_pad=82,382)

### 2. (Optional) Change the app database name

The default is DATAPANCAKE

![](https://ajeuwbhvhr.cloudimg.io/https://colony-recorder.s3.amazonaws.com/files/2025-05-12/0efa1689-8f02-4ba2-bb56-25efd97a09dc/ascreenshot.jpeg?tl_px=0,0\&br_px=1376,769\&force_format=jpeg\&q=100\&width=1120.0\&wat=1\&wat_opacity=1\&wat_gravity=northwest\&wat_url=https://colony-recorder.s3.amazonaws.com/images/watermarks/FB923C_standard.png\&wat_pad=413,221)

### 3. Enter the role name used to install data pancake

![](https://ajeuwbhvhr.cloudimg.io/https://colony-recorder.s3.amazonaws.com/files/2025-05-12/dc4ee1e4-2257-4e82-956d-d69ef634944e/ascreenshot.jpeg?tl_px=164,7\&br_px=1541,776\&force_format=jpeg\&q=100\&width=1120.0\&wat=1\&wat_opacity=1\&wat_gravity=northwest\&wat_url=https://colony-recorder.s3.amazonaws.com/images/watermarks/FB923C_standard.png\&wat_pad=563,277)

### 4. Enter a role name with privileges to create a warehouse

![](https://ajeuwbhvhr.cloudimg.io/https://colony-recorder.s3.amazonaws.com/files/2025-05-12/295b8765-64e7-41f8-9e46-ac68b4e990f8/ascreenshot.jpeg?tl_px=194,80\&br_px=1571,849\&force_format=jpeg\&q=100\&width=1120.0\&wat=1\&wat_opacity=1\&wat_gravity=northwest\&wat_url=https://colony-recorder.s3.amazonaws.com/images/watermarks/FB923C_standard.png\&wat_pad=524,277)

### 6. Enter the warehouse name used to execute the generated script

![](https://ajeuwbhvhr.cloudimg.io/https://colony-recorder.s3.amazonaws.com/files/2025-05-12/8c24c2ce-3eb2-4b00-adbe-27babbd7ce61/ascreenshot.jpeg?tl_px=164,158\&br_px=1541,927\&force_format=jpeg\&q=100\&width=1120.0\&wat=1\&wat_opacity=1\&wat_gravity=northwest\&wat_url=https://colony-recorder.s3.amazonaws.com/images/watermarks/FB923C_standard.png\&wat_pad=563,277)

### 7. Ensure the "Initialize Application Database Privileges" checkbox is checked

If you are ever re-running this script, you can uncheck this box to skip this step.

![](https://ajeuwbhvhr.cloudimg.io/https://colony-recorder.s3.amazonaws.com/files/2025-05-12/19e18130-9b3e-4270-93db-63086324bb71/ascreenshot.jpeg?tl_px=55,189\&br_px=1432,959\&force_format=jpeg\&q=100\&width=1120.0\&wat=1\&wat_opacity=1\&wat_gravity=northwest\&wat_url=https://colony-recorder.s3.amazonaws.com/images/watermarks/FB923C_standard.png\&wat_pad=524,291)

### 8. Scroll to the bottom and click "Generate Script"

![](https://ajeuwbhvhr.cloudimg.io/https://colony-recorder.s3.amazonaws.com/files/2025-05-12/ae0261d2-230b-42b8-a660-3a11e676879b/ascreenshot.jpeg?tl_px=0,189\&br_px=1376,959\&force_format=jpeg\&q=100\&width=1120.0\&wat=1\&wat_opacity=1\&wat_gravity=northwest\&wat_url=https://colony-recorder.s3.amazonaws.com/images/watermarks/FB923C_standard.png\&wat_pad=405,448)

### 9. Copy the script

![](https://ajeuwbhvhr.cloudimg.io/https://colony-recorder.s3.amazonaws.com/files/2025-05-12/5196b227-3115-45e5-9d68-c54ac685728c/ascreenshot.jpeg?tl_px=544,0\&br_px=1920,769\&force_format=jpeg\&q=100\&width=1120.0\&wat=1\&wat_opacity=1\&wat_gravity=northwest\&wat_url=https://colony-recorder.s3.amazonaws.com/images/watermarks/FB923C_standard.png\&wat_pad=987,168)

### 10. Open a new Snowflake SQL file and paste the script

Ensure you have a role and warehouse selected to execute the SQL file

![](https://colony-recorder.s3.amazonaws.com/files/2025-05-12/6de63b03-2077-4c3a-96c4-9436ef0dbfde/stack_animation.webp)

### 11. Review & Execute the script

Use the blue dropdown arrow at the top right and click "Run All"

![](https://ajeuwbhvhr.cloudimg.io/https://colony-recorder.s3.amazonaws.com/files/2025-05-12/46027b34-667d-4a21-acaa-4b22453ee679/ascreenshot.jpeg?tl_px=164,0\&br_px=1541,769\&force_format=jpeg\&q=100\&width=1120.0\&wat=1\&wat_opacity=1\&wat_gravity=northwest\&wat_url=https://colony-recorder.s3.amazonaws.com/images/watermarks/FB923C_standard.png\&wat_pad=1047,60)

### 12. Ensure successful execution by examining the call result column in the result set

<figure><img src="https://201309747-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FkX4nSXGvrFIEggg2Drr1%2Fuploads%2F06aRl256tAKcgUSKZRFW%2Fimage.png?alt=media&amp;token=a65a1581-79d9-4107-8011-c8c0529ce503" alt=""><figcaption></figcaption></figure>


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.datapancake.com/guides/how-to-guides-script-builder/admin-guides/how-to-grant-account-level-privileges-to-datapancake.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
