From issues-return-7573-archive-asf-public=cust-asf.ponee.io@phoenix.apache.org Wed Jun 12 01:47:02 2019 Return-Path: X-Original-To: archive-asf-public@cust-asf.ponee.io Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [207.244.88.153]) by mx-eu-01.ponee.io (Postfix) with SMTP id 02E7F180627 for ; Wed, 12 Jun 2019 03:47:01 +0200 (CEST) Received: (qmail 51492 invoked by uid 500); 12 Jun 2019 01:47:01 -0000 Mailing-List: contact issues-help@phoenix.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@phoenix.apache.org Delivered-To: mailing list issues@phoenix.apache.org Received: (qmail 51472 invoked by uid 99); 12 Jun 2019 01:47:01 -0000 Received: from mailrelay1-us-west.apache.org (HELO mailrelay1-us-west.apache.org) (209.188.14.139) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 12 Jun 2019 01:47:01 +0000 Received: from jira-lw-us.apache.org (unknown [207.244.88.139]) by mailrelay1-us-west.apache.org (ASF Mail Server at mailrelay1-us-west.apache.org) with ESMTP id 8332EE2D55 for ; Wed, 12 Jun 2019 01:47:00 +0000 (UTC) Received: from jira-lw-us.apache.org (localhost [127.0.0.1]) by jira-lw-us.apache.org (ASF Mail Server at jira-lw-us.apache.org) with ESMTP id 41D422463B for ; Wed, 12 Jun 2019 01:47:00 +0000 (UTC) Date: Wed, 12 Jun 2019 01:47:00 +0000 (UTC) From: "Toshihiro Suzuki (JIRA)" To: issues@phoenix.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Commented] (PHOENIX-5209) Cannot add non-PK column to table when the last PK column is of type VARBINARY or ARRAY MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 [ https://issues.apache.org/jira/browse/PHOENIX-5209?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16861663#comment-16861663 ] Toshihiro Suzuki commented on PHOENIX-5209: ------------------------------------------- I forgot that 4.x-HBase-1.x branches are compiled in Java7. I attached a new patch for the 4.x-HBase-1.5 branch. If it's okay, I will attach patches for the other branches. > Cannot add non-PK column to table when the last PK column is of type VARBINARY or ARRAY > --------------------------------------------------------------------------------------- > > Key: PHOENIX-5209 > URL: https://issues.apache.org/jira/browse/PHOENIX-5209 > Project: Phoenix > Issue Type: Bug > Reporter: Toshihiro Suzuki > Assignee: Toshihiro Suzuki > Priority: Major > Attachments: PHOENIX-5209.4.x-HBase-1.3.v1.patch, PHOENIX-5209.4.x-HBase-1.4.v1.patch, PHOENIX-5209.4.x-HBase-1.5.v1.patch, PHOENIX-5209.4.x-HBase-1.5.v2.patch, PHOENIX-5209.master.v1.patch, PHOENIX-5209.master.v2.patch > > Time Spent: 1h 10m > Remaining Estimate: 0h > > Let's see we have the following table: > {code} > CREATE TABLE tbl (id VARBINARY PRIMARY KEY, col1 INTEGER) > {code} > The type of the primary key of this table is VARBINARY. > And when we alter this table to add a new column: > {code} > ALTER TABLE tbl ADD col2 INTEGER > {code} > we are facing the following error: > {code} > java.sql.SQLException: ERROR 1015 (42J04): Cannot add column to table when the last PK column is of type VARBINARY or ARRAY. columnName=ID > {code} > I think we should be able to do it without the above error because we don't try to add a PK column. -- This message was sent by Atlassian JIRA (v7.6.3#76005)