Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Speaker Deck
PRO
Sign in
Sign up for free
Fun with Django and Databases
Andrew Godwin
July 19, 2010
Programming
0
44
Fun with Django and Databases
A talk I gave at EuroPython 2010
Andrew Godwin
July 19, 2010
Tweet
Share
More Decks by Andrew Godwin
See All by Andrew Godwin
Writing Maintainable Software At Scale
andrewgodwin
0
190
A Newcomer's Guide To Airflow's Architecture
andrewgodwin
0
150
Async, Python, and the Future
andrewgodwin
2
440
How To Break Django: With Async
andrewgodwin
1
420
Taking Django's ORM Async
andrewgodwin
0
410
The Long Road To Asynchrony
andrewgodwin
0
420
The Scientist & The Engineer
andrewgodwin
1
450
Pioneering Real-Time
andrewgodwin
0
200
Just Add Await: Retrofitting Async Into Django
andrewgodwin
2
1.2k
Other Decks in Programming
See All in Programming
社会人 20 年目エンジニア、発信で技術学びなおしてる話
e99h2121
1
140
Unity+C#で学ぶ! メモリレイアウトとvtableのすゝめ 〜動的ポリモーフィズムを実現する仕組み〜
rossam
1
120
AWSにおける標的型Bot対策
hacomono
0
420
Ruby Pattern Matching
bkuhlmann
0
610
Milestoner
bkuhlmann
1
240
TSX First な Zero-Runtime SSG potato4d/dodai とその仕組み / owned static site generator #kyotojs
potato4d
0
270
Micro Frontends with Module Federation @MicroFrontend Summit 2023
manfredsteyer
PRO
0
570
AWS App Runnerがそろそろ本番環境でも使い物になりそう
n1215
PRO
0
1.1k
花き業界のサプライチェーンを繋げるプロダクト開発の進め方
userlike1
0
170
23年のJavaトレンドは?Quarkusで理解するコンテナネイティブJava
tatsuya1bm
1
120
xarray-Datatree: Hierarchical Data Structures for Multi-Model Science
tomnicholas
0
220
Zynq MP SoC で楽しむエッジコンピューティング ~RTLプログラミングのススメ~
ryuz88
0
370
Featured
See All Featured
10 Git Anti Patterns You Should be Aware of
lemiorhan
643
54k
Designing for Performance
lara
600
65k
The MySQL Ecosystem @ GitHub 2015
samlambert
240
11k
Robots, Beer and Maslow
schacon
154
7.3k
What’s in a name? Adding method to the madness
productmarketing
12
1.9k
Designing the Hi-DPI Web
ddemaree
273
32k
For a Future-Friendly Web
brad_frost
166
7.8k
Design and Strategy: How to Deal with People Who Don’t "Get" Design
morganepeng
109
16k
How GitHub Uses GitHub to Build GitHub
holman
465
280k
Web Components: a chance to create the future
zenorocha
304
40k
What the flash - Photography Introduction
edds
64
10k
Learning to Love Humans: Emotional Interface Design
aarron
263
38k
Transcript
Django and Databases Fun with
""Andrew speaks English like a machine gun speaks bullets."" Reinout
van Rees
Introduction
from django.db import models
First, an aside
""When all you have is a hammer, everything looks like
a nail"" Abraham Manslow (paraphrased)
Also, "NoSQL"? Really?
queryset.raw()
qs = Teacher.objects.raw(""" SELECT t.name, COUNT(s.id) FROM school_teacher AS t
INNER JOIN school_student AS s ON t.id = s.teacher_id GROUP BY t.name HAVING COUNT(s.id) > 2 """)
queryset.aggregate()
qs = Teacher.objects.annotate( num_students = models.Count('student') ).filter(num_students__gt=2)
Search haystack __search=
Schema Changes
Changing Requirements
Dynamic/Unknown Data
Document Databases MongoDB CouchDB
Key-Value Stores Redis Cassandra
Redis Sets Sorted Sets Hashes Pub/Sub Atomicity
Message Queues AMQP Celery
Various Others Graph databases Filesystems VCSs
Conclusion
Thanks. Andrew Godwin @andrewgodwin http://aeracode.org