[Reference](/docs) · by task

# Store data

Entities, references and migrations, then the queries and writes that read and change them. Read them in this order. Each page links to the pages around it.

1.  [Entities and the id](/docs/entities-and-the-id)
    
    An entity is a kind of stored record with a lasting identity.
    
2.  [Fields and their settings](/docs/fields-and-their-settings)
    
    A field's settings, such as `generated:`, `unique:` and `on_delete:`, go in a block after its type, one per line:
    
3.  [Unique rules](/docs/unique-rules)
    
    `unique: true` in a field's block means no two records may hold the same value in that field.
    
4.  [References and on\_delete](/docs/references-and-on-delete)
    
    Any field typed `X.id` is a reference to a record of `X`.
    
5.  [Lifecycle](/docs/lifecycle)
    
    A lifecycle describes the stages a record goes through and when it drops out of normal view.
    
6.  [Migrations](/docs/migrations)
    
    Entities describe the schema you want.
    
7.  [Named queries](/docs/named-queries)
    
    Every read of stored records is a named query.
    
8.  [Filters](/docs/filters)
    
    Each `where:` line is one condition, and a record must meet all of them.
    
9.  [Order and pages](/docs/order-and-pages)
    
    `order:` lists fields, each with `asc` or `desc`.
    
10.  [The operations every entity gets](/docs/the-operations-every-entity-gets)
     
     Every entity gets these operations, called through the entity's name, as `Todo.get(todo_id)`.
     
11.  [When a write is refused](/docs/when-a-write-is-refused)
     
     A write can be refused for two reasons, and a lifecycle transition for a third, when its `when:` doesn't hold (Transitions, above):
     
12.  [All-or-nothing actions and concurrent changes](/docs/all-or-nothing-actions-and-concurrent-changes)
     
     Every action is all-or-nothing (Functions and actions): its writes, and those of the public actions it calls, commit together or not at all.
