1
0
mirror of synced 2024-12-15 07:36:03 +03:00
doctrine2/manual/codes/Working with objects - Component overview - Query - Fetching strategies.php

26 lines
469 B
PHP
Raw Normal View History

2006-07-24 01:08:06 +04:00
<?php
// select all users and load the data directly (Immediate fetching strategy)
$coll = $conn->query("FROM User-I");
2006-07-24 01:08:06 +04:00
// or
$coll = $conn->query("FROM User-IMMEDIATE");
2006-07-24 01:08:06 +04:00
// select all users and load the data in batches
$coll = $conn->query("FROM User-B");
2006-07-24 01:08:06 +04:00
// or
$coll = $conn->query("FROM User-BATCH");
2006-07-24 01:08:06 +04:00
// select all user and use lazy fetching
$coll = $conn->query("FROM User-L");
2006-07-24 01:08:06 +04:00
// or
$coll = $conn->query("FROM User-LAZY");
2006-07-24 01:08:06 +04:00
?>