Skip to content

Tutorial

Kevin Nguyen edited this page Nov 8, 2022 · 9 revisions

How to set up the database

  1. Install PostgreSQL.
  2. Choose a password for PostgreSQL authentification.
  3. Open the application.properties file in code/src/main/resources and fill in the spring.datasource.username=and spring.datasource.password= fields, e.g. spring.datasource.username=postgres and spring.datasource.password=123456.

How to connect to the database

  1. Open the SpecitemDatabaseApplication.java file and run it.

or

  1. Run SQL Shell (psql).
  2. Execute \c specitems.
  3. Run \dt to display all avaiable tables in the specitems database.
  4. As you are already connected to the database, you can query something like SELECT * FROM spec_item_entity;.
Clone this wiki locally