database - How to use DATABSE_URL in Play 2.0 (Scala) for local connection to mysql -


i'm new play framework. i'm trying configure mysql database datasource used play.

i have done following setting connect mysql database play..

db.default.driver=com.mysql.jdbc.driver

db.default.url="jdbc:mysql://localhost/phpmyadmin/index.php?db=formdemo&token=3882f545563c7df106e1daf21515e1b7#pmaurl:db=formdemo&server=1&target=db_structure.php&token=3882f545563c7df106e1daf21515e1b7"


but getting following configuration error.

play.api.configuration$$anon$1: configuration error[cannot connect database [default]]


i not able connect wamp localhost database play. how modify configuration file use mysql database opposed in-memory version. need setup entirely separate db or can modify db.default.url property?

i'm using play! 2.1.

i have resolved issue. thank guidance.

few lines put. dependency

"mysql" % "mysql-connector-java" % "5.1.18"  

conf

db.default.driver=com.mysql.jdbc.driver db.default.url="jdbc:mysql://localhost/formdemo?characterencoding=utf-8" db.default.user=root db.default.password="" 

follow reference, http://blog.knoldus.com/2013/01/28/play-framework-2-0-connectivity-with-mysql-in-scala/


Comments

Popular posts from this blog

php - Why I am getting the Error "Commands out of sync; you can't run this command now" -

linux - Does gcc have any options to add version info in ELF binary file? -

java - Are there any classes that implement javax.persistence.Parameter<T>? -