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 922687F30 for ; Thu, 11 Aug 2011 03:50:20 +0000 (UTC) Received: (qmail 73430 invoked by uid 500); 11 Aug 2011 03:50:19 -0000 Delivered-To: apmail-cassandra-commits-archive@cassandra.apache.org Received: (qmail 72862 invoked by uid 500); 11 Aug 2011 03:50:04 -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 72801 invoked by uid 99); 11 Aug 2011 03:49:50 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 11 Aug 2011 03:49:50 +0000 X-ASF-Spam-Status: No, hits=-2000.8 required=5.0 tests=ALL_TRUSTED,RP_MATCHES_RCVD X-Spam-Check-By: apache.org Received: from [140.211.11.116] (HELO hel.zones.apache.org) (140.211.11.116) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 11 Aug 2011 03:49:47 +0000 Received: from hel.zones.apache.org (hel.zones.apache.org [140.211.11.116]) by hel.zones.apache.org (Postfix) with ESMTP id 5DFA6B6361 for ; Thu, 11 Aug 2011 03:49:27 +0000 (UTC) Date: Thu, 11 Aug 2011 03:49:27 +0000 (UTC) From: "Jonathan Ellis (JIRA)" To: commits@cassandra.apache.org Message-ID: <1924931676.26622.1313034567381.JavaMail.tomcat@hel.zones.apache.org> In-Reply-To: <1773446756.26596.1313034328144.JavaMail.tomcat@hel.zones.apache.org> Subject: [jira] [Assigned] (CASSANDRA-3016) CQL: double and float types do not seem to work properly 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-3016?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Jonathan Ellis reassigned CASSANDRA-3016: ----------------------------------------- Assignee: Tyler Hobbs I think we just need to teach cql.py the new-in-0.8.1 types. (CASSANDRA-2530) > CQL: double and float types do not seem to work properly > -------------------------------------------------------- > > Key: CASSANDRA-3016 > URL: https://issues.apache.org/jira/browse/CASSANDRA-3016 > Project: Cassandra > Issue Type: Bug > Reporter: Matt Hollingsworth > Assignee: Tyler Hobbs > > Was asked to make this from the mailing list by Jonathan Ellis. > I'm just getting started with CQL, and decided to do a simple test create/insert/select thing to check that everything was working. Most everything seems to work, but it appears that double/floats do not work properly. Here's what I did: > test.cql > -------------------------- > CREATE KEYSPACE test with strategy_class = 'SimpleStrategy' and strategy_options:replication_factor=1; > USE test; > CREATE COLUMNFAMILY testvals ( > key varchar PRIMARY KEY, > value float > ); > INSERT INTO testvals (key,value) VALUES ('k1',341.32355); > SELECT key, value FROM testvals; > -------------------------- > The output is this: > cqlsh localhost < scripts/test.cql > key | value | > k1 | @uU-B??? | > Same thing happens when I do value double. I also tried to do this from the python driver, gives the same weirdness: > In [2]: import cql > In [3]: con = cql.connect("localhost",keyspace="test") > In [4]: cursor = con.cursor() > In [5]: cursor.execute("SELECT * from testvals") > Out[5]: True > In [6]: for r in cursor: print r > ...: > [u'k1', '?\xf8\x00\x00\x00\x00\x00\x00'] -- This message is automatically generated by JIRA. For more information on JIRA, see: http://www.atlassian.com/software/jira