Related Products displaying viewing product
I have a product details page. Product RS:
$query_ProductDetails = sprintf("SELECT * FROM Products WHERE ID = %s", GetSQLValueString($colname_ProductDetails, "int"));
I have a section where i display related product using SubCatID from Products
$query_RelatedProducts = "SELECT * FROM Products WHERE SubCatID IN (".$row_ProductDetails['SubCatID'].")";
Lets say i want to show just 3 related products. I don't want the existing product to be shown in related products.
How do we do this?