Kaptain.
Telegram /
LinkedIn /
Email /
GIT /
RSS /
GPG /
Заказ печатных плат

№ 4275 В разделе
Programming
от May 11th, 2012,
В подшивках: CodeIgniter, PHP
Sometimes you need to make porno like this:
SELECT blablabla
FROM (`blablabla`)
WHERE `blabla` = bla
AND `blabla` = 100500
AND ( `blabla` LIKE '%14%'
OR `blablabla` LIKE '%14%' )
CodeIgniter can’t add brackets out of box, but I created patch that help you to solve this problem. Download this file DB_active_rec.php.patch and patch you /system/database/DB_active_rec.php.
Now you can use it:
$this->db->or_like('( dogovor_num',$str);
$this->db->or_like("podkluchenie.kvartira",$str,'both'," ) ");
Fortune cookie: When I was a baby, my penis Was as white as the buttocks of Venus. But now 'this as red As her nipples instead-- All because of the feminie genus!
Leave a Reply