> ## Documentation Index
> Fetch the complete documentation index at: https://help.elationhealth.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Creating a Custom Database

You can create custom tables in Snowflake which will allow you to aggregate data from your master database to analyze and run reports. For more information check out the Snowflake documentation [https://docs.snowflake.com/en/sql-reference/sql/create-table](https://docs.snowflake.com/en/sql-reference/sql/create-table)

**Step 1: Create your database**

1. On the left hand navigation bar click on **Data > Database.**
2. On the top right hand corner click on the **Blue Database button**

<img src="https://mintcdn.com/elationhealth/aqLVKRo1Jpffmnwl/images/reference/snowflake-create-database-button.png?fit=max&auto=format&n=aqLVKRo1Jpffmnwl&q=85&s=b4dd3c6e5ea69a5bff6929219d4c47a8" alt="Snowflake Databases page showing 3 existing databases, with &#x22;Data > Databases&#x22; selected in the left nav and the &#x22;+ Database&#x22; button highlighted in the top right corner." data-og-width="3564" width="3564" data-og-height="1278" height="1278" data-path="images/reference/snowflake-create-database-button.png" data-optimize="true" data-opv="3" srcset="https://mintcdn.com/elationhealth/aqLVKRo1Jpffmnwl/images/reference/snowflake-create-database-button.png?w=280&fit=max&auto=format&n=aqLVKRo1Jpffmnwl&q=85&s=4c1cd600bfa152456003f4b5372befb5 280w, https://mintcdn.com/elationhealth/aqLVKRo1Jpffmnwl/images/reference/snowflake-create-database-button.png?w=560&fit=max&auto=format&n=aqLVKRo1Jpffmnwl&q=85&s=8646fc2c06b3555c673d4ed5715c7aa0 560w, https://mintcdn.com/elationhealth/aqLVKRo1Jpffmnwl/images/reference/snowflake-create-database-button.png?w=840&fit=max&auto=format&n=aqLVKRo1Jpffmnwl&q=85&s=7f54b89a343f4939ee02ae4a3b0d5196 840w, https://mintcdn.com/elationhealth/aqLVKRo1Jpffmnwl/images/reference/snowflake-create-database-button.png?w=1100&fit=max&auto=format&n=aqLVKRo1Jpffmnwl&q=85&s=6f6e509e121310b665fa707ef5312fe6 1100w, https://mintcdn.com/elationhealth/aqLVKRo1Jpffmnwl/images/reference/snowflake-create-database-button.png?w=1650&fit=max&auto=format&n=aqLVKRo1Jpffmnwl&q=85&s=785f7eeba577ea459ba4bbf1720b0d0e 1650w, https://mintcdn.com/elationhealth/aqLVKRo1Jpffmnwl/images/reference/snowflake-create-database-button.png?w=2500&fit=max&auto=format&n=aqLVKRo1Jpffmnwl&q=85&s=1003b77f7f1d5f2e2f99fdb3f752c731 2500w" />

**Step 2: Name your database and give it an optional comment**

<img src="https://mintcdn.com/elationhealth/aqLVKRo1Jpffmnwl/images/reference/snowflake-create-database-form.png?fit=max&auto=format&n=aqLVKRo1Jpffmnwl&q=85&s=3c0d2792b6d1e0a33b0c23ded6f8e4eb" alt="New Database dialog with Name field filled in as &#x22;MY_CUSTOM_DATABASE&#x22; and an optional Comment field partially showing appointment-related text, ready to click Create." width="1488" height="816" data-path="images/reference/snowflake-create-database-form.png" />

Click on the **Create button** once you are finished

**Step 3: Create a Schema**

1. Once the Database has been created you will see it on the left hand navigation along with your other database(s)
2. Click on the newly created Database then click on the blue Schema button on the top right hand side of the page.
3. Give your Schema a name and hit the create button

<img src="https://mintcdn.com/elationhealth/aqLVKRo1Jpffmnwl/images/reference/snowflake-create-schema-button.png?fit=max&auto=format&n=aqLVKRo1Jpffmnwl&q=85&s=12f44f73e3dec214f9ff7ced6ac38a65" alt="MY_CUSTOM_DATABASE selected in the left nav, showing the Database Details tab with ACCOUNTADMIN ownership. The &#x22;+ Schema&#x22; button is highlighted in the top right corner." width="3086" height="1000" data-path="images/reference/snowflake-create-schema-button.png" />

<img src="https://mintcdn.com/elationhealth/aqLVKRo1Jpffmnwl/images/reference/snowflake-create-schema-form.png?fit=max&auto=format&n=aqLVKRo1Jpffmnwl&q=85&s=a8f28d046fd82e641c350ed7d29a8676" alt="New Schema dialog in MY_CUSTOM_DATABASE, showing the Name field filled with &#x22;schema_name,&#x22; an optional Comment field, unchecked Managed access, and the Create button." width="1302" height="900" data-path="images/reference/snowflake-create-schema-form.png" />

**Step 4: Create your table**

1. Click on your newly created Schema
2. On the top right hand side corner of your screen click on the Blue Create button
3. Click on table then the appropriate option.

<img src="https://mintcdn.com/elationhealth/aqLVKRo1Jpffmnwl/images/reference/snowflake-create-table-menu.png?fit=max&auto=format&n=aqLVKRo1Jpffmnwl&q=85&s=19ab990508c7d3f0d23cb18f189a50ab" alt="SCHEMA_NAME selected in left nav under MY_CUSTOM_DATABASE, with the Create dropdown open showing Table, View, Stage, and other object type options." width="3088" height="1024" data-path="images/reference/snowflake-create-table-menu.png" />

For this example we will be choosing **Table** > As **Select**

This will take you to a new worksheet Pick your warehouse > Enter the criteria for you custom table > Click Create

<img src="https://mintcdn.com/elationhealth/c_0GuvXN24rkf1qg/images/reference/snowflake-worksheet-select-warehouse.png?fit=max&auto=format&n=c_0GuvXN24rkf1qg&q=85&s=080f1e30dc2a4ca82fe851cc9b5a4b80" alt="Snowflake worksheet showing USERADMIN role selected and SUPPORT_TESTING_WH warehouse selected (highlighted in red), with the Create Table button visible in the top right." width="2884" height="994" data-path="images/reference/snowflake-worksheet-select-warehouse.png" />

Enter the criteria for your new table and click Create Table

Make sure to reference your main hosted database and schema's full path

<img src="https://mintcdn.com/elationhealth/aqLVKRo1Jpffmnwl/images/reference/snowflake-create-table-criteria.png?fit=max&auto=format&n=aqLVKRo1Jpffmnwl&q=85&s=55a7099b07c833685b4645bdb3370a23" alt="SQL editor showing a CREATE TABLE AS SELECT statement for patient_id_to_appointmentas, with the SQL highlighted in red and the Create Table button highlighted in the top right corner." width="2878" height="610" data-path="images/reference/snowflake-create-table-criteria.png" />

You have successfully created a custom table

<img src="https://mintcdn.com/elationhealth/c_0GuvXN24rkf1qg/images/reference/snowflake-custom-table-results.png?fit=max&auto=format&n=c_0GuvXN24rkf1qg&q=85&s=fe1b00a5d6cedab901abc9ea04d76830" alt="Database object browser showing MY_CUSTOM_DATABASE > SCHEMA_NAME > Tables expanded, with PATIENT_ID_TO_APPOINTMENT table selected and highlighted inside a red callout box." data-og-width="658" width="658" data-og-height="712" height="712" data-path="images/reference/snowflake-custom-table-results.png" data-optimize="true" data-opv="3" srcset="https://mintcdn.com/elationhealth/c_0GuvXN24rkf1qg/images/reference/snowflake-custom-table-results.png?w=280&fit=max&auto=format&n=c_0GuvXN24rkf1qg&q=85&s=3e655625d03051d28b0420eb9c244ffd 280w, https://mintcdn.com/elationhealth/c_0GuvXN24rkf1qg/images/reference/snowflake-custom-table-results.png?w=560&fit=max&auto=format&n=c_0GuvXN24rkf1qg&q=85&s=5e9f7f2758c85913c6a5924bc104ad8d 560w, https://mintcdn.com/elationhealth/c_0GuvXN24rkf1qg/images/reference/snowflake-custom-table-results.png?w=840&fit=max&auto=format&n=c_0GuvXN24rkf1qg&q=85&s=c20ff52bc7db110873014c0605227e26 840w, https://mintcdn.com/elationhealth/c_0GuvXN24rkf1qg/images/reference/snowflake-custom-table-results.png?w=1100&fit=max&auto=format&n=c_0GuvXN24rkf1qg&q=85&s=4e3450ad6518ac825e5df2b0410a54a2 1100w, https://mintcdn.com/elationhealth/c_0GuvXN24rkf1qg/images/reference/snowflake-custom-table-results.png?w=1650&fit=max&auto=format&n=c_0GuvXN24rkf1qg&q=85&s=f851b6cd926ec1702c9091a6fd576ed5 1650w, https://mintcdn.com/elationhealth/c_0GuvXN24rkf1qg/images/reference/snowflake-custom-table-results.png?w=2500&fit=max&auto=format&n=c_0GuvXN24rkf1qg&q=85&s=3ac071221a6c3baddc36c996aa766993 2500w" />

If you have any questions please contact [Elation Support Portal](/articles/support-portal-introduction)
