1
0
Fork 0

bug fix in the query, it now exports only relations with non-hidden organizations

This commit is contained in:
miconis 2021-04-08 11:51:47 +02:00
parent 0857100fb8
commit 11b22b2d23
1 changed files with 8 additions and 4 deletions

View File

@ -1,7 +1,7 @@
-- relations approved by the user and suggested by the dedup
SELECT
local_id AS id1,
oa_original_id AS id2,
d.local_id AS id1,
d.oa_original_id AS id2,
'openaire____::openorgs' AS collectedfromid,
'OpenOrgs Database' AS collectedfromname,
false AS inferred,
@ -9,6 +9,10 @@ SELECT
0.99 AS trust,
'' AS inferenceprovenance
FROM
oa_duplicates
oa_duplicates d
LEFT OUTER JOIN
organizations o ON (d.local_id = o.id)
WHERE
reltype = 'is_similar' OR reltype = 'suggested';
(d.reltype = 'is_similar' OR d.reltype = 'suggested') AND (o.status != 'hidden');