cancel
Showing results for 
Search instead for 
Did you mean: 
Community Platform Discussions
Connect with fellow community members to discuss general topics related to the Databricks platform, industry trends, and best practices. Share experiences, ask questions, and foster collaboration within the community.
cancel
Showing results for 
Search instead for 
Did you mean: 

Primary key and not null

Shree23
New Contributor III

Hi Expert,

 

how we can get primary key and not null and cluster index in table creation

%Sql

create table table1 values (id int , product char)

 

expected output

create table table1 values (id int  not null primary key, product char) and cluster index

 

 

4 REPLIES 4

Shree23
New Contributor III

it is giving error message   Dataanalysisexception:table constraint are only supported in unity catalog

Shree23
New Contributor III

Shree23
New Contributor III

Suggestion please 

Shree23
New Contributor III

sugggestion pls

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