Hi,
I'm hoping someone can help with this..
I have a query which returns a list of all of the products in a particular food category (see query below) for use in site navigation. Now the client has introduced variations (refills, large and small). So now I have to filter the products SKU code ( products_model ) to only show the base products
The base products SKU look like this..
D0165
D0132
D0953
..while the variations have a letter attached
D0165R
D0165T
Question is, how do I add something like
"and where products_model does not contain any letters"
Thank's for reading
-Stephen
##Query##
$query = product_db_query("select p.products_id, p.products_name from products p, products_to_categories p2c where p.products_status = '1' and p.products_id = p2c.products_id and p2c.categories_id = '" . $current_category_id . "' order by p.products_name");
I'm hoping someone can help with this..
I have a query which returns a list of all of the products in a particular food category (see query below) for use in site navigation. Now the client has introduced variations (refills, large and small). So now I have to filter the products SKU code ( products_model ) to only show the base products
The base products SKU look like this..
D0165
D0132
D0953
..while the variations have a letter attached
D0165R
D0165T
Question is, how do I add something like
"and where products_model does not contain any letters"
Thank's for reading
-Stephen
##Query##
$query = product_db_query("select p.products_id, p.products_name from products p, products_to_categories p2c where p.products_status = '1' and p.products_id = p2c.products_id and p2c.categories_id = '" . $current_category_id . "' order by p.products_name");