cancel
Showing results for 
Search instead for 
Did you mean: 
Warehousing & Analytics
Engage in discussions on data warehousing, analytics, and BI solutions within the Databricks Community. Share insights, tips, and best practices for leveraging data for informed decision-making.
cancel
Showing results for 
Search instead for 
Did you mean: 

Error Message when Creating Catalog

Billycheng
New Contributor

I am very new to DB. Can someone show me how to resolve the error below please? 

Assistant
 
 

The error message you're encountering indicates that when creating a catalog, you need to specify a managed storage location for it. This is a requirement in order to provide a storage location where the catalog's data will reside. Based on the information provided in your error message and the related documentation passages, you'll have to add the MANAGED LOCATION clause to your CREATE CATALOG statement, specifying a storage location in the format required.

Assuming you have a storage location ready, your corrected SQL code should look something like this:

sql
CREATE CATALOG IF NOT EXISTS billy_cheng_dawd_13May2024
MANAGED LOCATION 'abfss://<container-name>@<storage-account>.dfs.core.windows.net/<path-to-directory>';

USE CATALOG billy_cheng_dawd_13May2024;

CREATE SCHEMA IF NOT EXISTS dawd_v2;

In this code:

  • Replace <container-name>, <storage-account>, and <path-to-directory> with your actual storage container name, storage account name, and the path to the directory within the storage account, respectively. This storage will be used to manage and store the data for your catalog billy_cheng_dawd_13May2024.
4 REPLIES 4

niklaus
New Contributor II

Warehousing & Analytics play a pivotal role in modern business strategies, enabling organizations to store, manage, and analyze vast amounts of data. By leveraging advanced analytics tools cable and internet packages directv within warehouse environments, companies gain valuable insights, driving informed decision-making and enhancing operational efficiency, ultimately fostering growth and competitiveness.

Cary
Databricks Employee
Databricks Employee

It looks like a couple of things.   You may not have setup the abfss path as an external location.  You may not have added the location to the IAM controls for the container to the Databricks Connector. I am assuming that you are a workspace and catalog admin and have the correct permissions to create a catalog.

Yeshwanth
Databricks Employee
Databricks Employee

@Billycheng Good day!

To correct your SQL code and specify the managed storage location, you should replace the placeholders in the MANAGED LOCATION clause with your actual storage container name, storage account name, and the path to the directory within the storage account.

Here is an example of how you might modify your SQL code:

sql
CREATE CATALOG IF NOT EXISTS billy_cheng_dawd_13May2024
MANAGED LOCATION 'abfss://myContainer@myStorageAccount.dfs.core.windows.net/myDirectory';

USE CATALOG billy_cheng_dawd_13May2024;

CREATE SCHEMA IF NOT EXISTS dawd_v2;

In this example, myContainer is the name of your storage container, myStorageAccount is the name of your storage account, and myDirectory is the path to the directory within the storage account.
Please replace myContainer, myStorageAccount, and myDirectory with your actual storage container name, storage account name, and the path to the directory within the storage account, respectively.

Good reads: 

1. https://docs.databricks.com/en/connect/unity-catalog/managed-storage.html

2. https://docs.databricks.com/en/data-governance/unity-catalog/get-started.html

Please let us know if you have any questions or concerns.

Kind regards,

Yeshwanth

dkushari
Databricks Employee
Databricks Employee

If your root metastore bucket is not configured then you need to provide a managed location when creating a catalog in UC. https://docs.databricks.com/en/data-governance/unity-catalog/create-catalogs.html#create-a-catalog

 

dkushari_0-1716488757021.png

 

Connect with Databricks Users in Your Area

Join a Regional User Group to connect with local Databricks users. Events will be happening in your city, and you won’t want to miss the chance to attend and share knowledge.

If there isn’t a group near you, start one and help create a community that brings people together.

Request a New Group