@id 是作为参数穿进去的,你调用存储过程的时候没有在后面家参数!
应该象这样 
declare @tempid char(5)
exec p_get_DrugName_Max_Innerid @tempid