INSERT INTO applyinfo_repeal (
business_num,
identify_organization_id
) SELECT
applyNumber,
identifyOrganizationId
FROM
applyinfo a
LEFT JOIN enterprise_applicant e ON a.app_ent_id = e.id
WHERE
e.enterprise_name = 'test公司'
AND a.`status` = 9
AND a.create_date >= '2017-05-18'
business_num,
identify_organization_id
) SELECT
applyNumber,
identifyOrganizationId
FROM
applyinfo a
LEFT JOIN enterprise_applicant e ON a.app_ent_id = e.id
WHERE
e.enterprise_name = 'test公司'
AND a.`status` = 9
AND a.create_date >= '2017-05-18'