---
name: Doctrine Fetch Modes
slug: doctrine-fetch-modes
category: Quality
description: Doctrine Fetch Modes helps tune Doctrine fetching with DTO hydration, lazy loading, query hints, and DBAL 4 access. Use it when improving relation mapping, query performance, or avoiding N+1 issues.
github: "https://github.com/dev-toolings/superpowers-symfony/tree/main/skills/doctrine-fetch-modes"
language: TypeScript
stars: 208
forks: 20
install: "npx degit https://github.com/dev-toolings/superpowers-symfony/tree/main/skills/doctrine-fetch-modes ~/.claude/skills/doctrine-fetch-modes"
installs_to: ~/.claude/skills/doctrine-fetch-modes
source_path: skills/doctrine-fetch-modes/SKILL.md
collection_size: 23
category_size: 1557
collection_url: "https://dirskills.com/collections/dev-toolings/superpowers-symfony"
added: 2026-09-04T05:27:06.727Z
last_synced: 2026-09-04T05:27:06.727Z
canonical_url: "https://dirskills.com/skills/doctrine-fetch-modes"
---

# Doctrine Fetch Modes

Doctrine Fetch Modes helps tune Doctrine fetching with DTO hydration, lazy loading, query hints, and DBAL 4 access. Use it when improving relation mapping, query performance, or avoiding N+1 issues.

**Install:**

```bash
npx degit https://github.com/dev-toolings/superpowers-symfony/tree/main/skills/doctrine-fetch-modes ~/.claude/skills/doctrine-fetch-modes
```

## README

# Doctrine Fetch Modes (Symfony)

## Use when
- Designing entity relations or schema evolution.
- Improving Doctrine correctness/performance.

## Default workflow
1. Model ownership/cardinality and transactional boundaries.
2. Apply mapping/schema changes with migration safety.
3. Tune fetch/query behavior for hot paths.
4. Verify lifecycle behavior with targeted tests.

## Guardrails
- Keep owning/inverse sides coherent.
- Avoid destructive migration jumps in one release.
- Eliminate accidental N+1 and over-fetching.

## Progressive disclosure
- Use this file for execution posture and risk controls.
- Open references when deep implementation details are needed.

## Output contract
- Entity/migration changes.
- Integrity and performance decisions.
- Validation outcomes and rollback notes.

## References
- `reference.md`
- `docs/complexity-tiers.md`
