Skip to content

Instantly share code, notes, and snippets.

@VinACE
Last active March 10, 2017 07:41
Show Gist options
  • Select an option

  • Save VinACE/4a00d6f1133af25856ed1d83d4d8ff93 to your computer and use it in GitHub Desktop.

Select an option

Save VinACE/4a00d6f1133af25856ed1d83d4d8ff93 to your computer and use it in GitHub Desktop.
COPY keyspace.columnfamily1 (column1, column2,...) TO 'temp.csv';
COPY keyspace.columnfamily2 (column1, column2,...) FROM 'temp.csv';
seqno ,peopleid ,datetime ,activityid ,datasetfileid ,datasetid ,heartrate ,imuankleacc16gxaxis ,imuankleacc16gyaxis ,imuankleacc16gzaxis ,imuankleacc6gxaxis ,imuankleacc6gyaxis ,imuankleacc6gzaxis ,imuanklegyroxaxis ,imuanklegyroyaxis ,imuanklegyrozaxis ,imuanklemagxaxis ,imuanklemagyaxis ,imuanklemagzaxis ,imuankleori1 ,imuankleori2 ,imuankleori3 ,imuankleori4 ,imuankletemp ,imuchestacc16gxaxis ,imuchestacc16gyaxis ,imuchestacc16gzaxis ,imuchestacc6gxaxis ,imuchestacc6gyaxis ,imuchestacc6gzaxis ,imuchestgyroxaxis ,imuchestgyroyaxis ,imuchestgyrozaxis ,imuchestmagxaxis ,imuchestmagyaxis ,imuchestmagzaxis ,imuchestori1 ,imuchestori2 ,imuchestori3 ,imuchestori4 ,imuchesttemp ,imuhandacc16gxaxis ,imuhandacc16gyaxis ,imuhandacc16gzaxis ,imuhandacc6gxaxis ,imuhandacc6gyaxis ,imuhandacc6gzaxis ,imuhandgyroxaxis ,imuhandgyroyaxis ,imuhandgyrozaxis ,imuhandmagxaxis ,imuhandmagyaxis ,imuhandmagzaxis ,imuhandori1 ,imuhandori2 ,imuhandori3 ,imuhandori4 ,imuhandtemp ,isactive ,rowid ,sourceid
cqlsh -e'select * from anomaly_final where peopleid=*** ALLOW FILTERING' > '_final.csv' -- try using copy for big vol of data
scp -r [email protected]:/tmp/x.csv .
scp -i "ofs.pem" [email protected]:/home/centos/*.csv .
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment