CodeIgniter Forums
Database Query Problem. - Printable Version

+- CodeIgniter Forums (https://forum.codeigniter.com)
+-- Forum: Archived Discussions (https://forum.codeigniter.com/forum-20.html)
+--- Forum: Archived Libraries & Helpers (https://forum.codeigniter.com/forum-22.html)
+--- Thread: Database Query Problem. (/thread-47871.html)



Database Query Problem. - El Forum - 12-26-2011

[eluser]Unknown[/eluser]
I have a date field in the database . Inorder to get the year of the date I am using the SQL feature "YEAR(column_name)" . my problem is the query is executing but i am not able to echo it int the view file whenever i use $data-> YEAR(Column_name); it returns an error.