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

Francis Chuang updated PHOENIX-3358:
------------------------------------
    Description: 
DDL statements are currently not supported in a transaction. To reproduce:

1. Create a transactional table: CREATE TABLE schemas(version varchar not null 
primary key) TRANSACTIONAL=true

2. Confirm it exists/is created: SELECT * FROM schemas

3. Begin transaction.

4. Insert into schemas: UPSERT INTO schemas (version) VALUES ('some-release')

5. Also create a table: CREATE TABLE test_table (id integer not null primary 
key)

6. Commit the transaction.

Once the transaction has been committed, I can see that test_table is created. 
However, the schemas table is missing the 'some-release' entry as the update 
was rolled back before the DDL statement was executed.


  was:
To reproduce:

1. Create a transactional table: CREATE TABLE schemas(version varchar not null 
primary key) TRANSACTIONAL=true

2. Confirm it exists/is created: SELECT * FROM schemas

3. Begin transaction.

4. Insert into schemas: UPSERT INTO schemas (version) VALUES ('some-release')

5. Also create a table: CREATE TABLE test_table (id integer not null primary 
key)

6. Commit the transaction.

Once the transaction has been committed, I can see that test_table is created. 
However, the schemas table is missing the 'some-release' entry.


     Issue Type: New Feature  (was: Bug)
        Summary: Support DDL statements in a transaction  (was: Weird behaviour 
when creating a table and upserting a row in a transaction.)

> Support DDL statements in a transaction
> ---------------------------------------
>
>                 Key: PHOENIX-3358
>                 URL: https://issues.apache.org/jira/browse/PHOENIX-3358
>             Project: Phoenix
>          Issue Type: New Feature
>    Affects Versions: 4.8.1
>         Environment: Phoenix 4.8.1 and HBase 1.2.3
>            Reporter: Francis Chuang
>
> DDL statements are currently not supported in a transaction. To reproduce:
> 1. Create a transactional table: CREATE TABLE schemas(version varchar not 
> null primary key) TRANSACTIONAL=true
> 2. Confirm it exists/is created: SELECT * FROM schemas
> 3. Begin transaction.
> 4. Insert into schemas: UPSERT INTO schemas (version) VALUES ('some-release')
> 5. Also create a table: CREATE TABLE test_table (id integer not null primary 
> key)
> 6. Commit the transaction.
> Once the transaction has been committed, I can see that test_table is 
> created. However, the schemas table is missing the 'some-release' entry as 
> the update was rolled back before the DDL statement was executed.



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

Reply via email to