September 2018
Intermediate to advanced
398 pages
9h 43m
English
The database setup is done in the conf/application.conf file. When a database is needed, it must be configured in this file. Slick provides a default configuration, named default. For a new database, replace this name with the name of your database.
We will enable evolution and tell it to automatically run the scripts for database creation and deletion.
In our case, the entry looks as follows:
# Default database configuration slick.dbs.default.profile="slick.jdbc.H2Profile$" slick.dbs.default.db.driver="org.h2.Driver" slick.dbs.default.db.url="jdbc:h2:mem:shopping" play.evolutions.enabled=true play.evolutions.db.default.autoApply=true
The complete configuration option can be found in the Play Framework documentation ...
Read now
Unlock full access