SlideShare a Scribd company logo
1 of 12
MongoDB
SHARAN PRAKASH BABU
IIT CHICAGO
What is MongoDB?
MongoDB (from “humoungus”) is a
scalable, high-performance, open source,
schema-free, document-oriented database.
- mongodb.org
Philosophy
• “One size fits all” approach no longer applies
• Non-Relational DB’s scale more easily, especially horizontally
• Focus on speed, performance, flexibility and scalability
• Not concerned with transactional stuff and relational semantics
• DBs should be an on-demand commodity, in a cloud- like fashion
Philosophy
Mongo tries to achieve the performance of
traditional key-value stores while
maintaining functionality of traditional
RDBMS
Features of MongoDB
Document data model
 Documents are stored in BSON (binary JSON)
 BSON is a binary serialization of JSON-like objects
 This is extremely powerful, b/c it means mongo understands JSON natively
 Any valid JSON can be easily imported and queried
Sample JSON
{“author”: “sharan”, “text”: “...”}
{“author”: “eliot”, “text”: “...”, “tags”: [“mongodb”]}
JSON style Document represented in BSON
{“hello”: “world”}
x16x00x00x00x02hello x00x06x00x00x00world x00x00
Features of MongoDB (contd.)
Dynamic Schema
 Polymorphic Data is the normal
 Data models can evolve as the applications evolve – quicker to iterate
 Highly flexible
Sample “Schemas” ( Document )
{“author”: “mike”,
“text”: “...”}
{“author”: “eliot”,
“text”: “...”,
“tags”: [“mongodb”]}
Features of MongoDB (contd.)
Built-in Horizontal Scalability
 Low infrastructure costs – commodity hosts
 Elasticity – start small and invest incrementally
 Strong with major languages
 Supports Map-Reduce
Querying
 Rich, JavaScript-based query syntax A
 Allows us to do deep, nested queries
Ex. db.order.find( { shipping: { carrier: ”SpeedPost" } } );
Concepts
 Document Oriented
 Think of “documents” as database records
 Documents are basically just JSON objects that Mongo stores in binary
 Think of “collections” as database tables
RDBMS (mysql, postgres) MongoDB
Tables Collections
Records/rows Documents/objects
Queries return record(s) Queries return a cursor
Concepts(contd.)
Cursors
 Queries return “cursors” instead of collections
 A cursor allows you to iterate through the result set
 A big reason for this is performance
 Much more efficient than loading all objects into memory
 Capped collections
 Fixed-sized, limited operation, auto-LRU age-out collections
 Fixed insertion order
 Super fast
 Ideal for logging and caching
Uses
Scaling Out
Caching
The Web
High Volume
Data Warehousing
What MongoDB does not support?
Joins
Highly Transactions
Problems that require SQL
Relational Integrity
Demo
Demo of the following operations
Creating a collection
Inserting documents
Finding documents
How a key values pair works

More Related Content

What's hot

MongoDB Hadoop DC
MongoDB Hadoop DCMongoDB Hadoop DC
MongoDB Hadoop DCMike Dirolf
 
MongoDB at CodeMash 2.0.1.0
MongoDB at CodeMash 2.0.1.0MongoDB at CodeMash 2.0.1.0
MongoDB at CodeMash 2.0.1.0Mike Dirolf
 
Mongodb Training Tutorial in Bangalore
Mongodb Training Tutorial in BangaloreMongodb Training Tutorial in Bangalore
Mongodb Training Tutorial in Bangalorerajkamaltibacademy
 
A Presentation on MongoDB Introduction - Habilelabs
A Presentation on MongoDB Introduction - HabilelabsA Presentation on MongoDB Introduction - Habilelabs
A Presentation on MongoDB Introduction - HabilelabsHabilelabs
 
Why MongoDB over other Databases - Habilelabs
Why MongoDB over other Databases - HabilelabsWhy MongoDB over other Databases - Habilelabs
Why MongoDB over other Databases - HabilelabsHabilelabs
 
Introduction To MongoDB
Introduction To MongoDBIntroduction To MongoDB
Introduction To MongoDBYubraj Ghimire
 
Mongodb intro
Mongodb introMongodb intro
Mongodb introchristkv
 
Building a Directed Graph with MongoDB
Building a Directed Graph with MongoDBBuilding a Directed Graph with MongoDB
Building a Directed Graph with MongoDBTony Tam
 
Introduction to mongo db by zain
Introduction to mongo db by zainIntroduction to mongo db by zain
Introduction to mongo db by zainKenAndTea
 
SharePoint Saturday Durban Presentation
SharePoint Saturday Durban PresentationSharePoint Saturday Durban Presentation
SharePoint Saturday Durban PresentationWarren Marks
 

What's hot (20)

MongoDB Hadoop DC
MongoDB Hadoop DCMongoDB Hadoop DC
MongoDB Hadoop DC
 
mongodb_Introduction
mongodb_Introductionmongodb_Introduction
mongodb_Introduction
 
MongoDB at CodeMash 2.0.1.0
MongoDB at CodeMash 2.0.1.0MongoDB at CodeMash 2.0.1.0
MongoDB at CodeMash 2.0.1.0
 
Mongo db
Mongo dbMongo db
Mongo db
 
Mongodb Training Tutorial in Bangalore
Mongodb Training Tutorial in BangaloreMongodb Training Tutorial in Bangalore
Mongodb Training Tutorial in Bangalore
 
A Presentation on MongoDB Introduction - Habilelabs
A Presentation on MongoDB Introduction - HabilelabsA Presentation on MongoDB Introduction - Habilelabs
A Presentation on MongoDB Introduction - Habilelabs
 
Introduction to mongodb
Introduction to mongodbIntroduction to mongodb
Introduction to mongodb
 
Why MongoDB over other Databases - Habilelabs
Why MongoDB over other Databases - HabilelabsWhy MongoDB over other Databases - Habilelabs
Why MongoDB over other Databases - Habilelabs
 
Introduction to mongoDB
Introduction to mongoDBIntroduction to mongoDB
Introduction to mongoDB
 
Introduction To MongoDB
Introduction To MongoDBIntroduction To MongoDB
Introduction To MongoDB
 
Mongo db workshop # 02
Mongo db workshop # 02Mongo db workshop # 02
Mongo db workshop # 02
 
CSCi226PPT1
CSCi226PPT1CSCi226PPT1
CSCi226PPT1
 
Mongodb intro
Mongodb introMongodb intro
Mongodb intro
 
10 mongo db
10 mongo db10 mongo db
10 mongo db
 
MongoDb - Details on the POC
MongoDb - Details on the POCMongoDb - Details on the POC
MongoDb - Details on the POC
 
Building a Directed Graph with MongoDB
Building a Directed Graph with MongoDBBuilding a Directed Graph with MongoDB
Building a Directed Graph with MongoDB
 
MongoDB 101
MongoDB 101MongoDB 101
MongoDB 101
 
Starting with MongoDB
Starting with MongoDBStarting with MongoDB
Starting with MongoDB
 
Introduction to mongo db by zain
Introduction to mongo db by zainIntroduction to mongo db by zain
Introduction to mongo db by zain
 
SharePoint Saturday Durban Presentation
SharePoint Saturday Durban PresentationSharePoint Saturday Durban Presentation
SharePoint Saturday Durban Presentation
 

Viewers also liked

Invoice Processing Serv ice
Invoice Processing Serv iceInvoice Processing Serv ice
Invoice Processing Serv icerdpigott
 
P:\Aqua Texas\Wimberley Valley Water Talks\Presentations\3 19 10 Wimberley Va...
P:\Aqua Texas\Wimberley Valley Water Talks\Presentations\3 19 10 Wimberley Va...P:\Aqua Texas\Wimberley Valley Water Talks\Presentations\3 19 10 Wimberley Va...
P:\Aqua Texas\Wimberley Valley Water Talks\Presentations\3 19 10 Wimberley Va...jessyoung
 
Sindrome de Dolor Regional Complejo. Tratamiento farmacológico e intervencion...
Sindrome de Dolor Regional Complejo. Tratamiento farmacológico e intervencion...Sindrome de Dolor Regional Complejo. Tratamiento farmacológico e intervencion...
Sindrome de Dolor Regional Complejo. Tratamiento farmacológico e intervencion...Miguel Mendez
 
Sindrome De Dolor Regional Complejo. Rehabilitación
Sindrome De Dolor Regional Complejo. RehabilitaciónSindrome De Dolor Regional Complejo. Rehabilitación
Sindrome De Dolor Regional Complejo. RehabilitaciónMiguel Mendez
 
113 online suicide prevention: First two year results presented at the ESSSB1...
113 online suicide prevention: First two year results presented at the ESSSB1...113 online suicide prevention: First two year results presented at the ESSSB1...
113 online suicide prevention: First two year results presented at the ESSSB1...Jan Mokkenstorm
 
Neuropatía Supraescapular
Neuropatía SupraescapularNeuropatía Supraescapular
Neuropatía SupraescapularMiguel Mendez
 
Martisor andrea dogot
Martisor andrea dogotMartisor andrea dogot
Martisor andrea dogotElias Garcia
 
Sindrome De Dolor Regional Complejo
Sindrome De Dolor Regional ComplejoSindrome De Dolor Regional Complejo
Sindrome De Dolor Regional ComplejoMiguel Mendez
 
BD - Queres conhecer o projeto prove?
BD - Queres conhecer o projeto prove?BD - Queres conhecer o projeto prove?
BD - Queres conhecer o projeto prove?Elias Garcia
 
Livrodapaz3 a.pptx
Livrodapaz3 a.pptxLivrodapaz3 a.pptx
Livrodapaz3 a.pptxElias Garcia
 
IAPP Accounts Payable Automation Presentation
IAPP Accounts Payable Automation PresentationIAPP Accounts Payable Automation Presentation
IAPP Accounts Payable Automation Presentationrdpigott
 
Afinal o que é a saúde mental?
Afinal o que é a saúde mental?Afinal o que é a saúde mental?
Afinal o que é a saúde mental?Elias Garcia
 
Magnetoterapia 2º parte
Magnetoterapia 2º parteMagnetoterapia 2º parte
Magnetoterapia 2º parteMiguel Mendez
 
Divulgação de Clubes e projetos do dia do agrupamento
Divulgação de Clubes e projetos do dia do agrupamentoDivulgação de Clubes e projetos do dia do agrupamento
Divulgação de Clubes e projetos do dia do agrupamentoElias Garcia
 
Accounts Payable Processing Presentation
Accounts Payable Processing PresentationAccounts Payable Processing Presentation
Accounts Payable Processing Presentationrdpigott
 

Viewers also liked (19)

ColaboracióN Web
ColaboracióN WebColaboracióN Web
ColaboracióN Web
 
Invoice Processing Serv ice
Invoice Processing Serv iceInvoice Processing Serv ice
Invoice Processing Serv ice
 
P:\Aqua Texas\Wimberley Valley Water Talks\Presentations\3 19 10 Wimberley Va...
P:\Aqua Texas\Wimberley Valley Water Talks\Presentations\3 19 10 Wimberley Va...P:\Aqua Texas\Wimberley Valley Water Talks\Presentations\3 19 10 Wimberley Va...
P:\Aqua Texas\Wimberley Valley Water Talks\Presentations\3 19 10 Wimberley Va...
 
Sindrome de Dolor Regional Complejo. Tratamiento farmacológico e intervencion...
Sindrome de Dolor Regional Complejo. Tratamiento farmacológico e intervencion...Sindrome de Dolor Regional Complejo. Tratamiento farmacológico e intervencion...
Sindrome de Dolor Regional Complejo. Tratamiento farmacológico e intervencion...
 
Sindrome De Dolor Regional Complejo. Rehabilitación
Sindrome De Dolor Regional Complejo. RehabilitaciónSindrome De Dolor Regional Complejo. Rehabilitación
Sindrome De Dolor Regional Complejo. Rehabilitación
 
113 online suicide prevention: First two year results presented at the ESSSB1...
113 online suicide prevention: First two year results presented at the ESSSB1...113 online suicide prevention: First two year results presented at the ESSSB1...
113 online suicide prevention: First two year results presented at the ESSSB1...
 
Neuropatía Supraescapular
Neuropatía SupraescapularNeuropatía Supraescapular
Neuropatía Supraescapular
 
Martisor andrea dogot
Martisor andrea dogotMartisor andrea dogot
Martisor andrea dogot
 
Prolapso vaginal
Prolapso vaginalProlapso vaginal
Prolapso vaginal
 
Cetoacidos Diabetica en Pediatria
Cetoacidos Diabetica en Pediatria Cetoacidos Diabetica en Pediatria
Cetoacidos Diabetica en Pediatria
 
Sindrome De Dolor Regional Complejo
Sindrome De Dolor Regional ComplejoSindrome De Dolor Regional Complejo
Sindrome De Dolor Regional Complejo
 
BD - Queres conhecer o projeto prove?
BD - Queres conhecer o projeto prove?BD - Queres conhecer o projeto prove?
BD - Queres conhecer o projeto prove?
 
Livrodapaz3 a.pptx
Livrodapaz3 a.pptxLivrodapaz3 a.pptx
Livrodapaz3 a.pptx
 
IAPP Accounts Payable Automation Presentation
IAPP Accounts Payable Automation PresentationIAPP Accounts Payable Automation Presentation
IAPP Accounts Payable Automation Presentation
 
Afinal o que é a saúde mental?
Afinal o que é a saúde mental?Afinal o que é a saúde mental?
Afinal o que é a saúde mental?
 
Magnetoterapia 2º parte
Magnetoterapia 2º parteMagnetoterapia 2º parte
Magnetoterapia 2º parte
 
Magnetoterapia
MagnetoterapiaMagnetoterapia
Magnetoterapia
 
Divulgação de Clubes e projetos do dia do agrupamento
Divulgação de Clubes e projetos do dia do agrupamentoDivulgação de Clubes e projetos do dia do agrupamento
Divulgação de Clubes e projetos do dia do agrupamento
 
Accounts Payable Processing Presentation
Accounts Payable Processing PresentationAccounts Payable Processing Presentation
Accounts Payable Processing Presentation
 

Similar to MongoDB_Sharan_Prakash_Babu

MongoDB NoSQL database a deep dive -MyWhitePaper
MongoDB  NoSQL database a deep dive -MyWhitePaperMongoDB  NoSQL database a deep dive -MyWhitePaper
MongoDB NoSQL database a deep dive -MyWhitePaperRajesh Kumar
 
Top MongoDB interview Questions and Answers
Top MongoDB interview Questions and AnswersTop MongoDB interview Questions and Answers
Top MongoDB interview Questions and Answersjeetendra mandal
 
Kalp Corporate MongoDB Tutorials
Kalp Corporate MongoDB TutorialsKalp Corporate MongoDB Tutorials
Kalp Corporate MongoDB TutorialsKalp Corporate
 
Elasticsearch vs MongoDB comparison
Elasticsearch vs MongoDB comparisonElasticsearch vs MongoDB comparison
Elasticsearch vs MongoDB comparisonjeetendra mandal
 
Everything You Need to Know About MongoDB Development.pptx
Everything You Need to Know About MongoDB Development.pptxEverything You Need to Know About MongoDB Development.pptx
Everything You Need to Know About MongoDB Development.pptx75waytechnologies
 
Jumpstart: Building Your First MongoDB App
Jumpstart: Building Your First MongoDB AppJumpstart: Building Your First MongoDB App
Jumpstart: Building Your First MongoDB AppMongoDB
 
MongoDB.local Sydney: An Introduction to Document Databases with MongoDB
MongoDB.local Sydney: An Introduction to Document Databases with MongoDBMongoDB.local Sydney: An Introduction to Document Databases with MongoDB
MongoDB.local Sydney: An Introduction to Document Databases with MongoDBMongoDB
 
MongoDB 2.4 and spring data
MongoDB 2.4 and spring dataMongoDB 2.4 and spring data
MongoDB 2.4 and spring dataJimmy Ray
 
MongoDB presentation
MongoDB presentationMongoDB presentation
MongoDB presentationHyphen Call
 
MongoDB by Emroz sardar.
MongoDB by Emroz sardar.MongoDB by Emroz sardar.
MongoDB by Emroz sardar.Emroz Sardar
 
Basics of MongoDB
Basics of MongoDB Basics of MongoDB
Basics of MongoDB Habilelabs
 
Introduction to MongoDB
Introduction to MongoDBIntroduction to MongoDB
Introduction to MongoDBRavi Teja
 
Mongo Bb - NoSQL tutorial
Mongo Bb - NoSQL tutorialMongo Bb - NoSQL tutorial
Mongo Bb - NoSQL tutorialMohan Rathour
 
3-Mongodb and Mapreduce Programming.pdf
3-Mongodb and Mapreduce Programming.pdf3-Mongodb and Mapreduce Programming.pdf
3-Mongodb and Mapreduce Programming.pdfMarianJRuben
 
No SQL - MongoDB
No SQL - MongoDBNo SQL - MongoDB
No SQL - MongoDBMirza Asif
 

Similar to MongoDB_Sharan_Prakash_Babu (20)

MongoDB NoSQL database a deep dive -MyWhitePaper
MongoDB  NoSQL database a deep dive -MyWhitePaperMongoDB  NoSQL database a deep dive -MyWhitePaper
MongoDB NoSQL database a deep dive -MyWhitePaper
 
Top MongoDB interview Questions and Answers
Top MongoDB interview Questions and AnswersTop MongoDB interview Questions and Answers
Top MongoDB interview Questions and Answers
 
Kalp Corporate MongoDB Tutorials
Kalp Corporate MongoDB TutorialsKalp Corporate MongoDB Tutorials
Kalp Corporate MongoDB Tutorials
 
Elasticsearch vs MongoDB comparison
Elasticsearch vs MongoDB comparisonElasticsearch vs MongoDB comparison
Elasticsearch vs MongoDB comparison
 
MongoDB
MongoDBMongoDB
MongoDB
 
Everything You Need to Know About MongoDB Development.pptx
Everything You Need to Know About MongoDB Development.pptxEverything You Need to Know About MongoDB Development.pptx
Everything You Need to Know About MongoDB Development.pptx
 
Jumpstart: Building Your First MongoDB App
Jumpstart: Building Your First MongoDB AppJumpstart: Building Your First MongoDB App
Jumpstart: Building Your First MongoDB App
 
MongoDB.local Sydney: An Introduction to Document Databases with MongoDB
MongoDB.local Sydney: An Introduction to Document Databases with MongoDBMongoDB.local Sydney: An Introduction to Document Databases with MongoDB
MongoDB.local Sydney: An Introduction to Document Databases with MongoDB
 
MongoDB 2.4 and spring data
MongoDB 2.4 and spring dataMongoDB 2.4 and spring data
MongoDB 2.4 and spring data
 
MongoDB presentation
MongoDB presentationMongoDB presentation
MongoDB presentation
 
MongoDB by Emroz sardar.
MongoDB by Emroz sardar.MongoDB by Emroz sardar.
MongoDB by Emroz sardar.
 
MongoDB.pptx
MongoDB.pptxMongoDB.pptx
MongoDB.pptx
 
Basics of MongoDB
Basics of MongoDB Basics of MongoDB
Basics of MongoDB
 
Introduction to MongoDB
Introduction to MongoDBIntroduction to MongoDB
Introduction to MongoDB
 
Mongo Bb - NoSQL tutorial
Mongo Bb - NoSQL tutorialMongo Bb - NoSQL tutorial
Mongo Bb - NoSQL tutorial
 
MongoDB
MongoDBMongoDB
MongoDB
 
3-Mongodb and Mapreduce Programming.pdf
3-Mongodb and Mapreduce Programming.pdf3-Mongodb and Mapreduce Programming.pdf
3-Mongodb and Mapreduce Programming.pdf
 
Mongo db
Mongo dbMongo db
Mongo db
 
Mongodb
MongodbMongodb
Mongodb
 
No SQL - MongoDB
No SQL - MongoDBNo SQL - MongoDB
No SQL - MongoDB
 

MongoDB_Sharan_Prakash_Babu

  • 2. What is MongoDB? MongoDB (from “humoungus”) is a scalable, high-performance, open source, schema-free, document-oriented database. - mongodb.org
  • 3. Philosophy • “One size fits all” approach no longer applies • Non-Relational DB’s scale more easily, especially horizontally • Focus on speed, performance, flexibility and scalability • Not concerned with transactional stuff and relational semantics • DBs should be an on-demand commodity, in a cloud- like fashion
  • 4. Philosophy Mongo tries to achieve the performance of traditional key-value stores while maintaining functionality of traditional RDBMS
  • 5. Features of MongoDB Document data model  Documents are stored in BSON (binary JSON)  BSON is a binary serialization of JSON-like objects  This is extremely powerful, b/c it means mongo understands JSON natively  Any valid JSON can be easily imported and queried Sample JSON {“author”: “sharan”, “text”: “...”} {“author”: “eliot”, “text”: “...”, “tags”: [“mongodb”]} JSON style Document represented in BSON {“hello”: “world”} x16x00x00x00x02hello x00x06x00x00x00world x00x00
  • 6. Features of MongoDB (contd.) Dynamic Schema  Polymorphic Data is the normal  Data models can evolve as the applications evolve – quicker to iterate  Highly flexible Sample “Schemas” ( Document ) {“author”: “mike”, “text”: “...”} {“author”: “eliot”, “text”: “...”, “tags”: [“mongodb”]}
  • 7. Features of MongoDB (contd.) Built-in Horizontal Scalability  Low infrastructure costs – commodity hosts  Elasticity – start small and invest incrementally  Strong with major languages  Supports Map-Reduce Querying  Rich, JavaScript-based query syntax A  Allows us to do deep, nested queries Ex. db.order.find( { shipping: { carrier: ”SpeedPost" } } );
  • 8. Concepts  Document Oriented  Think of “documents” as database records  Documents are basically just JSON objects that Mongo stores in binary  Think of “collections” as database tables RDBMS (mysql, postgres) MongoDB Tables Collections Records/rows Documents/objects Queries return record(s) Queries return a cursor
  • 9. Concepts(contd.) Cursors  Queries return “cursors” instead of collections  A cursor allows you to iterate through the result set  A big reason for this is performance  Much more efficient than loading all objects into memory  Capped collections  Fixed-sized, limited operation, auto-LRU age-out collections  Fixed insertion order  Super fast  Ideal for logging and caching
  • 11. What MongoDB does not support? Joins Highly Transactions Problems that require SQL Relational Integrity
  • 12. Demo Demo of the following operations Creating a collection Inserting documents Finding documents How a key values pair works