1
|
INSERT INTO hostedby_map(_dnet_resource_identifier_, oa_source_id, entry, datasourceid)
|
2
|
SELECT d.issn||'@@'||d.collectedfrom, d.collectedfrom, d.issn, d.id
|
3
|
FROM dsm_datasources d where
|
4
|
d.collectedfrom ='$datasourceId$' and d.issn is not null and d.id like '$datasourceNamespacePrefix$%'
|
5
|
AND
|
6
|
(d.collectedfrom, d.issn) NOT IN
|
7
|
(SELECT oa_source_id, entry from hostedby_map);
|
8
|
|
9
|
|
10
|
INSERT INTO hostedby_map(_dnet_resource_identifier_, oa_source_id, entry, datasourceid)
|
11
|
SELECT d.eissn||'@@'||d.collectedfrom, d.collectedfrom, d.eissn, d.id
|
12
|
FROM dsm_datasources d where
|
13
|
d.collectedfrom ='$datasourceId$' and d.eissn is not null and d.id like '$datasourceNamespacePrefix$%'
|
14
|
AND
|
15
|
(d.collectedfrom, d.eissn) NOT IN
|
16
|
(SELECT oa_source_id, entry from hostedby_map);
|
17
|
|
18
|
|
19
|
INSERT INTO hostedby_map(_dnet_resource_identifier_, oa_source_id, entry, datasourceid)
|
20
|
SELECT d.lissn||'@@'||d.collectedfrom, d.collectedfrom, d.lissn, d.id
|
21
|
FROM dsm_datasources d where
|
22
|
d.collectedfrom ='$datasourceId$' and d.lissn is not null and d.id like '$datasourceNamespacePrefix$%'
|
23
|
AND
|
24
|
(d.collectedfrom, d.lissn) NOT IN
|
25
|
(SELECT oa_source_id, entry from hostedby_map);
|