Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Geospatial Indexing with MongoDB
Search
Sponsored
·
Ship Features Fearlessly
Turn features on and off without deploys. Used by thousands of Ruby developers.
→
20spokes
January 22, 2012
Programming
3
110
Geospatial Indexing with MongoDB
20spokes
January 22, 2012
Tweet
Share
More Decks by 20spokes
See All by 20spokes
Start Your Startup: The Essential Steps to Launch Your Idea
ryan_fischer
1
85
Intro to MongoDB (Updated)
ryan_fischer
2
87
Intro to MongoDB
ryan_fischer
2
250
MongoDB and Ruby on Rails
ryan_fischer
2
180
Other Decks in Programming
See All in Programming
Oxlint JS plugins
kazupon
1
950
なぜSQLはAIぽく見えるのか/why does SQL look AI like
florets1
0
460
CSC307 Lecture 03
javiergs
PRO
1
490
Implementation Patterns
denyspoltorak
0
290
CSC307 Lecture 02
javiergs
PRO
1
780
dchart: charts from deck markup
ajstarks
3
990
開発者から情シスまで - 多様なユーザー層に届けるAPI提供戦略 / Postman API Night Okinawa 2026 Winter
tasshi
0
200
IFSによる形状設計/デモシーンの魅力 @ 慶應大学SFC
gam0022
1
300
AIエージェント、”どう作るか”で差は出るか? / AI Agents: Does the "How" Make a Difference?
rkaga
4
2k
Best-Practices-for-Cortex-Analyst-and-AI-Agent
ryotaroikeda
1
110
コントリビューターによるDenoのすゝめ / Deno Recommendations by a Contributor
petamoriken
0
200
なるべく楽してバックエンドに型をつけたい!(楽とは言ってない)
hibiki_cube
0
140
Featured
See All Featured
Agile Leadership in an Agile Organization
kimpetersen
PRO
0
82
Efficient Content Optimization with Google Search Console & Apps Script
katarinadahlin
PRO
1
320
Performance Is Good for Brains [We Love Speed 2024]
tammyeverts
12
1.4k
Everyday Curiosity
cassininazir
0
130
Designing for Performance
lara
610
70k
Data-driven link building: lessons from a $708K investment (BrightonSEO talk)
szymonslowik
1
910
Test your architecture with Archunit
thirion
1
2.2k
[RailsConf 2023 Opening Keynote] The Magic of Rails
eileencodes
31
9.9k
The Illustrated Children's Guide to Kubernetes
chrisshort
51
51k
Fantastic passwords and where to find them - at NoRuKo
philnash
52
3.6k
Optimizing for Happiness
mojombo
379
71k
How People are Using Generative and Agentic AI to Supercharge Their Products, Projects, Services and Value Streams Today
helenjbeal
1
120
Transcript
Geospatial Indexing Ryan Fischer @ryanfischer20 Tuesday, November 15, 11
What is covered The most amazing slides ever to be
displayed Getting Started with Geospatial Indexing A real live working session of the most amazing code How many times I say ‘um’ Tuesday, November 15, 11
geospatial Tuesday, November 15, 11
simple Tuesday, November 15, 11
SQL SELECT * FROM Places WHERE acos(sin(1.3963) * sin(Lat) +
cos(1.3963) * cos(Lat) * cos(Lon - (-0.6981))) * 6371 <= 1000; Tuesday, November 15, 11
MongoDB db.places.find({loc : { $near:[50,50] } } ) Tuesday, November
15, 11
how do you want to search? Tuesday, November 15, 11
Exact Queries Search by closest points Tuesday, November 15, 11
Query within a rectangle Circle with a center point and
radius Search within a polygon ( >= 1.9 ) Bound Queries Tuesday, November 15, 11
The earth is round (seriously) Tuesday, November 15, 11
Tuesday, November 15, 11
Tuesday, November 15, 11
Spherical Model Use decimal degrees - 42.53 Use [longitude, latitude]
as ordering Use radians for distance $nearSphere and $centerSphere Tuesday, November 15, 11
geoNear returns distance for object db.runCommand({ geoNear: "persons", near: [50,50]
}) Tuesday, November 15, 11
Multi-location Documents objects can contain sub-objects for multiple locations can
show up more than once in location queries Tuesday, November 15, 11
Sharding Now supported Can only use geoNear command MongoDB is
still young Tuesday, November 15, 11
MongoDB meets Ruby Tuesday, November 15, 11
The End Follow me - @ryanfischer20 Tuesday, November 15, 11
Tuesday, November 15, 11