prepare($sql); $stmt->execute(); $row = $stmt->fetchAll(PDO::FETCH_ASSOC); if ($row){ // Fetch the record // $row = $stmt->fetchAll(PDO::FETCH_ASSOC); printSuccess( $row); } else{ // Print a failure message printFailure($message = "No Kazan record found"); } ?>