cphalcon icon indicating copy to clipboard operation
cphalcon copied to clipboard

[2.0.0][ORM][Query Builder] issue

Open eclipse88 opened this issue 11 years ago • 1 comments

$result =$builder->from(['Table1' => 'Table1'])
    ->columns(['Table1.*', 'Table2.*', 'Table3.*'])
    ->join('Table2', 'Table1.id = Table2.tb2_id', 'Table2')
    ->join('Table3', 'Table1.id = Table3.tb3_id', 'Table3')
    ->getQuery()
    ->execute();
$result->toArray();

on my server(ubuntu 12.0.4) returning an empty array, but when i try from windows on same db and with same phalcon version(2.0.0) is returning an array with records(the expected result).

I notice if i let one parameter in columns: Ex: ->columns(['Table1.* ']) or ->columns(['Table2.* ']) is working.

In 1.3.4 was working properly

eclipse88 avatar Apr 21 '15 07:04 eclipse88

Check that your files match the same case sensitiveness as the models you're using in the Query.

andresgutierrez avatar Jun 16 '15 01:06 andresgutierrez