Database Reference
In-Depth Information
values(now(),'Cassandra book:beginning
cassandra development','@apress_team');
insert into
twitterdata(tweet_id,body,tweeted_by)
values(now(),'Technical review position
available for #Parse and #Phonegap related
@Apress titles: paid','@apress_team');
insert into
twitterdata(tweet_id,body,tweeted_by)
values(now(),'Android Apps Security
http://t.co/5XLSObkk9f' , '@jhassel');
3.
Let's connect to the Hive shell by configuring the Cassandra storage
handler, Thrift, and Cassandra-specific jars:
/home/vivek/software/hive-0.9.0/bin/hive
--auxpath /home/vivek/source/cash/
cassandra-handler/target/
hive-cassandra-1.2.9.jar:/home/vivek/.m2/
repository/org/apache/cassandra/cassandra-all/
1.2.9/cassandra-all-1.2.9.jar:/home/vivek/
software/apache-cassandra-2.0.4/lib/
libthrift-0.9.1.jar:/home/vivek/.m2/
repository/org/apache/cassandra/
cassandra-thrift/1.2.9/
cassandra-thrift-1.2.9.jar
4.
After successfully connecting with the Hive shell, we can create the
external table as follows:
CREATE EXTERNAL TABLE
twitter.twitterdata(tweet_id string, body
string, tweeted_by string) STORED BY
'org.apache.hadoop.hive.cassandra.cql.CqlStorageHandler'
WITH SERDEPROPERTIES ("cql.primarykey" =
"message_id, author", "comment"="check",
"read_repair_chance" = "0.2",
Search WWH ::




Custom Search