mysqli - PHP MYSQL query WHERE statement - Returns also rows where the condition is not met

one text

Solution:

because submitId is a varchar, you should use character 's' instead of 'i' for bind_param method(character 's' uses for bind string data type or varchar while 'i' uses for integers) so try something like below..

 $stmt->bind_param("s", $reportId);

Source