In the arrayref syntax of table joins, I allow table names to appear with aliases, like so:
$db->select([
\'people AS parents',
[\'people AS children', 'children.parent_id' => 'parents.id'],
]);
Motivation
This change is necessary, in order to allow a table to join itself in a query. Without this change, one would have to write a long SCALARREF instead of the arrayref syntax, like so:
$db->select(\'people AS parents JOIN people AS children ON (children.parent_id = parents.id)');
Summary
In the arrayref syntax of table joins, I allow table names to appear with aliases, like so:
Motivation
This change is necessary, in order to allow a table to join itself in a query. Without this change, one would have to write a long SCALARREF instead of the arrayref syntax, like so:
References
3