1045 |
end_timestamp timestamp, |
end_timestamp timestamp, |
1046 |
tax_total numeric(12,4), |
tax_total numeric(12,4), |
1047 |
start_timestamp timestamp, |
start_timestamp timestamp, |
|
exempt_net_total numeric(12,4), |
|
1048 |
own_entity bigint, |
own_entity bigint, |
1049 |
bundles int, |
bundles int, |
1050 |
net_total numeric(12,4), |
net_total numeric(12,4), |
1061 |
CREATE INDEX own_document_salesperson_idx ON own_document(salesperson); |
CREATE INDEX own_document_salesperson_idx ON own_document(salesperson); |
1062 |
CREATE INDEX own_document_transport_idx ON own_document(transport); |
CREATE INDEX own_document_transport_idx ON own_document(transport); |
1063 |
CREATE INDEX own_document_own_entity_idx ON own_document(own_entity); |
CREATE INDEX own_document_own_entity_idx ON own_document(own_entity); |
1064 |
INSERT INTO own_document (due_date, own_document_type, related_to, number, is_void, salesperson, address, date, authorized_amount, recipient, id, transport, end_timestamp, tax_total, start_timestamp, exempt_net_total, own_entity, bundles, net_total, observations, discount_percent, authorized_by, entry, guide_number) SELECT due_date, own_document_type, related_to, number, is_void, salesperson, address, date, authorized_amount, recipient, id, transport, end_timestamp, tax_total, start_timestamp, exempt_net_total, own_entity, bundles, net_total, observations, discount_percent, authorized_by, entry, guide_number FROM temp; |
INSERT INTO own_document (due_date, own_document_type, related_to, number, is_void, salesperson, address, date, authorized_amount, recipient, id, transport, end_timestamp, tax_total, start_timestamp, own_entity, bundles, net_total, observations, discount_percent, authorized_by, entry, guide_number) SELECT due_date, own_document_type, related_to, number, is_void, salesperson, address, date, authorized_amount, recipient, id, transport, end_timestamp, tax_total, start_timestamp, own_entity, bundles, net_total, observations, discount_percent, authorized_by, entry, guide_number FROM temp; |
1065 |
DROP TABLE temp; |
DROP TABLE temp; |
1066 |
CREATE TABLE temp AS SELECT * FROM _employee_comm_prod_client_data; |
CREATE TABLE temp AS SELECT * FROM _employee_comm_prod_client_data; |
1067 |
DROP TABLE _employee_comm_prod_client_data; |
DROP TABLE _employee_comm_prod_client_data; |
1169 |
alien_document_type bigint, |
alien_document_type bigint, |
1170 |
tax_total numeric(12,4), |
tax_total numeric(12,4), |
1171 |
start_timestamp timestamp, |
start_timestamp timestamp, |
|
exempt_net_total numeric(12,4), |
|
1172 |
sender bigint, |
sender bigint, |
1173 |
bundles int, |
bundles int, |
1174 |
net_total numeric(12,4), |
net_total numeric(12,4), |
1185 |
CREATE INDEX alien_document_alien_document_type_idx ON alien_document(alien_document_type); |
CREATE INDEX alien_document_alien_document_type_idx ON alien_document(alien_document_type); |
1186 |
CREATE INDEX alien_document_received_by_idx ON alien_document(received_by); |
CREATE INDEX alien_document_received_by_idx ON alien_document(received_by); |
1187 |
CREATE INDEX alien_document_salesperson_idx ON alien_document(salesperson); |
CREATE INDEX alien_document_salesperson_idx ON alien_document(salesperson); |
1188 |
INSERT INTO alien_document (due_date, number, date, is_void, salesperson, received_by, own_entity, id, transport, alien_document_type, tax_total, start_timestamp, exempt_net_total, sender, bundles, net_total, observations, discount_percent, entry, end_timestamp, guide_number) SELECT due_date, number, date, is_void, salesperson, received_by, own_entity, id, transport, alien_document_type, tax_total, start_timestamp, exempt_net_total, sender, bundles, net_total, observations, discount_percent, entry, end_timestamp, guide_number FROM temp; |
INSERT INTO alien_document (due_date, number, date, is_void, salesperson, received_by, own_entity, id, transport, alien_document_type, tax_total, start_timestamp, sender, bundles, net_total, observations, discount_percent, entry, end_timestamp, guide_number) SELECT due_date, number, date, is_void, salesperson, received_by, own_entity, id, transport, alien_document_type, tax_total, start_timestamp, sender, bundles, net_total, observations, discount_percent, entry, end_timestamp, guide_number FROM temp; |
1189 |
DROP TABLE temp; |
DROP TABLE temp; |
1190 |
CREATE TABLE temp AS SELECT * FROM _product_tax_data; |
CREATE TABLE temp AS SELECT * FROM _product_tax_data; |
1191 |
DROP TABLE _product_tax_data; |
DROP TABLE _product_tax_data; |