SELECT GROUP_CONCAT(g.good_issue_note_no) gin_nos, GROUP_CONCAT(e.eorder_no) as web_roder_nos ,i.* FROM `0p4_invoice` i
left join 0p4_good_issue_note g on FIND_IN_SET(g.id, i.good_issue_note_ids ) > 0 and g.type='GIE'
left join 0p4_eorder e on e.id=g.eorder_id
where i.type="EORDER" group by i.invoice_id





update `0p4_invoice` i
left join 0p4_good_issue_note g on FIND_IN_SET(g.id, i.good_issue_note_ids ) > 0 and g.type='GIE'
left join 0p4_eorder e on e.id=g.eorder_id
set g.web_roder_no=GROUP_CONCAT(e.eorder_no)
where i.type="EORDER" group by i.invoice_id