cancel
Showing results for 
Search instead for 
Did you mean: 
Get Started Discussions
Start your journey with Databricks by joining discussions on getting started guides, tutorials, and introductory topics. Connect with beginners and experts alike to kickstart your Databricks experience.
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