You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
Cauã 561905d43e Tornando o endpoint /organizations/all público e removendo os números de telefone das instituições ao listar 8 months ago
..
README.md Fixing JPA Cache 3 years ago
educacao.cemaden-organization-dump.csv Adding load module 3 years ago

README.md

wpdAuth.load module

This module is responsible to load the organizations dump from Cemaden Educations web site. The dump is loaded from the csv file here in this folder following the ddl structure to the entity 'educemaden_organizations'. In order to avoid SQL errors, there are no indexes on 'educemaden_organizations' entity, and for each load this entity should be truncated.

Dependencies

  • Make sure the setup was finished successfully according to the instruction in the root README file.

How to run this load

Once the project setup was finished successfully, follow the steps below:

  • Start the PostgreSQL and run the scripts to create the database and get the load data.
  $ psql -d wpdauth -c "TRUNCATE TABLE auth.educemaden_organizations;"
  $ psql -d wpdauth -c "\COPY auth.educemaden_organizations(id,active,name,creation_date,inep_code,phone,type,website,login,address,responsible) FROM '/<absolute path>/educacao.cemaden-organization-dump.csv' DELIMITER ',' CSV HEADER;"
  $ psql -d wpdauth -c "SELECT * FROM auth.educemaden_organizations;"