Return-Path: X-Original-To: apmail-cassandra-commits-archive@www.apache.org Delivered-To: apmail-cassandra-commits-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 0625819433 for ; Tue, 12 Apr 2016 01:58:26 +0000 (UTC) Received: (qmail 33246 invoked by uid 500); 12 Apr 2016 01:58:25 -0000 Delivered-To: apmail-cassandra-commits-archive@cassandra.apache.org Received: (qmail 33197 invoked by uid 500); 12 Apr 2016 01:58:25 -0000 Mailing-List: contact commits-help@cassandra.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@cassandra.apache.org Delivered-To: mailing list commits@cassandra.apache.org Received: (qmail 32947 invoked by uid 99); 12 Apr 2016 01:58:25 -0000 Received: from arcas.apache.org (HELO arcas) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 12 Apr 2016 01:58:25 +0000 Received: from arcas.apache.org (localhost [127.0.0.1]) by arcas (Postfix) with ESMTP id 7E3382C1F5C for ; Tue, 12 Apr 2016 01:58:25 +0000 (UTC) Date: Tue, 12 Apr 2016 01:58:25 +0000 (UTC) From: "Jeremiah Jordan (JIRA)" To: commits@cassandra.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Commented] (CASSANDRA-11549) cqlsh: COPY FROM ignores NULL values in conversion 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/CASSANDRA-11549?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15236431#comment-15236431 ] Jeremiah Jordan commented on CASSANDRA-11549: --------------------------------------------- This is a regression introduced in CASSANDRA-11053 > cqlsh: COPY FROM ignores NULL values in conversion > -------------------------------------------------- > > Key: CASSANDRA-11549 > URL: https://issues.apache.org/jira/browse/CASSANDRA-11549 > Project: Cassandra > Issue Type: Bug > Components: Tools > Reporter: Stefania > Assignee: Stefania > Fix For: 2.1.x, 2.2.x, 3.0.x, 3.x > > > COPY FROM fails to import empty values. > For example: > {code} > $ cat test.csv > a,10,20 > b,30, > c,50,60 > $ cqlsh > cqlsh> create keyspace if not exists test with replication = {'class': 'SimpleStrategy', 'replication_factor':1}; > cqlsh> create table if not exists test.test (t text primary key, i1 int, i2 int); > cqlsh> copy test.test (t,i1,i2) from 'test.csv'; > {code} > Imports: > {code} > select * from test.test"; > t | i1 | i2 > ---+----+---- > a | 10 | 20 > c | 50 | 60 > (2 rows) > {code} > and generates a {{ParseError - invalid literal for int() with base 10: '', given up without retries}} for the row with an empty value. > It should import the empty value as a {{null}} and there should be no error: > {code} > cqlsh> select * from test.test"; > t | i1 | i2 > ---+----+------ > a | 10 | 20 > c | 50 | 60 > b | 30 | null > (3 rows) > {code} -- This message was sent by Atlassian JIRA (v6.3.4#6332)