Page 1 of 1

Unknown column 'Projects1.id' in 'on clause'

Posted: 2016-03-25 15:00
by omackeytech
I have no table in my database called Projects1.
I get this error when I try to create a look up field based on my Projects Table.
I have two forms that use this look up field and both generate the same error.
If I remove the look up reference and generate the code the error goes away.
No error appears in the php error_log or mysql logs.
This used to work, when I upgraded so I could use the Search Page Maker and regenerated the code the problem began.
It appears to be coming either from these lines of code in incCommon.php

Line 158: 'Time_Entry' => "`Time_Entry` LEFT JOIN `Projects` as Projects1 ON `Projects1`.`id`=`Time_Entry`.`Project` ",
Line 159: 'Expenses' => "`Expenses` LEFT JOIN `Projects` as Projects1 ON `Projects1`.`id`=`Expenses`.`Project` ",

Or in this line in Time_Entry_view.php and Expences_view.php.

Line 79: $x->QueryFrom="`Time_Entry` LEFT JOIN `Projects` as Projects1 ON `Projects1`.`id`=`Time_Entry`.`Project` ";
Line 87: $x->QueryFrom="`Expenses` LEFT JOIN `Projects` as Projects1 ON `Projects1`.`id`=`Expenses`.`Project` ";

Any idea what is going on?

Thank you,
Brian