我试图在某个地方搜索,但没有找到任何答案。这是我的问题:
我正在开发一个网站,使用 Symfony 3 和 Propel 2。我有一些捆绑包连接到我自己的数据库,它运行良好。
我有一个捆绑包,应该连接到另一个数据库(在 Microsoft SQL Server 上)。问题是,我无法连接到数据库。
这是我的 config.yml
propel:
database:
connections:
myconnection:
adapter: "pdo_mssql"
classname: Propel\Runtime\Adapter\MSSQL\MssqlDebugPDO
dsn: "host=MyHOST;dbname=DBname"
user: "user"
password: "password"
attributes:
我的所有选项都是正确的,我能够使用DBeaver(数据库管理器)连接到这个数据库。
当我尝试
bin/console propel:database:reverse myconnection
我有这个错误
[Propel\Generator\Exception\InvalidArgumentException]
Invalid database name: no configured connection named
`host=MyHOST;dbname=DBname;user=user;password=password`.
那么,有人可以帮助我吗?
如果您需要更多信息,请询问,对不起我的英语
银。