SELECT
    t.id,
    t.shipped,
    c.code companyCode
FROM ticket t
    JOIN company c ON c.id = t.companyFk
WHERE t.id = ?