Calculate 2 fields with Active records - Printable Version +- CodeIgniter Forums (https://forum.codeigniter.com) +-- Forum: Using CodeIgniter (https://forum.codeigniter.com/forumdisplay.php?fid=5) +--- Forum: General Help (https://forum.codeigniter.com/forumdisplay.php?fid=24) +--- Thread: Calculate 2 fields with Active records (/showthread.php?tid=69155) |
Calculate 2 fields with Active records - manhvt - 10-14-2017 I have a table with fields I want to looking for some records expired date in 6days. today - test_time (created date) < duration - 6 days My code don't work Code: $this->db->select("test.*"); Quote:Error Number: 1064 Please help me. Thanks. ho RE: Calculate 2 fields with Active records - Kaosweaver - 10-16-2017 Try: PHP Code: $this->db->where("(duration * con) <=", $next7day); |