Add notes for 2018-06-13

This commit is contained in:
2018-06-13 09:22:58 +03:00
parent 982ed47d55
commit 22a4819f36
3 changed files with 80 additions and 11 deletions

View File

@ -186,5 +186,38 @@ or(
- https://dspacetest.cgiar.org/10568/96141
- https://dspacetest.cgiar.org/10568/96118
- https://dspacetest.cgiar.org/10568/96113
## 2018-06-13
- Elizabeth from CIAT contacted me to ask if I could add ORCID identifiers to all of Robin Buruchara's items
- I used my [add-orcid-identifiers-csv.py](https://gist.githubusercontent.com/alanorth/a49d85cd9c5dea89cddbe809813a7050/raw/f67b6e45a9a940732882ae4bb26897a9b245ef31/add-orcid-identifiers-csv.py) script:
```
$ ./add-orcid-identifiers-csv.py -i 2018-06-13-Robin-Buruchara.csv -db dspace -u dspace -p 'fuuu'
```
- The contents of `2018-06-13-Robin-Buruchara.csv` were:
```
dc.contributor.author,cg.creator.id
"Buruchara, Robin",Robin Buruchara: 0000-0003-0934-1218
"Buruchara, Robin A.",Robin Buruchara: 0000-0003-0934-1218
```
- On a hunch I checked to see if CGSpace's bitstream cleanup was working properly and of course it's broken:
```
$ dspace cleanup -v
...
Error: ERROR: update or delete on table "bitstream" violates foreign key constraint "bundle_primary_bitstream_id_fkey" on table "bundle"
Detail: Key (bitstream_id)=(152402) is still referenced from table "bundle".
```
- As always, the solution is to delete that ID manually in PostgreSQL:
```
$ psql dspace -c 'update bundle set primary_bitstream_id=NULL where primary_bitstream_id in (152402);'
UPDATE 1
```
# vim: set sw=2 ts=2: