intellectsoft-uk / MssqlBundle

Symfony 2 Microsoft SQL Server Bundle
19 stars 24 forks source link

Configuration help #15

Open adriavidal opened 9 years ago

adriavidal commented 9 years ago

I've tried to install without exit these bundle, have some detailed install how-to with the right directory's for every file?

I get these error trying to run a second database connection with

root@extranet:/var/www/extranet# php app/console doctrine:database:create --connection=customer PHP Fatal error: Class 'Realestate\MssqlBundle\RealestateMssqlBundle' not found in /var/www/extranet/app/AppKernel.php on line 23

fesor commented 9 years ago

Did you use composer to install this bundle?

adriavidal commented 9 years ago

No, tried it by hand.

Will try to do it with composer.

adriavidal commented 9 years ago

ok, got it via bundle.

have setup config.yml with the customer connection and params

customer: driver_class: \Realestate\MssqlBundle\Driver\PDODblib\Driver host: "%database_host2%" dbname: "%database_name2%" user: "%database_user2%" password: "%database_password2%"

But configuring doctrine give me another error.

Could not create database for connection named [NNNN] Notice: Undefined property: Doctrine\DBAL\Connection::$options in /var/www/extranet/vendor/isoft/mssql-bundle/Realestate/MssqlBundle/Schema/DblibSchemaManager.php line 65

linkolen commented 9 years ago

@fesor @adriavidal I have the same issue Notice: Undefined property: Doctrine\DBAL\Connection::$options any solution please

albertoSoft commented 9 years ago

Notice: Undefined property: Doctrine\DBAL\Connection::$options ....... Same problem ..... :( someone can help us...

fesor commented 9 years ago

Which version of Doctrine DBAL you use?

albertoSoft commented 9 years ago

this one "doctrine/dbal": "<2.5", and symfony 2.3 O. S. Windows 7

albertoSoft commented 9 years ago

when i try >php app/console doctrine:database:create --connection=mssql , i have this message:

Notice: Undefined property: Doctrine\DBAL\Connection::$options in C:...projectName\vendor\isoft\mssql-bundle\Realestate\MssqlBundle\Schema\DblibSchemaManager.php on line 65

//***parameter.yml

database_driver: pdo_mysql database_host: 127.0.0.1 database_port: null database_name: base database_user: user database_password: userpass mailer_transport: smtp mailer_host: 127.0.0.1 mailer_user: null mailer_password: null locale: es secret: cabdac55292441407995420545d1cf2a

database_host2: 127.0.0.1
database_port2: 1433
database_name2: MSSQLBase
database_user2: sa
database_password2: password

//**Config.yml doctrine: dbal: default_connection: default connections: default: driver: "%database_driver%" host: "%database_host%" port: "%database_port%" dbname: "%database_name%" user: "%database_user%" password: "%database_password%" charset: UTF8 mssql:

driver: "%database_driver2%"

            driver_class:   Realestate\MssqlBundle\Driver\PDODblib\Driver
            host:     "%database_host2%"
            port:     "%database_port2%"
            dbname:   "%database_name2%"
            user:     "%database_user2%"
            password: "%database_password2%"
            #charset:  UTF8

default connection is fine, i can do everything in mysql. I hope you can help me.... i tried to change database_host2: SERVERNAME\INSTANCE insted 127.0.0.1 but it is the same