Skip to content

Instantly share code, notes, and snippets.

@AlifArnado
Last active April 20, 2022 17:32
Show Gist options
  • Select an option

  • Save AlifArnado/d42594666e2eaa882a15d9c5a0233bc5 to your computer and use it in GitHub Desktop.

Select an option

Save AlifArnado/d42594666e2eaa882a15d9c5a0233bc5 to your computer and use it in GitHub Desktop.

Revisions

  1. alif benden arnado revised this gist Apr 26, 2021. 1 changed file with 15 additions and 7 deletions.
    22 changes: 15 additions & 7 deletions Setting connection CI4 + SQL Server
    Original file line number Diff line number Diff line change
    @@ -1,10 +1,10 @@
    public $default = [
    'DSN' => '',
    'hostname' => 'ALIF\SQLSERVER',
    'username' => 'sa',
    'password' => 'peksi',
    'database' => 'Doq_legend',
    'DBDriver' => 'sqlsrv',
    'hostname' => '', // hostname login sql server
    'username' => 'sa', // user login sql server
    'password' => '', // password login sql server
    'database' => '', // database di sql server
    'DBDriver' => 'sqlsrv', // default driver sql server
    'DBPrefix' => '',
    'pConnect' => false,
    'DBDebug' => (ENVIRONMENT !== 'production'),
    @@ -15,5 +15,13 @@ public $default = [
    'compress' => false,
    'strictOn' => false,
    'failover' => [],
    'port' => '',
    ];
    'port' => '', // port di kosongkan jika error bisa di isi
    ];

    Requirement
    1. SQL Server 2016
    2. ODBC SQL Server Driver ver 17
    3. Up PHP 3 or PHP 4
    4. Driver PHP include extension php.ini in folder apache and folder php
    - php_pdo_sqlsrv_73_ts_x64
    - php_sqlsrv_73_ts_x64
  2. alif benden arnado created this gist Apr 26, 2021.
    19 changes: 19 additions & 0 deletions Setting connection CI4 + SQL Server
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,19 @@
    public $default = [
    'DSN' => '',
    'hostname' => 'ALIF\SQLSERVER',
    'username' => 'sa',
    'password' => 'peksi',
    'database' => 'Doq_legend',
    'DBDriver' => 'sqlsrv',
    'DBPrefix' => '',
    'pConnect' => false,
    'DBDebug' => (ENVIRONMENT !== 'production'),
    'charset' => 'utf8',
    'DBCollat' => 'utf8_general_ci',
    'swapPre' => '',
    'encrypt' => false,
    'compress' => false,
    'strictOn' => false,
    'failover' => [],
    'port' => '',
    ];