select i.itemid, dbo.ve_GetShortPath(i.itemid), c.Type, c.Text from parts p 
join items i on i.itemid = p.itemid 
join contents c on c.contentid = i.contentid
where fromtype = 7