From 38134d96c3638b825ca60aa197e8c10241829e48 Mon Sep 17 00:00:00 2001 From: John A Costa III Date: Tue, 6 Dec 2016 18:09:49 -0500 Subject: [PATCH] Update Report_Sales.php --- adminPages/Report_Sales.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/adminPages/Report_Sales.php b/adminPages/Report_Sales.php index 0c208d0..aa26aea 100644 --- a/adminPages/Report_Sales.php +++ b/adminPages/Report_Sales.php @@ -17,7 +17,7 @@ require("../commonFunctions.php"); if (isset($_GET['Category'])){ //Check if category has already been set $query = "SELECT * FROM `sales by category` WHERE CategoryID = ? AND ProductName = ? "; //'?' in place of variable - $ProductName = % . $_GET['ProductName'] . %; + $ProductName = "%" . $_GET['ProductName'] . "%"; $stmt = $con->prepare($query); $stmt ->bind_param("ds", $_GET['Category'], $ProductName); //Bind category to query, category is taken in as CategoryID, so it's a digit $stmt ->execute();