# VOSpace File Catalog (database) **⚠ Work in progress! ⚠** This repository defines the VOSpace database structure. It consists in a PostgreSQL database with the [ltree](https://www.postgresql.org/docs/12/ltree.html) extension. SQL files are named starting with a number because they are put in a Docker image where they have to be executed in order. ## Dump and restore To restore the file catalog from a dump it is necessary to drop the generated columns and regenerate them after the import. This can be done using the restore_db.sh script located in the dump_and_restore folder of this repository. To obtain a data only dump of the database use the following command: pg_dump -h -U postgres --data-only --format=tar vospace_testdb > mydump.tar Then you can use the restore script in the following way: ./restore_db.sh -U postgres -h 127.0.0.1 -p 5432 -d vospace_testdb mydump.tar