I have set my search page up and created the recordset below which works fine. The issue I am having is that if I search for Hello Kitty Bubble nothing is returned as the search is checking that the column description in the database contains the search phrase. The description in the database is Hello Kitty Single Bubble. I thought using the LIKE feature would return the record but it does not; if I search for Hello Kitty Single then the record is returned correctly. It seems as though records are only returned if the search phrase matches in the exact order it is stored in the database. Is this correct or is there a bug.
$rs_bubbles = new WA_MySQLi_RS("rs_bubbles",$dmbc_database,0);
$rs_bubbles->setQuery("SELECT products.id, products.itemnumber, products.description, products.categories, products.category_type, products.status, products.type, products.productdescription, products.typename, products.selling_quantity, products.price, products.image, products.imagelarge, products.volumediscount, products.supplier, products.supplierlogo, products.stock, products.onorder, products.packed, products.customer_back_orders, products.pending_online_orders, products.visible, products.product_arrival_date, special_prices.price AS special_price FROM products LEFT OUTER JOIN special_prices ON products.itemnumber = special_prices.itemnumber AND special_prices.userdetails_id = ? WHERE visible = 1 AND description LIKE ? AND category_type='Bubbles' OR visible = 1 AND keywords LIKE ? AND category_type='Bubbles' ORDER BY type, description ASC");
$rs_bubbles->bindParam("i", "".($rs_customer->getColumnVal("id")) ."", "-1"); //colname
$rs_bubbles->bindParam("c", "".(isset($_SESSION['keywords'])?$_SESSION['keywords']:"") ."", "-1"); //colname1
$rs_bubbles->bindParam("c", "".(isset($_SESSION['keywords'])?$_SESSION['keywords']:"") ."", "-1"); //colname2