I can’t do anything with legacy database, can’t migrate or update, I have to read some data from it.
Personally, I’d love to migrate asap, but I can’t.
Please help, is there any way to connect Laravel 11 on php 8.2 with any ODBC to that old server?
If yes, what I should install/use to do that?
I tried adding this connection to config:
'legacy_database' => [
'driver' => 'sqlsrv',
'host' => env('LEGACY_DB_HOST'),
'port' => env('LEGACY_DB_PORT', '1433'),
'database' => env('LEGACY_DB_DATABASE'),
'username' => env('LEGACY_DB_USERNAME'),
'password' => env('LEGACY_DB_PASSWORD'),
'charset' => 'utf8',
'prefix' => '',
'prefix_indexes' => true,
'options' => [
PDO::SQLSRV_ATTR_ENCODING => PDO::SQLSRV_ENCODING_UTF8,
'TrustServerCertificate' => true,
'Encrypt' => false,
'LoginTimeout' => 30,
'TraceOn' => 1,
'ReturnDatesAsStrings' => true,
],
],
With this result:
IlluminateDatabaseQueryException
SQLSTATE[08001]: [Microsoft][ODBC Driver 17 for SQL Server]SSL Provider: [error:0A000102:SSL routines::unsupported protocol]
I was trying to connect to Database on the old server but couldn’t
Rustam Anvarov is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
9