PHP code example of felixarenas / adodbconect

1. Go to this page and download the library: Download felixarenas/adodbconect library. Choose the download type require.

2. Extract the ZIP file and open the index.php.

3. Add this code to the index.php.
    
        
<?php
require_once('vendor/autoload.php');

/* Start to develop here. Best regards https://php-download.com/ */

    

felixarenas / adodbconect example snippets

 php
'providers' => [
    farenas\AdodbConect\Providers\AdodbConectServiceProvider::class,
    Yajra\Oci8\Oci8ServiceProvider::class,
]
 php
'aliases' => [
    'AdodbConect' => farenas\AdodbConect\Facades\AdodbConectFacade::class,
]
 php
php artisan vendor:publish --provider="farenas\AdodbConect\Providers\AdodbConectServiceProvider"

php artisan vendor:publish --tag=oracle
 php config/oracle.php 
 php
return [
    'oracle' => [
        'driver'         => config('dbConfig.DB_DRIVER'),
        'tns'            => config('dbConfig.DB_TNS'),
        'host'           => config('dbConfig.DB_HOST'),
        'port'           => config('dbConfig.DB_PORT'),
        'database'       => config('dbConfig.DB_DATABASE'),
        'username'       => config('dbConfig.DB_USERNAME'),
        'password'       => config('dbConfig.DB_PASSWORD'),
        'charset'        => config('dbConfig.DB_CHARSET'),
        'prefix'         => config('dbConfig.DB_PREFIX'),
        'prefix_schema'  => config('dbConfig.DB_SCHEMA_PREFIX'),
        'server_version' => config('dbConfig.DB_SERVER_VERSION'),
    ],
];
 php config/dbConfig.php 
 php
return [
    'DB_DRIVER' => 'oracle',
    'DB_CONNECTION' => 'oracle',
    'DB_HOST' => 'localhost',
    'DB_PORT' => '1070',
    'DB_DATABASE' => 'name_db',
    'DB_USERNAME' => 'root',
    'DB_PASSWORD' => 'password',
    'DB_TNS' => 'tns_names',
    'DB_CHARSET' => 'AL32UTF8',
    'DB_PREFIX' => '',
    'DB_SCHEMA_PREFIX' => '',
    'DB_SERVER_VERSION' => '11g',
    'STRIP_TAGS' => true,
    'EXCEP_TAGS' => '', //'<p><a><h1>'
];
 php
php artisan vendor:publish --provider="farenas\AdodbConect\Providers\AdodbConectServiceProvider"

php artisan vendor:publish --tag=oracle
 php
use AdodbConect;

$paramAdoDb = [
    'cursor' => true,
    'plsql'  => 'PackageOracle.function_package(:codUser, :codCompany);',
    'datos'  => [
        'codUser' => 2222,
        'codCompany' => 6655
    ]
];

AdodbConect::param($paramAdoDb)->run();