Using play with existing database ( models )

you can obtain JDBC Connection instance and execute raw SQL queries (read docs here https://www.playframework.com/documentation/2.8.x/AccessingAnSQLDatabase)