Ok I have several tables that have as the first field a field named "Div". When I try to access any of those fields I get the following error:
Fatal error: Error retrieving title from database in Dataface_QueryTool::getTitles(): SELECT RecordID,DIV as __titleColumn__ FROM PUDTL LIMIT 250You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'DIV as __titleColumn__ FROM PUDTL LIMIT 250' at line 1
On line 111 of file E:\xamp\xampp\htdocs\xampp\dataface\Dataface\QueryTool.php in function printStackTrace()
On line 205 of file E:\xamp\xampp\htdocs\xampp\dataface\Dataface\ResultController.php in function getTitles(,1,1)
On line 294 of file E:\xamp\xampp\htdocs\xampp\dataface\Dataface\ResultController.php in function getContentsList()
On line 458 of file E:\xamp\xampp\htdocs\xampp\dataface\Dataface\TableView.php in function toHtml()
On line 1149 of file E:\xamp\xampp\htdocs\xampp\dataface\Dataface\TableView.php in function _controller()
On line 452 of file E:\xamp\xampp\htdocs\xampp\dataface\Dataface\Application.php in function toHtml()
On line 26 of file E:\xamp\ in E:\xamp\xampp\htdocs\xampp\dataface\Dataface\QueryTool.php on line 111
Now if I move div to the FOURTH position then the error ceases. If it is in the first, second or third position it continues. Or if I rename the field the error ceases.
I've not had an opportunity to look over your code yet so I am only guessing at the following (plus I am only learning PHP now..so even then it would be perhaps a guess.) But when I run an SQL query on phpMyAdmin, I notice that each field name is surrounded by single quotes. But in the error msg again for the SQL statement, there is no quotes around the field names. So I am guessing that perhaps div is an SQL statement of some sort?
Now I can and will just rename the fields to Division instead of DIV for now. But it is something I thought we should be aware of.
Holler.