NoSQL and Advantages of NOSQL

Posted on Posted in Cassandra, Hadoop, MongoDB

Why NoSQL?  – Bigger data handling capability   To handle Volume of data it allows data to be spread across commodity hardware  – Elastic scaling   Scale out the storage  – Flexible Schema/fixed data model    It does not need a organized schema. The schema is dynamic or fixed schema  – Integrated caching facility   To Increase performance, NOSQL […]

CAP Theorem

Posted on Posted in Cassandra, Hadoop, Hadoop, HBase, MongoDB

CAP Theorem for a distributed architecture: Consistency: The data in database remains consistent after the execution of an operation.Example: After an insert operation all clients will see the same data Availability:The System is always On/Available. Partition Tolerance:The system continues to function even if the servers are not able to communicate with each other CAP provides […]

Data Manipulation Language in Cassandra

Posted on Posted in Cassandra, Hadoop

Data Manipulation Language in Cassandra: Insert data to KeySpace: Syntax: &lt;INSERTSTATEMENT&gt; ::= INSERT INTO &lt;TABLENAME&gt; '(' &lt;IDENTIFIER&gt; ( ',' &lt;IDENTIFIER&gt;)* ')' VALUES'(' &lt;TERM -OR- LITERAL&gt; (',' &lt;TERM -OR- LITERAL&gt;)<em>')'(IF NOT EXIST)?( USING&lt;OPTION&gt; (AND&lt;OPTION&gt;)</em> )?&lt;TERM -OR- LITERAL&gt; ::= &lt;TERM&gt; | &lt;COLLECTION-LITERAL&gt; &lt;OPTION&gt; ::= TIMESTAMP &lt;INTEGER&gt;|TTL&lt;INTEGER&gt; Update data in KeySpace: Syntax: &lt;UPDATE-STMT&gt; ::= UPDATE&lt;TABLE-NAME&gt; (USING &lt;OPTION&gt; (AND […]

Data Definition Language in Cassandra

Posted on Posted in Cassandra, Hadoop

Data Definition Language in Cassandra: You can create,alter,drop,truncate table/keyspaces in Cassandra. Create KeySpace: It is used to create a new keyspace Syntax: CREATE KEYSPACE &lt;NAME&gt; WITH STATEGY_CLASS = &lt;STATEGY_NAME&gt;[AND STRATEGY_OPTIONS;&lt;OPTION&gt;=&lt;VALUE&gt;[…]]; USE: It is used to switch to a keyspace to perform work Syntax: USE &lt;KEYSPACE&gt; Alter KeySpace: To change the existing keyspace Syntax: &lt;CRETAE-KEYSPACE-STMT&gt;::= ALTER […]

Cassandra Query Language (CQL)

Posted on Posted in Cassandra, Hadoop

Cassandra Query Language:(CQL) CQL is the SQL interface in Cassandra.CQL is intended to privide a simple,common and easier interface in Cassandra. Cassandra was originally developed with a Thrift RPC based approach and it was difficult to work with. So CQL was developed to overcome the Thrift RPC approach. It is similar to SQL but all […]

Cassandra Data Model

Posted on Posted in Cassandra, Hadoop

Data model determines the logical model of a database and the manner by which the data is stored, organized and manipulated. Data model Keywords in Cassandra: Cluster is the database server and keyspace is the database in cassandra.ROws and columns are the way data organized in a table in Cassandra.You can create primary and secondary […]

Snitches in Cassandra

Posted on Posted in Cassandra, Hadoop

Snitch is used to determine the relative host proximity. Snitches gather information on network topology for cassandra to efficiently route requests. For a single data center cluster, simple snitch is sufficient. Types of Snitches: Simple snitches This is the default snitch used and uses a simple strategy of placing the copy of the row on […]