I pasted the code from the configuration.md file to
module.config.php
\'doctrine\' => array(
\'connection\' => array(
\'orm
@edigu answer works perfectly fine but in some cases, it gives "Following error: Zend\ServiceManager\ServiceManager:: get was unable to fetch or create an instance for doctrine.connection.orm_crawle"
So to resolve this we may change in the Entity Manager settings
'entitymanager' => array(
'orm_default' => array(
'connection' => 'orm_default',
'configuration' => 'orm_default',
),
'orm_alternative' => array(
'connection' => 'orm_alternative',
'configuration' => 'orm_default', //<--use parent configurations
),
),
for refernece check here