views:

36

answers:

3

I don't develop with symphony but need to update the database connection details for a couple websites developed by third parties running it.

They appear to make use of propel.

I've updated the dsn in database.yml but this has just taken the site offline (500 error)

Any idea what I might have done wrong or may need to do to force the changes through. Is there some kind of update script I need to run?

In case it helps I seem to have propel-init-crud, propel-generate-crud as options for propel when I run:

> php symfony propel

A: 

Look in config/propel.ini:

propel.database.url        = mysql:dbname=foo;host=localhost
propel.database.user       = foo
propel.database.password   = foo

The same details need to be in databases.yml

Also it would be easier to answer if you said exactly what the error is.

Coronatus
A: 

hi coderchris, i need to know what is symfony version that you running , to knowing your symfony version , run this command in terminal(unix)/command prompt(win) in project directory

$ ./symfony -V

if you using symfony 1.4 the best way to set database configuration is :

$ ./symfony configure:database --name=propel --class=sfPropelDatabase "mysql:host=localhost;dbname=dbname" user secret

good luck

Danial
Hi Danialsorry for the late reply, it's: 1.0.17
coderchris
A: 

Whenever changes are made to symfony files, especially .yml files, you always need to run the clear cache command to remove all the cache files.

php symfony -cc
Patrick