Changes

Jump to navigation Jump to search
no edit summary
====Sample insert and copy commands ====
INSERT INTO assignees_merge
(
SELECT
'null',
'null',
'null',
'null',
a.assignee,
a.city,
a.country,
a.patent,
a.state,
'null',
a.nationality,
a.residence,
a.asgseq,
a.asgtype
FROM assignees a
);
INSERT INTO assignees_merge ( SELECT'null' assignees.lastname,'null' assignees.firstname,'null' assignees.address,'null' assignees.postcode,a assignees.assigneeorgname,a assignees.city,a assignees.country,a assignees.patentpatentnumber,a assignees.state, assignees.patentcountry, 'null',a.nationality 'null',a.residence -1,a.asgseq,a.asgtype -1 FROM assignees a );
INSERT INTO assignees_merge
(
SELECT
assignees.lastname,
assignees.firstname,
assignees.address,
assignees.postcode,
assignees.orgname,
assignees.city,
assignees.country,
assignees.patentnumber,
assignees.state,
assignees.patentcountry,
'null',
'null',
-1,
-1
FROM assignees
);
\COPY assignees_merge TO '/tmp/assignees_merge_export.txt' DELIMITER AS E'\t' HEADER NULL AS '' CSV;
\COPY assignees FROM '/tmp/assignees_merge_export.txt' DELIMITER AS E'\t' HEADER NULL AS '' CSV;
--1607724
\COPY assignees_merge TO '/tmp/assignees_merge_export.txt' DELIMITER AS E'\t' HEADER NULL AS '' CSV;\COPY assignees FROM '/tmp/assignees_merge_export.txt' DELIMITER AS E'\t' HEADER NULL AS '' CSV;--1607724  \COPY assignees_merge TO '/tmp/assignees_merge_export1.txt' DELIMITER AS E'\t' HEADER NULL AS '' CSV; \COPY assignees FROM '/tmp/assignees_merge_export1.txt' DELIMITER AS E'\t' HEADER NULL AS '' CSV; --3818842

Navigation menu