Last active
December 17, 2015 09:29
-
-
Save bobmagicii/5587790 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
$sql = new m\Database\Query; | |
$sql->Select('*') | |
->From('dma_objects') | |
->NaturalJoin('dma_objects_vehicles') | |
->Where('obj_type="vehicle"')->AndWhere('u_id=:OwnerID') | |
->OrderBy('obj_time_created ASC'); | |
echo $sql; | |
// SELECT * | |
// FROM dma_objects | |
// NATURAL JOIN dma_objects_vehicles | |
// WHERE obj_type="vehicle" AND u_id=:OwnerID | |
// ORDER BY obj_time_created ASC |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment