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
MongoDB 101
Search
Leszek Krupiński
July 15, 2013
Programming
0
89
MongoDB 101
Wprowadzenie do dokumentowej bazy danych
Leszek Krupiński
July 15, 2013
Tweet
Share
More Decks by Leszek Krupiński
See All by Leszek Krupiński
So that the daemon won’t die
leafnode
2
390
Practical PHP7
leafnode
2
410
Dobrze posól swoje hasło
leafnode
0
80
Dobrze posól swoje hasło (z notatkami)
leafnode
0
68
PHPNG kontra HHVM
leafnode
0
79
PHPNG kontra HHVM (z notatkami)
leafnode
0
45
Ewolucja PHP: PHP 5.6, NG, PHP 7, HHVM
leafnode
2
280
Sculpin - Generowanie statycznych stron w PHP
leafnode
2
51
Skalowanie aplikacji PHP
leafnode
1
390
Other Decks in Programming
See All in Programming
Outline View in SwiftUI
1024jp
1
310
CSC509 Lecture 11
javiergs
PRO
0
180
카카오페이는 어떻게 수천만 결제를 처리할까? 우아한 결제 분산락 노하우
kakao
PRO
0
110
【Kaigi on Rails 2024】YOUTRUST スポンサーLT
krpk1900
1
320
Click-free releases & the making of a CLI app
oheyadam
2
110
ピラミッド、アイスクリームコーン、SMURF: 自動テストの最適バランスを求めて / Pyramid Ice-Cream-Cone and SMURF
twada
PRO
10
1.2k
シェーダーで魅せるMapLibreの動的ラスタータイル
satoshi7190
1
470
PLoP 2024: The evolution of the microservice architecture pattern language
cer
PRO
0
2.6k
TypeScriptでライブラリとの依存を限定的にする方法
tutinoko
2
560
What’s New in Compose Multiplatform - A Live Tour (droidcon London 2024)
zsmb
1
470
subpath importsで始めるモック生活
10tera
0
240
Ethereum_.pdf
nekomatu
0
440
Featured
See All Featured
The Success of Rails: Ensuring Growth for the Next 100 Years
eileencodes
44
6.8k
How to Create Impact in a Changing Tech Landscape [PerfNow 2023]
tammyeverts
47
2.1k
CSS Pre-Processors: Stylus, Less & Sass
bermonpainter
356
29k
Being A Developer After 40
akosma
86
590k
5 minutes of I Can Smell Your CMS
philhawksworth
202
19k
Why You Should Never Use an ORM
jnunemaker
PRO
54
9k
Designing Experiences People Love
moore
138
23k
Scaling GitHub
holman
458
140k
Happy Clients
brianwarren
98
6.7k
[Rails World 2023 - Day 1 Closing Keynote] - The Magic of Rails
eileencodes
33
1.8k
[RailsConf 2023] Rails as a piece of cake
palkan
51
4.9k
Understanding Cognitive Biases in Performance Measurement
bluesmoon
26
1.4k
Transcript
MONGODB 101 Wprowadzenie do dokumentowej bazy danych PHPers.02 15 lipca
2013 Leszek Krupiński @leafnode Monday, July 15, 13
PODSTAWY NoSQL i dokumentowe bazy danych Monday, July 15, 13
MONGODB Baza dokumentowa, object store Monday, July 15, 13
REPLIKACJA I SHARDING OOTB Monday, July 15, 13
GEOSPATIAL INDEX Monday, July 15, 13
JSON BSON { _id : ObjectId("51d66af57d3afb7a973b00ab"), username : 'foo', firstName
: 'Jan', lastName : 'Kowalski', address : { street : 'Marszałkowska 12', city : 'Warszawa', zip : '00-950' } friends : [ 'janek', 'mirek', 'wiesiek' ] } Monday, July 15, 13
ZAPYTANIA CRUD Monday, July 15, 13
FIND Monday, July 15, 13
INSERT Monday, July 15, 13
UPDATE 3 sposoby na update Monday, July 15, 13
REMOVE Monday, July 15, 13
PROJEKTOWANIE SCHEMATU Schemaless != Nie planuj Monday, July 15, 13
MODEL RELACYJNY Monday, July 15, 13
MODEL DOKUMENTOWY { _id : ObjectId("51d66af57d3afb7a973b00ab"), author : 'janek', title
: 'Ciekawy post', body : 'Lorem Ipsum', date : ISODate("2012-12-19T20:10:56.920Z"), tags : [ 'lorem', 'testowe', 'z życia wzięte' ], comments : [ { author : 'Anonim', date : ISODate("2012-12-19T20:10:56.920Z"), body : 'Nuda!' }, { author : 'Zdzisiek', date : ISODate("2012-12-19T20:10:56.920Z"), body : 'Wcale nie nuda.' } ] } Monday, July 15, 13
GEOSPATIAL INDEX db.places.ensureIndex( { location: ‘2d’ } ) Monday, July
15, 13
db.places.find( { location: { $near: [ 52, 21 ] }
} ) Monday, July 15, 13
MONGODB I PHP pecl install mongo Monday, July 15, 13
DEMO Monday, July 15, 13
DOCTRINE DEMO Monday, July 15, 13
NOTKA $qb = $dm->createQueryBuilder('Application_Model_Entry') ->field('club.$id')->equals(new MongoId($club->getId())); Monday, July 15, 13