Doctrine 2 versus NotORM

Part 2: Data storage

These tutorials show the same demo application created in Doctrine 2 and in NotORM. You can play one whole video and then the other or you can switch playing both videos (watch for checkpoints).

Doctrine 2 video tutorial

Screencast

Download source codes (versioned in Git)

NotORM video tutorial

Screencast

Download source codes (versioned in Git)

Doctrine 2 WTFs

  1. One select for each insert (can be solved by using getReference instead of find)
  2. No error for wrong reference (can be solved by using getReference instead of find)
  3. No error for non-existing fields (can be solved by defining setters)
  4. No error for invalid data (can be solved by using strict mode in MySQL but not in SQLite)
  5. Manual locking and transaction handling for incrementing a column (can by bypassed by using DQL)
  6. One query for each loop iteration (can be bypassed by using DQL)
  7. Auto-generated code for proxy

Author: Jakub Vrána. It is allowed to re-publish only both videos together.