I am attempting a calculated field using the __sql__ construct in the fields.ini file:
- Code: Select all
__sql__ = "SELECT p.*,datediff(curdate(),birthdate) as age from Participants as p"
However, I get the following error:
Fatal error: Cannot use object of type PEAR_Error as array in /var/www/private/dataface/Dataface/Table.php on line 1789
If I just use curdate() it works, however other expressions (e.g. curdate()-birthdate) do not.
???