Details
-
Bug
-
Status: Closed (View Workflow)
-
Resolution: Incomplete
-
None
-
None
-
None
Description
I have a very simple table like this:
CREATE TABLE `path` (
`PID` int(10) unsigned NOT NULL,
`PPath` varchar(2000) NOT NULL,
`PHash` binary(16) NOT NULL,
PRIMARY KEY (`id`)
) ENGINE=InnoDB;
And a SP:
create procedure test(path VARCHAR(2000))
begin
DECLARE pid INT UNSIGNED;
DECLARE hash BINARY(16) DEFAULT UNHEX(MD5(path));
SELECT PID FROM path LIMIT 1;
end|
call test("/")|
Calling the procedure test() returns NULL. Upper and lower case doesn't matter. Renaming the column to something different like
alter table path change PID id int unsigned;
returns the correct result.