Revision 57750
Added by Michele Artini almost 5 years ago
modules/dnet-orgs-database-application/trunk/src/main/resources/sql/schema.sql | ||
---|---|---|
166 | 166 |
org.creation_date, |
167 | 167 |
org.modified_by, |
168 | 168 |
org.modification_date, |
169 |
count(r.id1) as n_rels,
|
|
170 |
count(e.local_id) as n_enrichments,
|
|
171 |
count(c.local_id) as n_conflicts
|
|
169 |
count(DISTINCT r.id2) as n_rels,
|
|
170 |
count(DISTINCT e.oa_original_id) as n_enrichments,
|
|
171 |
count(DISTINCT c.oa_original_id) as n_conflicts
|
|
172 | 172 |
FROM organizations org |
173 |
LEFT OUTER JOIN relationships r ON (org.id = r.id1) |
|
173 |
LEFT OUTER JOIN relationships r ON (org.id = r.id1)
|
|
174 | 174 |
LEFT OUTER JOIN openaire_simrels e ON (org.id = e.local_id AND e.oa_original_id NOT LIKE 'openorgs____::%') |
175 | 175 |
LEFT OUTER JOIN openaire_simrels c ON (org.id = c.local_id AND c.oa_original_id LIKE 'openorgs____::%') |
176 | 176 |
GROUP BY org.id; |
Also available in: Unified diff
bug fix