OLAP and OLTP \

oltp are the transaction based db systems where you focus on transactions like create , update , read , delete and ensure that a transaction happens atomicity and consistency these are the row oriented db and used for most of the services to handle data , olap on the other hand are focused on the data analysis , these are column oriented

chap 2

data organisation in general , most of the time read is larger than writes

how you write has different performance issue than how you read so we have to look into tradeoffs

Screenshot 2026-09-09 at 10.00.57 AM.png

on write it takes effort , but on read which is large number of operations that will be easier

binary search trees why not use this for db always

io devices work with pages like 8 kb chunks

b+ trees

Screenshot 2026-09-09 at 10.30.55 AM.png

each node can fit in a 8,16 kb page on disk

sometimes leaf node can contain the data sometime only the pointer to the location of data

mysql stores data in clustered index ,

row data is stored in leaf

postgres does this differently

postgres

l-3