error in bulk loading

2015-03-24 Thread Rahul Bhardwaj
Hi all,

I need to import a csv file to a table using copy command, but file
contains carriage returns which causing me problem in doing so, Is there
any way in cassandra to solve this



Regards:
Rahul

-- 

Follow IndiaMART.com http://www.indiamart.com for latest updates on this 
and more: https://plus.google.com/+indiamart 
https://www.facebook.com/IndiaMART https://twitter.com/IndiaMART Mobile 
Channel: 
https://itunes.apple.com/WebObjects/MZStore.woa/wa/viewSoftware?id=668561641mt=8
 
https://play.google.com/store/apps/details?id=com.indiamart.m 
http://m.indiamart.com/
https://www.youtube.com/watch?v=DzORNbeSXN8list=PL2o4J51MqpL0mbue6kzDa6eymLVUXtlR1index=2
Watch how IndiaMART Maximiser helped Mr. Khanna expand his business. kyunki 
Kaam 
Yahin Banta Hai 
https://www.youtube.com/watch?v=Q9fZ5ILY3w8feature=youtu.be!!!


RE: error in bulk loading

2015-03-24 Thread Caraballo, Rafael
Not sure if this will help, but I have had issues with windows file in Unix 
before and this has worked for me…

To remove the ^M characters at the end of all lines in vi, use:

:%s/^V^M//g

The ^v is a CONTROL-V character and ^m is a CONTROL-M. When you type this, it 
will look like this:

:%s/^M//g

Rafael

From: Tyler Hobbs [mailto:ty...@datastax.com]
Sent: Tuesday, March 24, 2015 5:55 PM
To: user@cassandra.apache.org
Subject: Re: error in bulk loading


On Tue, Mar 24, 2015 at 5:30 AM, Rahul Bhardwaj 
rahul.bhard...@indiamart.commailto:rahul.bhard...@indiamart.com wrote:
I need to import a csv file to a table using copy command, but file contains 
carriage returns which causing me problem in doing so, Is there any way in 
cassandra to solve this

You can surround the field with double-quotes to handle this (or change the 
quote character with the QUOTE option for COPY).

--
Tyler Hobbs
DataStaxhttp://datastax.com/


This E-mail and any of its attachments may contain Time Warner Cable 
proprietary information, which is privileged, confidential, or subject to 
copyright belonging to Time Warner Cable. This E-mail is intended solely for 
the use of the individual or entity to which it is addressed. If you are not 
the intended recipient of this E-mail, you are hereby notified that any 
dissemination, distribution, copying, or action taken in relation to the 
contents of and attachments to this E-mail is strictly prohibited and may be 
unlawful. If you have received this E-mail in error, please notify the sender 
immediately and permanently delete the original and any copy of this E-mail and 
any printout.


Re: error in bulk loading

2015-03-24 Thread Tyler Hobbs
On Tue, Mar 24, 2015 at 5:30 AM, Rahul Bhardwaj 
rahul.bhard...@indiamart.com wrote:

 I need to import a csv file to a table using copy command, but file
 contains carriage returns which causing me problem in doing so, Is there
 any way in cassandra to solve this


You can surround the field with double-quotes to handle this (or change the
quote character with the QUOTE option for COPY).

-- 
Tyler Hobbs
DataStax http://datastax.com/


Re: error while bulk loading using copy command

2015-01-29 Thread Eric Stevens
As the error implies, you cannot insert into counters tables, you can only
update them as increments or decrements (updating a counter that doesn't
exist will create it with the initial delta as if it had started at zero).

I would recommend this documentation which describes how to update
counters:
http://www.datastax.com/documentation/cql/3.0/cql/cql_using/use_counter_t.html

Also, just for clarification (because I had to Google it), lac
http://en.wikipedia.org/wiki/Lakh isn't a common unit where I'm from, by
18 lacs I assume you mean 1.8 million (1,800,000)?

On Wed, Jan 28, 2015 at 10:28 PM, Rahul Bhardwaj 
rahul.bhard...@indiamart.com wrote:

 Hi All,

 We need to upload 18 lacs rows into a table which consist columns with
 data type counter.

 on uploading using copy command , we are getting below error:

 *Bad Request: INSERT statement are not allowed on counter tables, use
 UPDATE instead*

 we need counter data type because after loading this data we want to use
 functionality of counter data type.

 Kindly help is there any way to do this.


 Regards:
 Rahul Bhardwaj


 Follow IndiaMART.com http://www.indiamart.com for latest updates on
 this and more: https://plus.google.com/+indiamart
 https://www.facebook.com/IndiaMART https://twitter.com/IndiaMART
 Mobile Channel:
 https://itunes.apple.com/WebObjects/MZStore.woa/wa/viewSoftware?id=668561641mt=8
 https://play.google.com/store/apps/details?id=com.indiamart.m
 http://m.indiamart.com/

 https://www.youtube.com/watch?v=DzORNbeSXN8list=PL2o4J51MqpL0mbue6kzDa6eymLVUXtlR1index=2
 Watch how Irrfan Khan gets his work done in no time on IndiaMART, kyunki Kaam
 Yahin Banta Hai https://www.youtube.com/watch?v=hmS4Afl2bNU!!!


Re: error while bulk loading using copy command

2015-01-29 Thread Rahul Bhardwaj
Thanks Eric..

yes 18 lacs implies 1.8 million.

On Thu, Jan 29, 2015 at 9:01 PM, Eric Stevens migh...@gmail.com wrote:

 As the error implies, you cannot insert into counters tables, you can only
 update them as increments or decrements (updating a counter that doesn't
 exist will create it with the initial delta as if it had started at zero).

 I would recommend this documentation which describes how to update
 counters:
 http://www.datastax.com/documentation/cql/3.0/cql/cql_using/use_counter_t.html

 Also, just for clarification (because I had to Google it), lac
 http://en.wikipedia.org/wiki/Lakh isn't a common unit where I'm from,
 by 18 lacs I assume you mean 1.8 million (1,800,000)?

 On Wed, Jan 28, 2015 at 10:28 PM, Rahul Bhardwaj 
 rahul.bhard...@indiamart.com wrote:

 Hi All,

 We need to upload 18 lacs rows into a table which consist columns with
 data type counter.

 on uploading using copy command , we are getting below error:

 *Bad Request: INSERT statement are not allowed on counter tables, use
 UPDATE instead*

 we need counter data type because after loading this data we want to use
 functionality of counter data type.

 Kindly help is there any way to do this.


 Regards:
 Rahul Bhardwaj


 Follow IndiaMART.com http://www.indiamart.com for latest updates on
 this and more: https://plus.google.com/+indiamart
 https://www.facebook.com/IndiaMART https://twitter.com/IndiaMART
 Mobile Channel:
 https://itunes.apple.com/WebObjects/MZStore.woa/wa/viewSoftware?id=668561641mt=8
 https://play.google.com/store/apps/details?id=com.indiamart.m
 http://m.indiamart.com/

 https://www.youtube.com/watch?v=DzORNbeSXN8list=PL2o4J51MqpL0mbue6kzDa6eymLVUXtlR1index=2
 Watch how Irrfan Khan gets his work done in no time on IndiaMART, kyunki Kaam
 Yahin Banta Hai https://www.youtube.com/watch?v=hmS4Afl2bNU!!!




-- 

Follow IndiaMART.com http://www.indiamart.com for latest updates on this 
and more: https://plus.google.com/+indiamart 
https://www.facebook.com/IndiaMART https://twitter.com/IndiaMART Mobile 
Channel: 
https://itunes.apple.com/WebObjects/MZStore.woa/wa/viewSoftware?id=668561641mt=8
 
https://play.google.com/store/apps/details?id=com.indiamart.m 
http://m.indiamart.com/
https://www.youtube.com/watch?v=DzORNbeSXN8list=PL2o4J51MqpL0mbue6kzDa6eymLVUXtlR1index=2
Watch how Irrfan Khan gets his work done in no time on IndiaMART, kyunki Kaam 
Yahin Banta Hai https://www.youtube.com/watch?v=hmS4Afl2bNU!!!


error while bulk loading using copy command

2015-01-28 Thread Rahul Bhardwaj
Hi All,

We need to upload 18 lacs rows into a table which consist columns with data
type counter.

on uploading using copy command , we are getting below error:

*Bad Request: INSERT statement are not allowed on counter tables, use
UPDATE instead*

we need counter data type because after loading this data we want to use
functionality of counter data type.

Kindly help is there any way to do this.


Regards:
Rahul Bhardwaj

-- 

Follow IndiaMART.com http://www.indiamart.com for latest updates on this 
and more: https://plus.google.com/+indiamart 
https://www.facebook.com/IndiaMART https://twitter.com/IndiaMART Mobile 
Channel: 
https://itunes.apple.com/WebObjects/MZStore.woa/wa/viewSoftware?id=668561641mt=8
 
https://play.google.com/store/apps/details?id=com.indiamart.m 
http://m.indiamart.com/
https://www.youtube.com/watch?v=DzORNbeSXN8list=PL2o4J51MqpL0mbue6kzDa6eymLVUXtlR1index=2
Watch how Irrfan Khan gets his work done in no time on IndiaMART, kyunki Kaam 
Yahin Banta Hai https://www.youtube.com/watch?v=hmS4Afl2bNU!!!