SlideShare a Scribd company logo
MongoDB for the SQL Server Pro
What is MongoDB?
• Open source NoSQL database
• Document-oriented
• Stores JSON-like documents (dynamic schemas)
• Includes a strong query language (javascript)
• Powerful, flexible indexing (including geospatial)
• Sharding and replication
• Cross-Platform (many drivers )
QUICKSTART - SETUP MONGODB
Demo
Get MongoDB and Driver(s)
• Quick download, zero install
• Also get your driver (C# for us)
Starting up MongoDB
Using the Console
Using MongoVue
Connecting with MongoVue
Using MongoVue
COMPARING DOCUMENT
DATABASES TO RDBMS SYSTEMS
Understanding more..
So which type of NoSQL? CAP…
Consistency
Availability
Partition
Tolerance
CP = noSQL/column
Hadoop
Big Table
H-base
MemCacheDB
(graph)?
CA = SQL/RDBMS
SQL Sever / SQL
Azure
Oracle
MySQL
AP = noSQL/document
or key/value
MongoDB
DynamoDB
CouchDB
Cassandra
Voldemort
DB Features for MongoDB & SQL Server
primary keys
and indexes
queries with
models for
sorting /
limiting results
a strong
typing system
aggregations
like SUM(),
COUNT(), etc…
Large object
support
DB Features unique to Document DBs
Collections, not Tables
Query language, not T-SQL
Idrefs, not Joins
No pre-defined Schema
• Aggregation Framework
• Grouping or MapReduce
Aggregations
• No multi-document transactions
No Transactions
No Full-text search
Use 10gen Quick Reference Cards
DB Features of note in MongoDB
• BSON supports more complex types (date, geo-spatial, etc…)
• Supports dynamic queries via proprietary query language
– Uses “find()” which returns a [lazy] cursor
– Multi-key indexes can be created
• Scalability via Replication and Sharding
Why use MongoDB?
• Document-like
• Semi-structured
• Few Joins
• Geospatial
Data Structure
• Large or Huge
• Distributed
• Unpredictable
Data Volume
MongoDB Scenarios
Document
Management
systems
E-commerce
(catalog portion
only)
Archiving /
event logging
Real time
analytics (based
on logging)
Gaming Geospatial
Mobile
IMPORTING DATA TO MONGODB
Demo
Adding Data
• Data must be in JSON format - converter
• “Insert” CREATES a collection if needed
Importing data…using MongoVue
Viewing Collection Data
USING VELOCITY FOR MODELING
Demo
Modeling
Use short names
• each name is saved for
each document
• can save up to 30%
storage
Keep collections
small
• Can create non-
default (narrower) key
• Document size
maximum is 4 MB
Use GridFS for
BLOBs
Comparing…
QUERY MONGODB DATA
Demo
Using Find
Find, Fields, Sort, Count, Skip, Limit, Visualize or Export
Data Visualization
Queries
Queries 2 …
Queries 3…
What is Grouping?
• Similar to T-SQL ‘Group By’
• Written in javascript
What about Joins?
No
traditional
joins in
MongoDB
Can use
Arrays
Can use
Embedded
Documents
Can use
DBRef
Can De-
normalize
schema
About the Aggregation Framework
• New in MongoDB 2.2
• Layer on top to facilitate easier query-writing
Query Tuning
• Use best indexes
– Evaluate use of _id
– Add columns to index (specificity)
– Multiple columns, most specific first
– Can use fully covered indexing (indexOnly:true)
– Test to make sure indexes are being used
• Qty scanned s/b same as QTY returned
• Use .explain
Understanding Explain
• Query execution detail plan
• Review number of scanned objects
ADD INDEXES TO MONGODB
Understanding more
Modifying Data
Update
• alone does a replace
Update w/ $set
• does an update
Update w/ $inc
• increments
Upserts
• must be enabled
• then insert if new,
update if existing
Multiple field
updates
• occur by default
Using Update
USING GRIDFS
Understanding more…
What is GridFS?
• Used to hold objects larger than 16 MB
CONNECTING TO MONGODB WITH C#
Demo
Programming against MongoDB
More Information
• MongoDB
– http://www.mongodb.org
• 10gen
– http://www.10gen.com/contact
– info@10gen.com
• YouTube videos (from Lynn Langit)
– MongoDB Playlist -
https://www.youtube.com/playlist?list=PLCE5902FB1D284880
&feature=view_all
• MongoDB LA UG - http://www.meetup.com/Los-Angeles-
MongoDB-User-Group
The Changing Data Landscape
NoSQL
RDBMS
Other
Services

More Related Content

What's hot (20)

PPTX
MongoDB Schema Design by Examples
Hadi Ariawan
 
PPTX
Mongo db
Raghu nath
 
PPTX
Klevis Mino: MongoDB
Carlo Vaccari
 
PPTX
MongoDB Introduction - Document Oriented Nosql Database
Sudhir Patil
 
PPTX
No sql - { If and Else }
Marjan Nikolovski
 
PDF
Migrating from MySQL to MongoDB
James Carr
 
PPTX
Introduction to MongoDB and CRUD operations
Anand Kumar
 
PDF
10 mongo db
Ahmed Elbassel
 
PDF
Data engineering Stl Big Data IDEA user group
Adam Doyle
 
PDF
Scaling MongoDB - Presentation at MTP
darkdata
 
PPTX
MongoDB introduction
Edward Yoon
 
PDF
NoSQL
Radu Potop
 
PPTX
mongoDB for sysadmins
Jordi Soucheiron
 
PPTX
NoSQL
Radu Vunvulea
 
PDF
MongoDB tuning on AWS
Ryuji Tamagawa
 
PPTX
Mongo DB
Er. Shiva K. Shrestha
 
PPT
First steps to Azure Cosmos DB: Getting Started with MongoDB and NoSQL
Hansamali Gamage
 
PPTX
Mongo DB
Karan Kukreja
 
PDF
Apache big data 2016 - Speaking the language of Big Data
techmaddy
 
PDF
Introduction to mongo db
Rohit Bishnoi
 
MongoDB Schema Design by Examples
Hadi Ariawan
 
Mongo db
Raghu nath
 
Klevis Mino: MongoDB
Carlo Vaccari
 
MongoDB Introduction - Document Oriented Nosql Database
Sudhir Patil
 
No sql - { If and Else }
Marjan Nikolovski
 
Migrating from MySQL to MongoDB
James Carr
 
Introduction to MongoDB and CRUD operations
Anand Kumar
 
10 mongo db
Ahmed Elbassel
 
Data engineering Stl Big Data IDEA user group
Adam Doyle
 
Scaling MongoDB - Presentation at MTP
darkdata
 
MongoDB introduction
Edward Yoon
 
NoSQL
Radu Potop
 
mongoDB for sysadmins
Jordi Soucheiron
 
MongoDB tuning on AWS
Ryuji Tamagawa
 
First steps to Azure Cosmos DB: Getting Started with MongoDB and NoSQL
Hansamali Gamage
 
Mongo DB
Karan Kukreja
 
Apache big data 2016 - Speaking the language of Big Data
techmaddy
 
Introduction to mongo db
Rohit Bishnoi
 

Similar to MongoDB for the SQL Server (20)

PPTX
Introduction to MongoDB.pptx
Surya937648
 
PPTX
Mongodb
ASEEMSRIVASTAVA22
 
PPTX
MongoDB presentation
Hyphen Call
 
PPTX
MongoDB
Rony Gregory
 
PDF
Mongodb
Apurva Vyas
 
PPTX
05201349_Unit_7_FSWD_ advanced learning.pptx
ozakamal8
 
PPTX
05201349_Unit_7_FSWD_II(1) with advance.pptx
ozakamal8
 
PPTX
Mongo db
AbhiKhurana8
 
PPTX
MongoDB NoSQL - Developer Guide
Shiv K Sah
 
PPTX
Kalp Corporate MongoDB Tutorials
Kalp Corporate
 
PDF
MongoDB
wiTTyMinds1
 
PPTX
MongoDbPpt based on python installation.
jnvcomputerlab2024
 
PDF
A Study on Mongodb Database
IJSRD
 
PDF
A Study on Mongodb Database.pdf
Jessica Navarro
 
PDF
MongoDB NoSQL database a deep dive -MyWhitePaper
Rajesh Kumar
 
PPT
Mongo Bb - NoSQL tutorial
Mohan Rathour
 
PPTX
Mongodb Introduction
Nabeel Naqeebi
 
DOCX
MongoDB DOC v1.5
Tharun Srinivasa
 
PPTX
Basics of MongoDB
HabileLabs
 
PDF
MongoDB - An Introduction
sethfloydjr
 
Introduction to MongoDB.pptx
Surya937648
 
MongoDB presentation
Hyphen Call
 
MongoDB
Rony Gregory
 
Mongodb
Apurva Vyas
 
05201349_Unit_7_FSWD_ advanced learning.pptx
ozakamal8
 
05201349_Unit_7_FSWD_II(1) with advance.pptx
ozakamal8
 
Mongo db
AbhiKhurana8
 
MongoDB NoSQL - Developer Guide
Shiv K Sah
 
Kalp Corporate MongoDB Tutorials
Kalp Corporate
 
MongoDB
wiTTyMinds1
 
MongoDbPpt based on python installation.
jnvcomputerlab2024
 
A Study on Mongodb Database
IJSRD
 
A Study on Mongodb Database.pdf
Jessica Navarro
 
MongoDB NoSQL database a deep dive -MyWhitePaper
Rajesh Kumar
 
Mongo Bb - NoSQL tutorial
Mohan Rathour
 
Mongodb Introduction
Nabeel Naqeebi
 
MongoDB DOC v1.5
Tharun Srinivasa
 
Basics of MongoDB
HabileLabs
 
MongoDB - An Introduction
sethfloydjr
 
Ad

More from Paulo Fagundes (11)

PDF
Oracle exalytics deployment for high availability
Paulo Fagundes
 
DOCX
Backup and Restore of database on 2-Node RAC
Paulo Fagundes
 
PDF
Zero Downtime for Oracle E-Business Suite on Oracle Exalogic
Paulo Fagundes
 
PDF
Mongodb
Paulo Fagundes
 
ODP
MongoDB - Javascript for your Data
Paulo Fagundes
 
PPTX
Capacityplanning
Paulo Fagundes
 
PDF
The Little MongoDB Book - Karl Seguin
Paulo Fagundes
 
PPTX
Mondodb
Paulo Fagundes
 
PDF
Oracle NoSQL Database Compared to Cassandra and HBase
Paulo Fagundes
 
PDF
The Power of Relationships in Your Big Data
Paulo Fagundes
 
PDF
Oracle NoSQL Database release 3.0 overview
Paulo Fagundes
 
Oracle exalytics deployment for high availability
Paulo Fagundes
 
Backup and Restore of database on 2-Node RAC
Paulo Fagundes
 
Zero Downtime for Oracle E-Business Suite on Oracle Exalogic
Paulo Fagundes
 
MongoDB - Javascript for your Data
Paulo Fagundes
 
Capacityplanning
Paulo Fagundes
 
The Little MongoDB Book - Karl Seguin
Paulo Fagundes
 
Oracle NoSQL Database Compared to Cassandra and HBase
Paulo Fagundes
 
The Power of Relationships in Your Big Data
Paulo Fagundes
 
Oracle NoSQL Database release 3.0 overview
Paulo Fagundes
 
Ad

Recently uploaded (20)

PDF
Staying Human in a Machine- Accelerated World
Catalin Jora
 
PDF
Newgen 2022-Forrester Newgen TEI_13 05 2022-The-Total-Economic-Impact-Newgen-...
darshakparmar
 
PDF
LOOPS in C Programming Language - Technology
RishabhDwivedi43
 
PDF
Transcript: Book industry state of the nation 2025 - Tech Forum 2025
BookNet Canada
 
PDF
“Voice Interfaces on a Budget: Building Real-time Speech Recognition on Low-c...
Edge AI and Vision Alliance
 
PDF
UPDF - AI PDF Editor & Converter Key Features
DealFuel
 
PDF
Future-Proof or Fall Behind? 10 Tech Trends You Can’t Afford to Ignore in 2025
DIGITALCONFEX
 
PDF
AI Agents in the Cloud: The Rise of Agentic Cloud Architecture
Lilly Gracia
 
PPTX
Seamless Tech Experiences Showcasing Cross-Platform App Design.pptx
presentifyai
 
PPTX
Agentforce World Tour Toronto '25 - MCP with MuleSoft
Alexandra N. Martinez
 
PDF
“Computer Vision at Sea: Automated Fish Tracking for Sustainable Fishing,” a ...
Edge AI and Vision Alliance
 
PPTX
Q2 FY26 Tableau User Group Leader Quarterly Call
lward7
 
PDF
UiPath DevConnect 2025: Agentic Automation Community User Group Meeting
DianaGray10
 
PDF
SIZING YOUR AIR CONDITIONER---A PRACTICAL GUIDE.pdf
Muhammad Rizwan Akram
 
PPTX
New ThousandEyes Product Innovations: Cisco Live June 2025
ThousandEyes
 
PPTX
MuleSoft MCP Support (Model Context Protocol) and Use Case Demo
shyamraj55
 
PDF
NASA A Researcher’s Guide to International Space Station : Physical Sciences ...
Dr. PANKAJ DHUSSA
 
PDF
Automating Feature Enrichment and Station Creation in Natural Gas Utility Net...
Safe Software
 
PDF
The 2025 InfraRed Report - Redpoint Ventures
Razin Mustafiz
 
PDF
Newgen Beyond Frankenstein_Build vs Buy_Digital_version.pdf
darshakparmar
 
Staying Human in a Machine- Accelerated World
Catalin Jora
 
Newgen 2022-Forrester Newgen TEI_13 05 2022-The-Total-Economic-Impact-Newgen-...
darshakparmar
 
LOOPS in C Programming Language - Technology
RishabhDwivedi43
 
Transcript: Book industry state of the nation 2025 - Tech Forum 2025
BookNet Canada
 
“Voice Interfaces on a Budget: Building Real-time Speech Recognition on Low-c...
Edge AI and Vision Alliance
 
UPDF - AI PDF Editor & Converter Key Features
DealFuel
 
Future-Proof or Fall Behind? 10 Tech Trends You Can’t Afford to Ignore in 2025
DIGITALCONFEX
 
AI Agents in the Cloud: The Rise of Agentic Cloud Architecture
Lilly Gracia
 
Seamless Tech Experiences Showcasing Cross-Platform App Design.pptx
presentifyai
 
Agentforce World Tour Toronto '25 - MCP with MuleSoft
Alexandra N. Martinez
 
“Computer Vision at Sea: Automated Fish Tracking for Sustainable Fishing,” a ...
Edge AI and Vision Alliance
 
Q2 FY26 Tableau User Group Leader Quarterly Call
lward7
 
UiPath DevConnect 2025: Agentic Automation Community User Group Meeting
DianaGray10
 
SIZING YOUR AIR CONDITIONER---A PRACTICAL GUIDE.pdf
Muhammad Rizwan Akram
 
New ThousandEyes Product Innovations: Cisco Live June 2025
ThousandEyes
 
MuleSoft MCP Support (Model Context Protocol) and Use Case Demo
shyamraj55
 
NASA A Researcher’s Guide to International Space Station : Physical Sciences ...
Dr. PANKAJ DHUSSA
 
Automating Feature Enrichment and Station Creation in Natural Gas Utility Net...
Safe Software
 
The 2025 InfraRed Report - Redpoint Ventures
Razin Mustafiz
 
Newgen Beyond Frankenstein_Build vs Buy_Digital_version.pdf
darshakparmar
 

MongoDB for the SQL Server

Editor's Notes

  • #3: Source - http://www.10gen.com/what-is-mongodb
  • #4: https://www.youtube.com/watch?v=k2YFy5IQu1M
  • #5: http://www.mongodb.org/downloads https://github.com/mongodb/mongo-csharp-driver/downloads
  • #8: http://www.mongovue.com/
  • #12: http://amitpiplani.blogspot.com/2010/05/u-pick-2-selection-for-nosql-providers.html
  • #14: http://docs.mongodb.org/manual/faq/developers/#how-do-i-do-transactions-and-locking-in-mongodb
  • #15: http://www.10gen.com/reference
  • #17: http://www.mongodb.org/display/DOCS/Use+Cases
  • #18: http://www.mongodb.org/display/DOCS/Use+Cases
  • #20: Free conversion (CSV to JSON) - http://www.cparker15.com/code/utilities/csv-to-json/
  • #25: http://rickosborne.org/download/SQL-to-MongoDB.pdf
  • #27: http://www.mongovue.com/2010/06/29/find/
  • #32: http://api.mongodb.org/wiki/current/Aggregation.html
  • #34: http://docs.mongodb.org/manual/aggregation/ And http://docs.mongodb.org/manual/reference/sql-aggregation-comparison/
  • #39: http://www.mongovue.com/2010/09/14/updating-collections/
  • #41: http://learnmongo.com/posts/getting-started-with-mongodb-gridfs/ Example: http://stackoverflow.com/questions/4988436/mongodb-gridfs-with-c-how-to-store-files-such-as-images/10645816#10645816 Default chunk size is 256kb Db.fs.files Fs.chunk Upload.date.date()
  • #42: https://www.youtube.com/watch?v=NCp4n6xWw68
  • #43: http://www.youtube.com/watch?v=NCp4n6xWw68