You are here:  » Search upper and lowercase


Search upper and lowercase

Submitted by Fuzzy on Mon, 2011-10-10 03:59 in

Having a similar issue to this post: http://www.pricetapestry.com/node/3414 which works great in stand alone form.

When Someone searches for say "Deus" they get correct listing results ie:

Deus Ex
Dues Ex Human Revolution
Deeus Ex Augmented Edition

If the search is made using the lowercase "deus" nothing is displayed.

Can that same redirect mod be used with the plugin?

Thanks Again.

Submitted by support on Mon, 2011-10-10 07:53

Hi Fuzzy,

That sounds like your database is defaulting to a binary collation rather than a general collation which causes queries to be case sensitive.

To fix this, try the following dbmod.php script. Create the file, and upload to your Price Tapestry installation folder and then browse to the script once to change the collation on the products table which should do the trick...

<?php
  
require("includes/common.php");
  
$sql "ALTER TABLE `".$config_databaseTablePrefix."products` CONVERT TO CHARACTER SET utf8 COLLATE utf8_general_ci";
  
database_queryModify($sql,$result);
  print 
"Done.";
?>

Hope this helps!
Cheers,
David.

Submitted by Fuzzy on Mon, 2011-10-10 12:07

Thanks again David, you are a champ.