Project

General

Profile

1
CREATE TABLE IF NOT EXISTS hostedby_map (
2
	_dnet_resource_identifier_ CHARACTER VARYING(2048) DEFAULT 'temp_' || md5(clock_timestamp() :: TEXT) || '_' || md5(random() :: TEXT) UNIQUE,
3
	oa_source_id               CHARACTER VARYING(255) REFERENCES dsm_datasources (id),
4
	entry                      CHARACTER VARYING(255) NOT NULL,
5
	datasourceid               CHARACTER VARYING(255) REFERENCES dsm_datasources (id),
6
	PRIMARY KEY (oa_source_id, entry)
7
);
8

    
9
--DATACITE API
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');
12
INSERT INTO apicollections (param, original, api) VALUES ('baseUrl', 'http://oai.datacite.org/oai', 'api_________::datacite::oaisets');
13
INSERT INTO apicollections (param, original, api, accessparam)
14
VALUES ('metadata_identifier_path', '//*[local-name() = ''setSpec'']', 'api_________::datacite::oaisets', FALSE);
15

    
16
--PANGAEA BY PROJECT
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);
26

    
27
--PANGAEA BY JOURNAL
28

    
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);
35

    
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);
56

    
57
--DOAJ
58

    
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');
62

    
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

    
80
CREATE TABLE IF NOT EXISTS hostedby_props (
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)
85
);
(25-25/26)