[ 
https://issues.apache.org/jira/browse/HIVE-13290?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Hari Sankar Sivarama Subramaniyan updated HIVE-13290:
-----------------------------------------------------
    Description: 
SUPPORT for the following statements
{code}
CREATE TABLE product 
  ( 
     product_id        INTEGER, 
     product_vendor_id INTEGER, 
     PRIMARY KEY (product_id), 
     CONSTRAINT product_fk_1 FOREIGN KEY (product_vendor_id) REFERENCES 
vendor(vendor_id) 
  ); 

CREATE TABLE vendor 
  ( 
     vendor_id INTEGER, 
     PRIMARY KEY (vendor_id) 
  ); 
{code}

In the above syntax, [CONSTRAINT constraint-Name] is optional. If this is not 
specified by the user, we will use system generated constraint name. For the 
purpose of simplicity, we will allow only CONSTRAINT option for foreign keys.

> Support primary keys/foreign keys constraint as part of create table command 
> in Hive
> ------------------------------------------------------------------------------------
>
>                 Key: HIVE-13290
>                 URL: https://issues.apache.org/jira/browse/HIVE-13290
>             Project: Hive
>          Issue Type: Sub-task
>          Components: CBO, Logical Optimizer
>            Reporter: Hari Sankar Sivarama Subramaniyan
>            Assignee: Hari Sankar Sivarama Subramaniyan
>         Attachments: HIVE-13290.1.patch, HIVE-13290.2.patch
>
>
> SUPPORT for the following statements
> {code}
> CREATE TABLE product 
>   ( 
>      product_id        INTEGER, 
>      product_vendor_id INTEGER, 
>      PRIMARY KEY (product_id), 
>      CONSTRAINT product_fk_1 FOREIGN KEY (product_vendor_id) REFERENCES 
> vendor(vendor_id) 
>   ); 
> CREATE TABLE vendor 
>   ( 
>      vendor_id INTEGER, 
>      PRIMARY KEY (vendor_id) 
>   ); 
> {code}
> In the above syntax, [CONSTRAINT constraint-Name] is optional. If this is not 
> specified by the user, we will use system generated constraint name. For the 
> purpose of simplicity, we will allow only CONSTRAINT option for foreign keys.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to