I know how to configure MySQL database in Play 2.0 by specifying these in application.conf:
db.default.driver=com.mysql.jdbc.Driver
db.default.url="jdbc:mysql://localhost/test"
db.default.user="root"
db.default.password=""
and putting this in
val appDependencies = Seq(
“mysql” % “mysql-connector-java” % “5.1.18”)
in Build.scala file.
But how do I achieve the same in Play 1.2 framework ?
To connect to a local MySQL database, put the settings in your
application.conffile in the following format:(So in your case it would be
db=mysql:root:@test)There is no need to add any dependencies – MySQL is already included.
The longer format of configuration would be like this:
See Play Framework documentation form more info.