--
-- Script de migration des données contenues dans la table llx_gpaoplus_element_time vers la table standard llx_element_time
--

INSERT INTO llx_element_time
(fk_element, elementtype, element_date, element_datehour, element_date_withhour, element_duration,
    fk_product, fk_user, thm, invoice_id, invoice_line_id, intervention_id, intervention_line_id, import_key, datec, tms, note)
SELECT gpao.fk_element, gpao.elementtype, gpao.element_date, gpao.element_datehour, gpao.element_date_withhour, gpao.element_duration,
    gpao.fk_product, gpao.fk_user, gpao.thm, gpao.invoice_id, gpao.invoice_line_id, gpao.intervention_id, gpao.intervention_line_id, gpao.import_key, gpao.datec, gpao.tms, gpao.note
FROM llx_gpaoplus_element_time gpao;

ALTER TABLE llx_gpaoplus_element_time RENAME TO llx_gpaoplus_element_time_backup;