vmeditab / laravel-odbc-driver
ODBC driver for Laravel 8.x & PHP 8.x
2.0.0
2021-03-04 06:50 UTC
Requires
- php: ^5.3 || ^7.0 || ^8.0
This package is not auto-updated.
Last update: 2025-04-26 02:10:27 UTC
README
ODBC Driver for Laravel 5.5+
Prerequisites
- The composer.json file use the "auto discover" function so you must have laravel ^5.5
- You must create a ODBC in your operating system
Installation
Install package with composer
composer require agomez/laravel-odbc-driver
Run composer update
composer update
Add odbc to config/database.php
'odbc' => [
'driver' => 'odbc',
'dsn' => 'dns name',
'grammar' => 'DB2',
'username' => 'username',
'password' => 'password',
'database' => 'database'
],
Test
@php
$array = DB::connection('odbc')->select('raw sql query');
dd($array);
@endphp
Original
- Cody Covey @ https://github.com/ccovey/odbc-driver