| | 82 | 定时任务 |
| | 83 | {{{ |
| | 84 | insert into ent_company_product_line(company_id,brand_id,small_type_id, big_type_id, last_update_date) |
| | 85 | select distinct a.user_id as company_id, a.type_id as brand_id, b.parent_id as small_type_id, c.parent_id as big_type_id, now() |
| | 86 | from ent_product a,v_pdl_product_type b, v_pdl_product_type c |
| | 87 | where a.type_id = b.id and b.parent_id = c.id and not exists ( |
| | 88 | select z.company_id from ent_company_product_line z |
| | 89 | where z.company_id = a.user_id and z.brand_id = a.type_id and z.small_type_id = c.id and z.big_type_id = c.parent_id |
| | 90 | ) |
| | 91 | }}} |