SlideShare a Scribd company logo
APACHE
CASSANDRA
SUMMARY OF CONTENTS
What is Apache Cassandra?
Evolution of Cassandra ?
Why Cassandra for Big Data?
Apache Cassandra Data types ?
Data Distribution in Apache Cassandra
How to Add Data in Cassandra ?
How to Read Data ?
How to Delete Data ?
Use Cases ?
Advantages and Limitations
Apache Cassandra is an open-source, NoSQL, wide column data store that can quickly
take and process huge amounts of data.
It is decentralized, distributed, scalable, highly available, and fault-tolerant, ,
with identical nodes that are clustered together for eliminating single points of failure.
WHAT IS APACHE CASSANDRA ?
EVOLUTION OF CASSANDRA ?
WHY CASSANDRA FOR BIG DATA?
1. Handles high velocity data with ease
2. Uses schema that support broad varieties of data
3. Is designed for continuous availability
4. Offers quick installation and configuration for multi-node clusters.
5. It is open source and reduces cost as compared to RDBMS.
DATA TYPES IN CASSANDRA ?
1.It supports the most common data types including ASCII, Bigint , BLOB, Boolean counter,
decimal, double, float, int , text, timestamp, UUID, varchar etc.
2.Its data model offers the convenient of the column indexes with the performance of log
structured updates, strong support for denormalization and materialized views and built in
caching.
3.Data access is performed using CQL (Cassandra Query Language) which is resembled to
SQL (Structured Query Language).
DATA DISTRIBUTION IN CASSANDRA ?
Cassandra uses a peer-to-peer model for distributing the data, which enables it to fully
distribute data in the form of variable-length rows, stored by partition keys. Cassandra is
built for its scalability, continuous availability, and has having no single point of
failure.
Many Different databases, such as Postgre SQL, use a master-slave replication model,
in which the writes go to a master node and reads are executed on slaves. To provide high
availability, fault tolerance, and scalability, Cassandra’s peer-to-peer distribution model
provides nodes with open channels of communication. Cassandra uses Tokens ( a 64
bit integer) for determining which node holds what data.
ADDING DATA IN CASSANDRA ?
You can insert data into the columns of a row in a table using the command INSERT.
Syntax for creating data in a table is shown below.
INSERT INTO <tablename>
(<column1 name>, <column2
name>....) VALUES (<value1>,
<value2>....)
USING <option>
Let us assume there is a table called std with columns (std_id, std_name, std_city,
std_phone, std_fee) and you have to insert the following data into the std table.
ADDING DATA IN CASSANDRA ?
Use the commands given below to fill the table with required data.
cqlsh: project1> INSERT INTO std (std_id, std_name, std_city, std_phone,
std_fee) VALUES (1,'Ramesh', 'Hyderabad', 9191234567, 55000);
cqlsh:project1> INSERT INTO std (std_id, std_name, std_city, std_phone,
std_fee) VALUES (2,'Pavan', 'Visakhapatnam', 9191234567, 45000);
cqlsh:project1> INSERT INTO std (std_id, std_name, std_city, std_phone,
std_fee) VALUES (3,'Gayatri', 'Vizainagaram', 9191234567, 47000);
READING DATA IN CASSANDRA ?
SELECT clause is used to read data from a table in Cassandra. By Using this clause, you can read a
whole table, a single column, or a particular cell.
The syntax of SELECT clause is given below
SELECT FROM <tablename>
Assume there is a table in the key space named std with the following details –
cqlsh:project1> select * from std;
cqlsh:project1> SELECT std_name, std_fee from std;
DELETING DATA IN CASSANDRA ?
The following statement deletes the std_fee column of last row –
cqlsh:project1> DELETE std_fee FROM std WHERE emp_id=3; Deletion of
Entire row:-
The following command deletes an entire row from a table.
cqlsh:project1> DELETE FROM std WHERE emp_id=3;
You can delete data from a table using the command DELETE. The syntax is given below
DELETE FROM <identifier> WHERE <condition>;
USE CASES FOR CASSANDRA ?
1. Mobility
2. Security and Fraud Detection
3. Personalization and Recommendation
4. IOT
5. Cloud Operations
ADVANTAGES?
1. Open source
2. Peer to peer Architecture
3. Elastic Scalability
4. High Availability and Fault Tolerence
5. High performance
6. Column oriented
7. Tunable Consistency
8. Schema-Free
LIMITATIONS
?1. A single column value may not be larger than 2 Giga Bytes.
2. The maximum number of column per row is 2 billion.
3. All data read should fit in memory due to thrift streaming support lack.
4. The key must be less than 64k bytes.
THANK YOU

More Related Content

Similar to Cassandra Tutorial | Data types | Why Cassandra for Big Data (20)

PDF
Trivadis TechEvent 2016 Big Data Cassandra, wieso brauche ich das? by Jan Ott
Trivadis
 
PPTX
Cassndra (4).pptx
NikhilAmauriya
 
PPTX
Apache Cassandra Data Modeling with Travis Price
DataStax Academy
 
PPTX
Appache Cassandra
nehabsairam
 
PPTX
Cassandra tutorial
Ramakrishna kapa
 
PPTX
Learning Cassandra NoSQL
Pankaj Khattar
 
PDF
Deep Dive into Cassandra
Brent Theisen
 
PDF
CQL In Cassandra 1.0 (and beyond)
Eric Evans
 
PDF
Cassandra Database
YounesCharfaoui
 
PPTX
An Introduction to Cassandra - Oracle User Group
Carlos Juzarte Rolo
 
PPTX
Cassandra - A decentralized storage system
Arunit Gupta
 
PPTX
Apache Cassandra, part 1 – principles, data model
Andrey Lomakin
 
PPT
Apache cassandra
Muralidharan Deenathayalan
 
ODP
Intro to cassandra
Aaron Ploetz
 
PDF
Cassandra NoSQL Tutorial
Michelle Darling
 
PPTX
Cassandra for mission critical data
Oleksandr Semenov
 
PDF
Cassandra Data Modeling
Ben Knear
 
PPTX
Cassandra Tutorial
Na Zhu
 
PDF
Introduction to Cassandra Concepts and its usage
bharatkumarbhojwani
 
PDF
Introduction to Apache Cassandra™ + What’s New in 4.0
DataStax
 
Trivadis TechEvent 2016 Big Data Cassandra, wieso brauche ich das? by Jan Ott
Trivadis
 
Cassndra (4).pptx
NikhilAmauriya
 
Apache Cassandra Data Modeling with Travis Price
DataStax Academy
 
Appache Cassandra
nehabsairam
 
Cassandra tutorial
Ramakrishna kapa
 
Learning Cassandra NoSQL
Pankaj Khattar
 
Deep Dive into Cassandra
Brent Theisen
 
CQL In Cassandra 1.0 (and beyond)
Eric Evans
 
Cassandra Database
YounesCharfaoui
 
An Introduction to Cassandra - Oracle User Group
Carlos Juzarte Rolo
 
Cassandra - A decentralized storage system
Arunit Gupta
 
Apache Cassandra, part 1 – principles, data model
Andrey Lomakin
 
Apache cassandra
Muralidharan Deenathayalan
 
Intro to cassandra
Aaron Ploetz
 
Cassandra NoSQL Tutorial
Michelle Darling
 
Cassandra for mission critical data
Oleksandr Semenov
 
Cassandra Data Modeling
Ben Knear
 
Cassandra Tutorial
Na Zhu
 
Introduction to Cassandra Concepts and its usage
bharatkumarbhojwani
 
Introduction to Apache Cassandra™ + What’s New in 4.0
DataStax
 

Recently uploaded (20)

PDF
Generative AI: it's STILL not a robot (CIJ Summer 2025)
Paul Bradshaw
 
PPTX
MENINGITIS: NURSING MANAGEMENT, BACTERIAL MENINGITIS, VIRAL MENINGITIS.pptx
PRADEEP ABOTHU
 
PDF
Dimensions of Societal Planning in Commonism
StefanMz
 
PPTX
grade 5 lesson matatag ENGLISH 5_Q1_PPT_WEEK4.pptx
SireQuinn
 
PPT
Talk on Critical Theory, Part One, Philosophy of Social Sciences
Soraj Hongladarom
 
PDF
People & Earth's Ecosystem -Lesson 2: People & Population
marvinnbustamante1
 
PPTX
Soil and agriculture microbiology .pptx
Keerthana Ramesh
 
PDF
CEREBRAL PALSY: NURSING MANAGEMENT .pdf
PRADEEP ABOTHU
 
PPTX
HYDROCEPHALUS: NURSING MANAGEMENT .pptx
PRADEEP ABOTHU
 
PDF
ARAL_Orientation_Day-2-Sessions_ARAL-Readung ARAL-Mathematics ARAL-Sciencev2.pdf
JoelVilloso1
 
PPSX
HEALTH ASSESSMENT (Community Health Nursing) - GNM 1st Year
Priyanshu Anand
 
PPTX
How to Convert an Opportunity into a Quotation in Odoo 18 CRM
Celine George
 
PDF
CONCURSO DE POESIA “POETUFAS – PASSOS SUAVES PELO VERSO.pdf
Colégio Santa Teresinha
 
PDF
Lesson 2 - WATER,pH, BUFFERS, AND ACID-BASE.pdf
marvinnbustamante1
 
PPTX
A PPT on Alfred Lord Tennyson's Ulysses.
Beena E S
 
PPTX
How to Create a PDF Report in Odoo 18 - Odoo Slides
Celine George
 
PDF
Knee Extensor Mechanism Injuries - Orthopedic Radiologic Imaging
Sean M. Fox
 
PPTX
2025 Winter SWAYAM NPTEL & A Student.pptx
Utsav Yagnik
 
PPTX
How to Set Maximum Difference Odoo 18 POS
Celine George
 
PDF
ARAL-Orientation_Morning-Session_Day-11.pdf
JoelVilloso1
 
Generative AI: it's STILL not a robot (CIJ Summer 2025)
Paul Bradshaw
 
MENINGITIS: NURSING MANAGEMENT, BACTERIAL MENINGITIS, VIRAL MENINGITIS.pptx
PRADEEP ABOTHU
 
Dimensions of Societal Planning in Commonism
StefanMz
 
grade 5 lesson matatag ENGLISH 5_Q1_PPT_WEEK4.pptx
SireQuinn
 
Talk on Critical Theory, Part One, Philosophy of Social Sciences
Soraj Hongladarom
 
People & Earth's Ecosystem -Lesson 2: People & Population
marvinnbustamante1
 
Soil and agriculture microbiology .pptx
Keerthana Ramesh
 
CEREBRAL PALSY: NURSING MANAGEMENT .pdf
PRADEEP ABOTHU
 
HYDROCEPHALUS: NURSING MANAGEMENT .pptx
PRADEEP ABOTHU
 
ARAL_Orientation_Day-2-Sessions_ARAL-Readung ARAL-Mathematics ARAL-Sciencev2.pdf
JoelVilloso1
 
HEALTH ASSESSMENT (Community Health Nursing) - GNM 1st Year
Priyanshu Anand
 
How to Convert an Opportunity into a Quotation in Odoo 18 CRM
Celine George
 
CONCURSO DE POESIA “POETUFAS – PASSOS SUAVES PELO VERSO.pdf
Colégio Santa Teresinha
 
Lesson 2 - WATER,pH, BUFFERS, AND ACID-BASE.pdf
marvinnbustamante1
 
A PPT on Alfred Lord Tennyson's Ulysses.
Beena E S
 
How to Create a PDF Report in Odoo 18 - Odoo Slides
Celine George
 
Knee Extensor Mechanism Injuries - Orthopedic Radiologic Imaging
Sean M. Fox
 
2025 Winter SWAYAM NPTEL & A Student.pptx
Utsav Yagnik
 
How to Set Maximum Difference Odoo 18 POS
Celine George
 
ARAL-Orientation_Morning-Session_Day-11.pdf
JoelVilloso1
 
Ad

Cassandra Tutorial | Data types | Why Cassandra for Big Data

  • 2. SUMMARY OF CONTENTS What is Apache Cassandra? Evolution of Cassandra ? Why Cassandra for Big Data? Apache Cassandra Data types ? Data Distribution in Apache Cassandra How to Add Data in Cassandra ? How to Read Data ? How to Delete Data ? Use Cases ? Advantages and Limitations
  • 3. Apache Cassandra is an open-source, NoSQL, wide column data store that can quickly take and process huge amounts of data. It is decentralized, distributed, scalable, highly available, and fault-tolerant, , with identical nodes that are clustered together for eliminating single points of failure. WHAT IS APACHE CASSANDRA ?
  • 5. WHY CASSANDRA FOR BIG DATA? 1. Handles high velocity data with ease 2. Uses schema that support broad varieties of data 3. Is designed for continuous availability 4. Offers quick installation and configuration for multi-node clusters. 5. It is open source and reduces cost as compared to RDBMS.
  • 6. DATA TYPES IN CASSANDRA ? 1.It supports the most common data types including ASCII, Bigint , BLOB, Boolean counter, decimal, double, float, int , text, timestamp, UUID, varchar etc. 2.Its data model offers the convenient of the column indexes with the performance of log structured updates, strong support for denormalization and materialized views and built in caching. 3.Data access is performed using CQL (Cassandra Query Language) which is resembled to SQL (Structured Query Language).
  • 7. DATA DISTRIBUTION IN CASSANDRA ? Cassandra uses a peer-to-peer model for distributing the data, which enables it to fully distribute data in the form of variable-length rows, stored by partition keys. Cassandra is built for its scalability, continuous availability, and has having no single point of failure. Many Different databases, such as Postgre SQL, use a master-slave replication model, in which the writes go to a master node and reads are executed on slaves. To provide high availability, fault tolerance, and scalability, Cassandra’s peer-to-peer distribution model provides nodes with open channels of communication. Cassandra uses Tokens ( a 64 bit integer) for determining which node holds what data.
  • 8. ADDING DATA IN CASSANDRA ? You can insert data into the columns of a row in a table using the command INSERT. Syntax for creating data in a table is shown below. INSERT INTO <tablename> (<column1 name>, <column2 name>....) VALUES (<value1>, <value2>....) USING <option> Let us assume there is a table called std with columns (std_id, std_name, std_city, std_phone, std_fee) and you have to insert the following data into the std table.
  • 9. ADDING DATA IN CASSANDRA ? Use the commands given below to fill the table with required data. cqlsh: project1> INSERT INTO std (std_id, std_name, std_city, std_phone, std_fee) VALUES (1,'Ramesh', 'Hyderabad', 9191234567, 55000); cqlsh:project1> INSERT INTO std (std_id, std_name, std_city, std_phone, std_fee) VALUES (2,'Pavan', 'Visakhapatnam', 9191234567, 45000); cqlsh:project1> INSERT INTO std (std_id, std_name, std_city, std_phone, std_fee) VALUES (3,'Gayatri', 'Vizainagaram', 9191234567, 47000);
  • 10. READING DATA IN CASSANDRA ? SELECT clause is used to read data from a table in Cassandra. By Using this clause, you can read a whole table, a single column, or a particular cell. The syntax of SELECT clause is given below SELECT FROM <tablename> Assume there is a table in the key space named std with the following details – cqlsh:project1> select * from std; cqlsh:project1> SELECT std_name, std_fee from std;
  • 11. DELETING DATA IN CASSANDRA ? The following statement deletes the std_fee column of last row – cqlsh:project1> DELETE std_fee FROM std WHERE emp_id=3; Deletion of Entire row:- The following command deletes an entire row from a table. cqlsh:project1> DELETE FROM std WHERE emp_id=3; You can delete data from a table using the command DELETE. The syntax is given below DELETE FROM <identifier> WHERE <condition>;
  • 12. USE CASES FOR CASSANDRA ? 1. Mobility 2. Security and Fraud Detection 3. Personalization and Recommendation 4. IOT 5. Cloud Operations
  • 13. ADVANTAGES? 1. Open source 2. Peer to peer Architecture 3. Elastic Scalability 4. High Availability and Fault Tolerence 5. High performance 6. Column oriented 7. Tunable Consistency 8. Schema-Free
  • 14. LIMITATIONS ?1. A single column value may not be larger than 2 Giga Bytes. 2. The maximum number of column per row is 2 billion. 3. All data read should fit in memory due to thrift streaming support lack. 4. The key must be less than 64k bytes.