aymanelarian/laravel-sqlserver-extender

Extend SQL Server Grammar for Laravel & Lumen to fix migration

1.0.3 2018-09-21 19:09 UTC

This package is not auto-updated.

Last update: 2024-11-10 23:57:48 UTC


README

Latest Version on Packagist Software License Total Downloads

This package extend the SQL Server driver from Laravel to fix the migration error due to using custom schema name and support sql server spatial

Install

Via Composer

$ composer require AymanElarian/laravel-sqlserver-extender

Once composer has been updated and the package has been installed, the service provider will need to be loaded.

For Laravel 5, open config/app.php and add following line to the providers array:

AymanElarian\Extensions\SqlServer\SpatialServiceProvider::class,

For Lumen 5, open bootstrap/app.php and add following line under the "Register Service Providers" section:

$app->register(AymanElarian\Extensions\SqlServer\SpatialServiceProvider::class);

For Laravel 4, open app/config/app.php and add following line to the providers array:

'AymanElarian\Extensions\SqlServer\SpatialServiceProvider',

TO DO : Development plan

  • overwrite sql server grammer (compileTableExists method) to search by schema name
  • refactor grimzy's Laravel mysql-spatial package to work with sql server
  • support points in sql server
  • support polygon in sql server
  • support all other types in sql server
  • fix all test cases to run with sql server

Usage

Once you included the service provider the Laravel/Lumen will start using the custom grammar.

Contributing

Contributions are very welcome. Please see CONTRIBUTING for details.

License

The MIT License (MIT). Please see License File for more information.

Credits

Originally inspired and code refactored from grimzy's Laravel mysql-spatial package.