1
|
SELECT * FROM orgs
|
2
|
UNION
|
3
|
SELECT
|
4
|
o.id AS organizationid,
|
5
|
o.legalshortname AS legalshortname,
|
6
|
o.legalname AS legalname,
|
7
|
o.websiteurl AS websiteurl,
|
8
|
o.logourl AS logourl,
|
9
|
null AS eclegalbody,
|
10
|
null AS eclegalperson,
|
11
|
null AS ecnonprofit,
|
12
|
null AS ecresearchorganization,
|
13
|
null AS echighereducation,
|
14
|
null AS ecinternationalorganizationeurinterests,
|
15
|
null AS ecinternationalorganization,
|
16
|
null AS ecenterprise,
|
17
|
null AS ecsmevalidated,
|
18
|
null AS ecnutscode,
|
19
|
o.dateofcollection AS dateofcollection,
|
20
|
false AS inferred,
|
21
|
false AS deletedbyinference,
|
22
|
0.9 AS trust,
|
23
|
'' AS inferenceprovenance,
|
24
|
d.id AS collectedfromid,
|
25
|
d.officialname AS collectedfromname,
|
26
|
|
27
|
o.country || '@@@' || o.country || '@@@dnet:countries@@@dnet:countries' AS country,
|
28
|
'sysimport:crosswalk:entityregistry@@@sysimport:crosswalk:entityregistry@@@dnet:provenance_actions@@@dnet:provenance_actions' AS provenanceaction,
|
29
|
|
30
|
ARRAY[]::text[] AS pid
|
31
|
FROM dsm_organizations o
|
32
|
LEFT OUTER JOIN dsm_datasources d ON (d.id = o.collectedfrom)
|
33
|
|
34
|
|
35
|
|
36
|
|
37
|
|