select s.specification_id s.specification c.contract_id c.contract u.usr_id u.login z.contragent_id z.contragent z.external_code from specification s left outer join contract c on (s.contract_id=c.contract_id) left outer join usr u on (c.contragent_id=u.contragent_id) left outer join contragent z on (u.contragent_id=z.contragent_id) where u.usr_id= order by specification_id desc;