Project

General

Profile

« Previous | Next » 

Revision 48139

integrated (hopefully) all required changes from dnet40

View differences:

patch_pangaea_doaj.sql
1 1
CREATE TABLE IF NOT EXISTS hostedby_map (
2
	_dnet_resource_identifier_ character varying(2048) DEFAULT 'temp_'||md5(clock_timestamp()::text)||'_'||md5(random()::text),
3
	oa_source_id               character varying(255) references  datasources(id),
4
	entry                      character varying(255) NOT NULL,
5
	datasourceid               character varying(255) references datasources(id),
6
  PRIMARY key(oa_source_id, entry)
2
	_dnet_resource_identifier_ CHARACTER VARYING(2048) DEFAULT 'temp_' || md5(clock_timestamp() :: TEXT) || '_' || md5(random() :: TEXT),
3
	oa_source_id               CHARACTER VARYING(255) REFERENCES datasources (id),
4
	entry                      CHARACTER VARYING(255) NOT NULL,
5
	datasourceid               CHARACTER VARYING(255) REFERENCES datasources (id),
6
	PRIMARY KEY (oa_source_id, entry)
7 7
);
8 8

  
9 9
--DATACITE API
10
INSERT INTO api (_dnet_resource_identifier_, id, protocolclass, datasource, typologyclass, compatibilityclass) VALUES ('api_________::datacite::oaisets', 'api_________::datacite::oaisets', 'oai_sets', 'openaire____::datacite', 'aggregator::datarepository', 'native');
10
INSERT INTO api (_dnet_resource_identifier_, id, protocolclass, datasource, typologyclass, compatibilityclass)
11
VALUES ('api_________::datacite::oaisets', 'api_________::datacite::oaisets', 'oai_sets', 'openaire____::datacite', 'aggregator::datarepository', 'native');
11 12
INSERT INTO apicollections (param, original, api) VALUES ('baseUrl', 'http://oai.datacite.org/oai', 'api_________::datacite::oaisets');
12
INSERT INTO apicollections (param, original, api, accessparam) VALUES ('metadata_identifier_path', '//*[local-name() = ''setSpec'']', 'api_________::datacite::oaisets', false);
13
INSERT INTO apicollections (param, original, api, accessparam)
14
VALUES ('metadata_identifier_path', '//*[local-name() = ''setSpec'']', 'api_________::datacite::oaisets', FALSE);
13 15

  
14 16
--PANGAEA BY PROJECT
15
INSERT INTO api (_dnet_resource_identifier_, id, protocolclass, datasource, typologyclass, compatibilityclass) VALUES  ('api_________::re3data_____::r3d100010134::pangaeabyproject', 'api_________::re3data_____::r3d100010134::pangaeabyproject', 'datasetsbyproject',  're3data_____::r3d100010134', 'datarepository::unknown', 'native');
16
insert into apicollections(param,original,api, _dnet_resource_identifier_, accessparam)  values ( 'metadata_identifier_path' ,'//*[local-name()=''header'']/*[local-name()=''identifier'']', 'api_________::re3data_____::r3d100010134::pangaeabyproject', 'api_________::re3data_____::r3d100010134::pangaeabyproject@@metadata_identifier_path', false);
17
insert into apicollections(param,original,api, _dnet_resource_identifier_, accessparam)  values ( 'baseUrl', 'file:///var/lib/dnet/pangaea_projects.csv', 'api_________::re3data_____::r3d100010134::pangaeabyproject', 'api_________::re3data_____::r3d100010134::pangaeabyproject@@baseUrl', true);
17
INSERT INTO api (_dnet_resource_identifier_, id, protocolclass, datasource, typologyclass, compatibilityclass) VALUES
18
	('api_________::re3data_____::r3d100010134::pangaeabyproject', 'api_________::re3data_____::r3d100010134::pangaeabyproject', 'datasetsbyproject',
19
	 're3data_____::r3d100010134', 'datarepository::unknown', 'native');
20
INSERT INTO apicollections (param, original, api, _dnet_resource_identifier_, accessparam) VALUES
21
	('metadata_identifier_path', '//*[local-name()=''header'']/*[local-name()=''identifier'']', 'api_________::re3data_____::r3d100010134::pangaeabyproject',
22
	 'api_________::re3data_____::r3d100010134::pangaeabyproject@@metadata_identifier_path', FALSE);
23
INSERT INTO apicollections (param, original, api, _dnet_resource_identifier_, accessparam) VALUES
24
	('baseUrl', 'file:///var/lib/dnet/pangaea_projects.csv', 'api_________::re3data_____::r3d100010134::pangaeabyproject',
25
	 'api_________::re3data_____::r3d100010134::pangaeabyproject@@baseUrl', TRUE);
18 26

  
19

  
20 27
--PANGAEA BY JOURNAL
21 28

  
22
INSERT INTO api (_dnet_resource_identifier_, id, protocolclass, datasource, typologyclass, compatibilityclass) VALUES ('api_________::re3data_____::r3d100010134::pangaeabyjournal', 'api_________::re3data_____::r3d100010134::pangaeabyjournal',  'datasetsbyjournal',  're3data_____::r3d100010134', 'datarepository::unknown', 'native');
23
INSERT INTO apicollections(param,original,api, _dnet_resource_identifier_, accessparam)  values ( 'metadata_identifier_path' ,'//*[local-name()=''header'']/*[local-name()=''identifier'']', 'api_________::re3data_____::r3d100010134::pangaeabyjournal',  'api_________::re3data_____::r3d100010134::pangaeabyjournal@@metadata_identifier_path', false);
29
INSERT INTO api (_dnet_resource_identifier_, id, protocolclass, datasource, typologyclass, compatibilityclass) VALUES
30
	('api_________::re3data_____::r3d100010134::pangaeabyjournal', 'api_________::re3data_____::r3d100010134::pangaeabyjournal', 'datasetsbyjournal',
31
	 're3data_____::r3d100010134', 'datarepository::unknown', 'native');
32
INSERT INTO apicollections (param, original, api, _dnet_resource_identifier_, accessparam) VALUES
33
	('metadata_identifier_path', '//*[local-name()=''header'']/*[local-name()=''identifier'']', 'api_________::re3data_____::r3d100010134::pangaeabyjournal',
34
	 'api_________::re3data_____::r3d100010134::pangaeabyjournal@@metadata_identifier_path', FALSE);
24 35

  
25
INSERT INTO api (_dnet_resource_identifier_, id, protocolclass, datasource, typologyclass, compatibilityclass) VALUES ('api_________::re3data_____::r3d100010134::pangaeabyjournalCSV', 'api_________::re3data_____::r3d100010134::pangaeabyjournalCSV', 'fileCSV',  're3data_____::r3d100010134', 'datarepository::unknown', 'native');
26
INSERT INTO apicollections(param,original,api, _dnet_resource_identifier_, accessparam)  values ( 'metadata_identifier_path' ,'//*[local-name()=''column'' and @isID=''true'']', 'api_________::re3data_____::r3d100010134::pangaeabyjournalCSV', 'api_________::re3data_____::r3d100010134::pangaeabyjournalCSV@@metadata_identifier_path', false);
27
INSERT INTO apicollections(param,original,api, _dnet_resource_identifier_, accessparam)  values ( 'baseUrl' ,'file:///var/lib/dnet/pangaea_journals.csv', 'api_________::re3data_____::r3d100010134::pangaeabyjournalCSV', 'api_________::re3data_____::r3d100010134::pangaeabyjournalCSV@@baseUrl', true);
28
INSERT INTO apicollections(param,original,api, _dnet_resource_identifier_, accessparam)   values ( 'quote' ,'"', 'api_________::re3data_____::r3d100010134::pangaeabyjournalCSV','api_________::re3data_____::r3d100010134::pangaeabyjournalCSV@@quote', true);       
29
INSERT INTO apicollections(param,original,api, _dnet_resource_identifier_, accessparam)  values ( 'header' ,'true', 'api_________::re3data_____::r3d100010134::pangaeabyjournalCSV','api_________::re3data_____::r3d100010134::pangaeabyjournalCSV@@header', true); 
30
INSERT INTO apicollections(param,original,api, _dnet_resource_identifier_, accessparam)  values ( 'identifier' ,'4','api_________::re3data_____::r3d100010134::pangaeabyjournalCSV','api_________::re3data_____::r3d100010134::pangaeabyjournalCSV@@identifier', true); 
31
INSERT INTO apicollections(param,original,api, _dnet_resource_identifier_, accessparam)  values ( 'separator' ,'@','api_________::re3data_____::r3d100010134::pangaeabyjournalCSV','api_________::re3data_____::r3d100010134::pangaeabyjournalCSV@@separator', true);
36
INSERT INTO api (_dnet_resource_identifier_, id, protocolclass, datasource, typologyclass, compatibilityclass) VALUES
37
	('api_________::re3data_____::r3d100010134::pangaeabyjournalCSV', 'api_________::re3data_____::r3d100010134::pangaeabyjournalCSV', 'fileCSV',
38
	 're3data_____::r3d100010134', 'datarepository::unknown', 'native');
39
INSERT INTO apicollections (param, original, api, _dnet_resource_identifier_, accessparam) VALUES
40
	('metadata_identifier_path', '//*[local-name()=''column'' and @isID=''true'']', 'api_________::re3data_____::r3d100010134::pangaeabyjournalCSV',
41
	 'api_________::re3data_____::r3d100010134::pangaeabyjournalCSV@@metadata_identifier_path', FALSE);
42
INSERT INTO apicollections (param, original, api, _dnet_resource_identifier_, accessparam) VALUES
43
	('baseUrl', 'file:///var/lib/dnet/pangaea_journals.csv', 'api_________::re3data_____::r3d100010134::pangaeabyjournalCSV',
44
	 'api_________::re3data_____::r3d100010134::pangaeabyjournalCSV@@baseUrl', TRUE);
45
INSERT INTO apicollections (param, original, api, _dnet_resource_identifier_, accessparam) VALUES
46
	('quote', '"', 'api_________::re3data_____::r3d100010134::pangaeabyjournalCSV', 'api_________::re3data_____::r3d100010134::pangaeabyjournalCSV@@quote', TRUE);
47
INSERT INTO apicollections (param, original, api, _dnet_resource_identifier_, accessparam) VALUES
48
	('header', 'true', 'api_________::re3data_____::r3d100010134::pangaeabyjournalCSV', 'api_________::re3data_____::r3d100010134::pangaeabyjournalCSV@@header',
49
	 TRUE);
50
INSERT INTO apicollections (param, original, api, _dnet_resource_identifier_, accessparam) VALUES
51
	('identifier', '4', 'api_________::re3data_____::r3d100010134::pangaeabyjournalCSV',
52
	 'api_________::re3data_____::r3d100010134::pangaeabyjournalCSV@@identifier', TRUE);
53
INSERT INTO apicollections (param, original, api, _dnet_resource_identifier_, accessparam) VALUES
54
	('separator', '@', 'api_________::re3data_____::r3d100010134::pangaeabyjournalCSV',
55
	 'api_________::re3data_____::r3d100010134::pangaeabyjournalCSV@@separator', TRUE);
32 56

  
33 57
--DOAJ
34 58

  
35
insert into api (id, _dnet_resource_identifier_ , protocolclass, datasource , contentdescriptionclass, typologyclass, compatibilityclass) values ('api_________::driver______::1790119e-d281-4b7a-aedf-866d1d853a07::httpCSV' , 'api_________::driver______::1790119e-d281-4b7a-aedf-866d1d853a07::httpCSV', 'httpCSV', 'driver______::1790119e-d281-4b7a-aedf-866d1d853a07', 'metadata',	 'entityregistry' , 'native');
59
INSERT INTO api (id, _dnet_resource_identifier_, protocolclass, datasource, contentdescriptionclass, typologyclass, compatibilityclass) VALUES
60
	('api_________::driver______::1790119e-d281-4b7a-aedf-866d1d853a07::httpCSV', 'api_________::driver______::1790119e-d281-4b7a-aedf-866d1d853a07::httpCSV',
61
	 'httpCSV', 'driver______::1790119e-d281-4b7a-aedf-866d1d853a07', 'metadata', 'entityregistry', 'native');
36 62

  
37
insert into apicollections(param,original,api,_dnet_resource_identifier_,accessparam) values('baseUrl', 'http://doaj.org/csv', 'api_________::driver______::1790119e-d281-4b7a-aedf-866d1d853a07::httpCSV','api_________::driver______::1790119e-d281-4b7a-aedf-866d1d853a07::httpCSV@@baseUrl',true);
38
insert into apicollections(param,original,api,_dnet_resource_identifier_,accessparam) values('separator', ',', 'api_________::driver______::1790119e-d281-4b7a-aedf-866d1d853a07::httpCSV','api_________::driver______::1790119e-d281-4b7a-aedf-866d1d853a07::httpCSV@@separator',true);
39
insert into apicollections(param,original,api,_dnet_resource_identifier_,accessparam) values('quote', '"', 'api_________::driver______::1790119e-d281-4b7a-aedf-866d1d853a07::httpCSV','api_________::driver______::1790119e-d281-4b7a-aedf-866d1d853a07::httpCSV@@quote',true);
40
insert into apicollections(param,original,api,_dnet_resource_identifier_,accessparam) values('identifier', 'ISSN', 'api_________::driver______::1790119e-d281-4b7a-aedf-866d1d853a07::httpCSV','api_________::driver______::1790119e-d281-4b7a-aedf-866d1d853a07::httpCSV@@identifier',true);
41
insert into apicollections(param,original,api,_dnet_resource_identifier_,accessparam) values('metadata_identifier_path', '//column[./@isID=''true'']', 'api_________::driver______::1790119e-d281-4b7a-aedf-866d1d853a07::httpCSV','api_________::driver______::1790119e-d281-4b7a-aedf-866d1d853a07::httpCSV@@metadata_identifier_path',false);
42
     
43
     
44
     
63
INSERT INTO apicollections (param, original, api, _dnet_resource_identifier_, accessparam) VALUES
64
	('baseUrl', 'http://doaj.org/csv', 'api_________::driver______::1790119e-d281-4b7a-aedf-866d1d853a07::httpCSV',
65
	 'api_________::driver______::1790119e-d281-4b7a-aedf-866d1d853a07::httpCSV@@baseUrl', TRUE);
66
INSERT INTO apicollections (param, original, api, _dnet_resource_identifier_, accessparam) VALUES
67
	('separator', ',', 'api_________::driver______::1790119e-d281-4b7a-aedf-866d1d853a07::httpCSV',
68
	 'api_________::driver______::1790119e-d281-4b7a-aedf-866d1d853a07::httpCSV@@separator', TRUE);
69
INSERT INTO apicollections (param, original, api, _dnet_resource_identifier_, accessparam) VALUES
70
	('quote', '"', 'api_________::driver______::1790119e-d281-4b7a-aedf-866d1d853a07::httpCSV',
71
	 'api_________::driver______::1790119e-d281-4b7a-aedf-866d1d853a07::httpCSV@@quote', TRUE);
72
INSERT INTO apicollections (param, original, api, _dnet_resource_identifier_, accessparam) VALUES
73
	('identifier', 'ISSN', 'api_________::driver______::1790119e-d281-4b7a-aedf-866d1d853a07::httpCSV',
74
	 'api_________::driver______::1790119e-d281-4b7a-aedf-866d1d853a07::httpCSV@@identifier', TRUE);
75
INSERT INTO apicollections (param, original, api, _dnet_resource_identifier_, accessparam) VALUES
76
	('metadata_identifier_path', '//column[./@isID=''true'']', 'api_________::driver______::1790119e-d281-4b7a-aedf-866d1d853a07::httpCSV',
77
	 'api_________::driver______::1790119e-d281-4b7a-aedf-866d1d853a07::httpCSV@@metadata_identifier_path', FALSE);
78

  
79

  
45 80
CREATE TABLE IF NOT EXISTS hostedby_props (
46
	_dnet_resource_identifier_ character varying(2048) NOT NULL references hostedby_map(_dnet_resource_identifier_),
47
	key               character varying(255) NOT NULL,
48
	value                      character varying(255) NOT NULL,	
49
  PRIMARY key(_dnet_resource_identifier_, key,value)
81
	_dnet_resource_identifier_ CHARACTER VARYING(2048) NOT NULL REFERENCES hostedby_map (_dnet_resource_identifier_),
82
	key                        CHARACTER VARYING(255)  NOT NULL,
83
	value                      CHARACTER VARYING(255)  NOT NULL,
84
	PRIMARY KEY (_dnet_resource_identifier_, key, value)
50 85
);

Also available in: Unified diff