This repository was archived by the owner on Nov 27, 2020. It is now read-only.
File tree Expand file tree Collapse file tree 1 file changed +32
-2
lines changed Expand file tree Collapse file tree 1 file changed +32
-2
lines changed Original file line number Diff line number Diff line change 1
1
# Laravel ORM for Microsoft Access DB
2
-
3
2
[ ![ Latest Stable Version] ( https://poser.pugx.org/zoilomora/laravel-msaccess/v/stable )] ( https://packagist.org/packages/zoilomora/laravel-msaccess )
4
3
[ ![ Total Downloads] ( https://poser.pugx.org/zoilomora/laravel-msaccess/downloads )] ( https://packagist.org/packages/zoilomora/laravel-msaccess )
5
4
[ ![ Latest Unstable Version] ( https://poser.pugx.org/zoilomora/laravel-msaccess/v/unstable )] ( https://packagist.org/packages/zoilomora/laravel-msaccess )
9
8
This package helps you to manage ** Microsoft Access DB** by ** ODBC Connection**
10
9
with the integrated [ Laravel] ( https://github.com/laravel/laravel ) ORM.
11
10
12
- ## License
11
+ ## Installation
12
+ 1 ) Install via composer
13
+ ```
14
+ composer require zoilomora/laravel-msaccess
15
+ ```
16
+
17
+ 2 ) Add Service Provider to ` config/app.php ` in ` providers ` section:
18
+ ``` php
19
+ \ZoiloMora\AccessServiceProvider::class,
20
+ ```
21
+
22
+ 3 ) Create a ** DSN** with the connection to the database.
13
23
24
+ 4 ) Add connection to ` config/database.php ` in ` connections ` section:
25
+ ``` php
26
+ 'access' => [
27
+ 'driver' => 'pdo_access',
28
+ 'connection_string' => 'dsn={namedsn}',
29
+ 'username' => '',
30
+ 'password' => '',
31
+ 'table_prefix' => '',
32
+ ]
33
+ ```
34
+
35
+ 5 ) Replace ` {namedsn} ` with the ** name of DSN** .
36
+
37
+ ## Connect model with the connection
38
+ 1 ) In the model class add the ` $connection ` variable like this:
39
+ ``` php
40
+ protected $connection = 'access';
41
+ ```
42
+
43
+ ## License
14
44
Licensed under the [ MIT license] ( http://opensource.org/licenses/MIT )
15
45
16
46
Read [ LICENSE] ( LICENSE ) for more information
You can’t perform that action at this time.
0 commit comments