Sign inSign up

aaxa/gutenberg-postgresql

By aaxa

•Updated over 8 years ago

Image
0

692

aaxa/gutenberg-postgresql repository overview

How to get it running with data imported:

docker run -p 5432:5432 --name psql -d aaxa/gutenberg-postgresql

Run this script to create schema, tables and indexes: https://github.com/CPHB-FKMP/gutenberg-backend/blob/master/src/main/resources/PostgreSQL.sql⁠

docker exec -it postgres-data /bin/bash

login to the PostgreSQL database as appdev user

psql -h localhost -U appdev

When you are logged in as a user then you can run the following commands

  • \copy gutenberg.books FROM 'import/postgres-books.csv' WITH CSV HEADER DELIMITER AS '|';
  • \copy gutenberg.cities FROM 'import/postgres-cities.csv' WITH CSV HEADER DELIMITER AS '|';
  • \copy gutenberg.authorDtos FROM 'import/postgres-authorDtos.csv' WITH CSV HEADER DELIMITER AS '|';
  • \copy gutenberg.authors_books FROM 'import/postgres-books-authorDtos.csv' WITH CSV HEADER DELIMITER AS '|';
  • \copy gutenberg.books_cities FROM 'import/postgres-books-cities.csv' WITH CSV HEADER DELIMITER AS '|';

Tag summary

Content type

Image

Digest

Size

249.8 MB

Last updated

over 8 years ago

docker pull aaxa/gutenberg-postgresql