incubator-cassandra-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Aleksey Yeschenko <alek...@yeschenko.com>
Subject Re: COPY command not working
Date Fri, 01 Mar 2013 17:42:02 GMT
This is being caused by stricter validation in 1.2.2.
I opened a ticket https://issues.apache.org/jira/browse/CASSANDRA-5305 - thanks for the report.


-- 
AY


On Friday, March 1, 2013 at 19:08 PM, Pushkar Prasad wrote:

> Hi,
> 
> I am unable to run the COPY command in cassandra. Here is the ColumnFamily
> that I am using
> 
> CREATE TABLE ap_perf_sample_data_tbl(
> ap_mac varchar,
> ap_proto int,
> stime int,
> ap_active_status int,
> bytes_from_dev int,
> bytes_to_dev int,
> location_id int,
> num_assocs int,
> num_data_pkts int,
> num_retry_pkts int,
> throughput_from_ap int,
> throughput_to_ap int,
> throughput_total_ap int,
> time_spent_on_channel int,
> time_util_by_ap int,
> PRIMARY KEY ((ap_mac, ap_proto), stime) 
> 
> I'm trying to use the COPY command in cqlsh as follows:
> 
> cqlsh:performance_data> copy ap_perf_sample_data_tbl (ap_mac, ap_proto ,
> stime, location_id, num_data_pkts, num_retry_pkts, num_assocs,
> time_util_by_ap, time_spent_on_channel, throughput_to_ap,
> throughput_from_ap, throughput_total_ap, bytes_to_dev, bytes_from_dev
> ,ap_active_status) from '/tmp/top';
> 
> Bad Request: Invalid STRING constant (1) for ap_proto of type int
> Aborting import at record #0 (line 1).
> Previously-inserted values still present.
> 0 rows imported in 0.008 seconds.
> cqlsh:performance_data>
> 
> 
> Contents of "/tmp/top" 
> 
> 00:00:01:00:01:00,1,1359532800,1,6002166,312781,10,845100,9045000,259143,241
> 011,52835,186318,5413799,10
> 00:00:02:00:02:00,1,1359532800,2,6002166,312781,10,845100,9045000,259143,241
> 011,52835,186318,5413799,10
> 00:00:03:00:03:00,1,1359532800,3,6002166,312781,10,845100,9045000,259143,241
> 011,52835,186318,5413799,10
> 00:00:04:00:04:00,1,1359532800,4,6002166,312781,10,845100,9045000,259143,241
> 011,52835,186318,5413799,10
> 
> 
> Following is the version information.
> 
> [root@localhost ~]# cqlsh Connected to Test Cluster at localhost:9160.
> [cqlsh 2.3.0 | Cassandra 1.2.2 | CQL spec 3.0.0 | Thrift protocol 19.35.0]
> Use HELP for help.
> 
> 
> 
> Any clues as to why this may happen will be appreciated.
> 
> Thanks
> Pushkar Prasad
> 
> 
> 



Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message