I was looking for something that is related to a mysql query and I stumbled to this link mysql variable usage and saw the stored proc-like variable setting. I've tried it in phpmyadmin :
SET @value = 5; SELECT @rank;
and it is working, but when I tried to place it in PDO statements, it does not work.
$value = "SET @value = 0";
$stmt = $this->_dbHandle->prepare($value);
$stmt->execute();
Kindly guide on what I am doing wrong.