03-27-2018, 08:43 AM
i've just started using UserSpice. Enjoying how well it is structured and learning quickly. Some help with this would be great.
How would i query rows where column is 'like' or contains part of a string var?
Possibly the equivalent to below
$item= = 'car';
("SELECT * FROM table WHERE column LIKE '{3bc1fe685386cc4c3ab89a3f76566d8931e181ad17f08aed9ad73b30bf28114d}$item{3bc1fe685386cc4c3ab89a3f76566d8931e181ad17f08aed9ad73b30bf28114d}'");
//Most likely for $item I would be using:
$item= $ab->items;
//Cannot workout how to use
$db->query("SELECT * FROM table WHERE column 'LIKE' ?",array($item));
Thanks for your help!
How would i query rows where column is 'like' or contains part of a string var?
Possibly the equivalent to below
$item= = 'car';
("SELECT * FROM table WHERE column LIKE '{3bc1fe685386cc4c3ab89a3f76566d8931e181ad17f08aed9ad73b30bf28114d}$item{3bc1fe685386cc4c3ab89a3f76566d8931e181ad17f08aed9ad73b30bf28114d}'");
//Most likely for $item I would be using:
$item= $ab->items;
//Cannot workout how to use
$db->query("SELECT * FROM table WHERE column 'LIKE' ?",array($item));
Thanks for your help!