/blockdata in chests creates ghost items
if you use setdata on a chest to put items in it, the items cant be shift-clicked out. and if you put them in the hotbar and right click they dissaparear
try
/blockdata ~ ~1 ~ {Items:[
]}
on a commandblock that has a chest above, put the resulting sword in your hotbar, and right click