Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 20 additions & 0 deletions .github/ISSUE_TEMPLATE.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
## Versions

* Laravel: Run `php artisan --version` to show the version.
* PHP: Run `php --version` to show the version.
* Composer: Run `composer --version` to show the version.
* uepg/laravel-sybase: Get the version in `composer.lock`.

## Expected behavior

What should have happened? Please include as much detail as possible.

## Actual behavior

What actually happened? Please include as much detail as possible.

## Steps to reproduce

1. Step 1
1. Step 2
1. Step 3
10 changes: 10 additions & 0 deletions .github/PULL_REQUEST_TEMPLATE.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
## Changes

* Feature 1
* Feature 2
* Change 1
* Change 2
* Change 3
* Deletion 1
* Fix #123
* ...
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
/vendor
composer.lock
154 changes: 154 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,154 @@
# Release Notes

## [Unreleased](https://github.com/uepg/laravel-sybase/compare/2.1.2...master)


## [2.1.2 (2019-04-19)](https://github.com/uepg/laravel-sybase/compare/2.1.1...2.1.2)

Merge pull request [#43](https://github.com/uepg/laravel-sybase/pull/43) from afgloeden/master

Problem with constraint length of the primary key fixed


## [2.1.1 (2019-04-05)](https://github.com/uepg/laravel-sybase/compare/2.1.0...2.1.1)

Merge pull request [#42](https://github.com/uepg/laravel-sybase/pull/42) from afgloeden/master

Changes related to PSR's


## [2.1.0 (2019-01-23)](https://github.com/uepg/laravel-sybase/compare/2.0...2.1.0)

See README


## [2.0 (2017-08-02)](https://github.com/uepg/laravel-sybase/compare/1.3.2...2.0)

Merge pull request [#36](https://github.com/uepg/laravel-sybase/pull/36) from marcelovsantos/master

Correction test for 5.3 and 5.4


## [1.3.2 (2017-03-14)](https://github.com/uepg/laravel-sybase/compare/1.3.1...1.3.2)

Better identention


## [1.3.1 (2017-03-14)](https://github.com/uepg/laravel-sybase/compare/1.3...1.3.1)

Fix [#29](https://github.com/uepg/laravel-sybase/issues/29)


## [1.3 (2017-01-24)](https://github.com/uepg/laravel-sybase/compare/1.2.1...1.3)

Merging dev in master


## [1.2.1 (2016-09-16)](https://github.com/uepg/laravel-sybase/compare/1.2.0.7...1.2.1)

Added support to multiples resultset


## [1.2.0.7 (2016-06-09)](https://github.com/uepg/laravel-sybase/compare/1.2.0.6...1.2.0.7)

Merge branch 'case_insensitive'


## [1.2.0.6 (2016-06-06)](https://github.com/uepg/laravel-sybase/compare/1.2.0.5...1.2.0.6)

Merge branch 'multiple_connections'


## [1.2.0.5 (2016-06-02)](https://github.com/uepg/laravel-sybase/compare/1.2.0.4...1.2.0.5)

Fix a offset problem in joins


## [1.2.0.4 (2016-05-23)](https://github.com/uepg/laravel-sybase/compare/1.2.0.3...1.2.0.4)

Fix [#13](https://github.com/uepg/laravel-sybase/issues/13)


## [1.2.0.3 (2016-05-19)](https://github.com/uepg/laravel-sybase/compare/1.2.0.2...1.2.0.3)

Fix [#13](https://github.com/uepg/laravel-sybase/issues/13) for insert, remove and update


## [1.2.0.2 (2016-05-18)](https://github.com/uepg/laravel-sybase/compare/1.2.0.1...1.2.0.2)

Fix [#14](https://github.com/uepg/laravel-sybase/issues/14)


## [1.2.0.1 (2016-05-12)](https://github.com/uepg/laravel-sybase/compare/1.2...1.2.0.1)

Add money to


## [1.2 (2016-05-03)](https://github.com/uepg/laravel-sybase/compare/1.1...1.2)

Merge branch 'dev'


## [1.1 (2016-03-16)](https://github.com/uepg/laravel-sybase/compare/1.0.3...1.1)

Probably fixed [#11](https://github.com/uepg/laravel-sybase/issues/11) and possible other problems with querys builded without query builder (but all binds will be considered strings by default)


## [1.0.3 (2016-02-18)](https://github.com/uepg/laravel-sybase/compare/1.0.2...1.0.3)

Fix [#8](https://github.com/uepg/laravel-sybase/issues/8)


## [1.0.2 (2015-12-21)](https://github.com/uepg/laravel-sybase/compare/1.0.1...1.0.2)

Minor fixes and better stability.


## [1.0.1 (2015-12-21)](https://github.com/uepg/laravel-sybase/compare/1.0...1.0.1)

Now offset works, but it is slow.


## [1.0 (2015-12-21)](https://github.com/uepg/laravel-sybase/compare/0.3...1.0)

Now offset works, but it is slow.


## [0.3 (2015-12-16)](https://github.com/uepg/laravel-sybase/compare/0.2.4...0.3)

Probably fixed [#4](https://github.com/uepg/laravel-sybase/issues/4) and [#5](https://github.com/uepg/laravel-sybase/issues/5)


## [0.2.4 (2015-12-10)](https://github.com/uepg/laravel-sybase/compare/0.2.3...0.2.4)

This fix [#3](https://github.com/uepg/laravel-sybase/issues/3) (workaround).


## [0.2.3 (2015-12-10)](https://github.com/uepg/laravel-sybase/compare/0.2.2...0.2.3)

Improving functions.


## [0.2.2 (2015-12-08)](https://github.com/uepg/laravel-sybase/compare/0.2.1...0.2.2)

Update Readme.


## [0.2.1 (2015-12-07)](https://github.com/uepg/laravel-sybase/compare/0.2...0.2.1)

This finally fix [#2](https://github.com/uepg/laravel-sybase/issues/2).


## [0.2 (2015-12-04)](https://github.com/uepg/laravel-sybase/compare/0.1.1...0.2)

This fix [#2](https://github.com/uepg/laravel-sybase/issues/2)


## [0.1.1 (2015-11-27)](https://github.com/uepg/laravel-sybase/compare/0.1.0...0.1.1)

Improvement in query seeking types.


## [0.1.0 (2015-11-18)](https://github.com/uepg/laravel-sybase/compare/fd48f2b402acbfd72c3a2e903dabdb2df0a8cbc6...0.1.0)

Single quote problem solved.
10 changes: 0 additions & 10 deletions Database/Query/SybaseProcessor.php

This file was deleted.

53 changes: 40 additions & 13 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,11 @@
# laravel-sybase
# Sybase ASE based Eloquent module extension for Laravel 5.x

[![Packagist Version](https://img.shields.io/packagist/v/uepg/laravel-sybase.svg)](https://packagist.org/packages/uepg/laravel-sybase)
[![PHP from Packagist](https://img.shields.io/packagist/php-v/uepg/laravel-sybase.svg)](https://packagist.org/packages/uepg/laravel-sybase)
[![Packagist](https://img.shields.io/packagist/dt/uepg/laravel-sybase.svg)](https://packagist.org/packages/uepg/laravel-sybase/stats)
[![GitHub contributors](https://img.shields.io/github/contributors-anon/uepg/laravel-sybase.svg)](https://github.com/uepg/laravel-sybase/graphs/contributors)
[![GitHub](https://img.shields.io/github/license/uepg/laravel-sybase.svg)](https://github.com/uepg/laravel-sybase/blob/master/LICENSE)

Sybase ASE based Eloquent module extension for Laravel 5.x.
* Enables use of multiple kinds of fields.
* Use default eloquent: works with odbc and dblib!
* Migrations! (WIP - Work in Progress)
Expand All @@ -26,10 +31,16 @@ Update the package dependencies executing:
composer update
```

Add the following entry to your providers array in **config/app.php** file:
Add the following entry to your providers array in **config/app.php** file, optional in Laravel 5.5 or above:

```php
Uepg\LaravelSybase\Database\SybaseServiceProvider::class
Uepg\LaravelSybase\SybaseServiceProvider::class,
```

Add the following entry to your aliases array in **config/app.php** file, optional in Laravel 5.5 or above:

```php
'UepgBlueprint' => Uepg\LaravelSybase\Database\Schema\Blueprint::class,
```

Update your **config/database.php's** default driver with the settings for the **sqlsrv** or your custom odbc. See the following example:
Expand All @@ -45,14 +56,15 @@ return [
'connections' => [
...

'sqlsrv' => [
'driver' => 'sqlsrv',
'host' => env('DB_HOST', 'sybase.myserver.br:5000'),
'sybase' => [
'driver' => 'sqlsrv',
'host' => env('DB_HOST', 'sybase.myserver.com'),
'port' => env('DB_PORT', '5000'),
'database' => env('DB_DATABASE', 'mydatabase'),
'username' => env('DB_USERNAME', 'forge'),
'password' => env('DB_PASSWORD', 'secret'),
'charset' => 'utf8',
'prefix' => '',
'username' => env('DB_USERNAME', 'user'),
'password' => env('DB_PASSWORD', 'password'),
'charset' => 'utf8',
'prefix' => '',
],

...
Expand All @@ -62,6 +74,21 @@ return [
]
```

Update your **.env** with the settings for the **sqlsrv** or your custom odbc. See the following example:

```text
...

DB_CONNECTION=sybase
DB_HOST=sybase.myserver.com
DB_PORT=5000
DB_DATABASE=mydatabase
DB_USERNAME=user
DB_PASSWORD=password

...
```

## Configuration of freetds driver

In Linux systems the driver version must be set in **freetds.conf** file to the right use of charset pages.
Expand All @@ -76,14 +103,14 @@ The file is usualy found in **/etc/freetds/freetds.conf**. Set the configuration

## Setting to use numeric data type

In the migration file you must replace `use Illuminate\Database\Schema\Blueprint;` with `use Uepg\LaravelSybase\Database\Schema\BlueprintSybase as Blueprint;`. See the following example:
In the migration file you must replace `use Illuminate\Database\Schema\Blueprint;` with `use Uepg\LaravelSybase\Database\Schema\Blueprint;`. See the following example:

```php
<?php

use Illuminate\Support\Facades\Schema;
// use Illuminate\Database\Schema\Blueprint;
use Uepg\LaravelSybase\Database\Schema\BlueprintSybase as Blueprint;
use Uepg\LaravelSybase\Database\Schema\Blueprint; // or "use UepgBlueprint as Blueprint"
use Illuminate\Database\Migrations\Migration;

class CreateTable extends Migration
Expand Down
28 changes: 23 additions & 5 deletions composer.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,10 @@
{
"name": "uepg/laravel-sybase",
"description": "Sybase based Eloquent module extension for Laravel 5.x.",
"type": "library",
"keywords": [
"sybase"
],
"license": "GPL-2.0-only",
"authors": [
{
"name": "Gabriel Tadra Mainginski",
Expand All @@ -12,14 +15,29 @@
"email": "mazer@uepg.br"
}
],
"minimum-stability": "dev",
"support": {
"issues": "https://github.com/uepg/laravel-sybase/issues",
"wiki": "https://github.com/uepg/laravel-sybase/wiki"
},
"require": {
"php": ">=5.5",
"laravel/framework": "5.*"
"php": "^5.6.4 || ^7.0",
"doctrine/dbal": "^2.5",
"illuminate/database": "5.4.*|5.5.*|5.6.*|5.7.*",
"illuminate/support": "5.4.*|5.5.*|5.6.*|5.7.*"
},
"extra": {
"laravel": {
"providers": [
"Uepg\\LaravelSybase\\SybaseServiceProvider"
],
"aliases": {
"UepgBlueprint": "Uepg\\LaravelSybase\\Database\\Schema\\Blueprint"
}
}
},
"autoload": {
"psr-4": {
"Uepg\\LaravelSybase\\Database\\": "Database/"
"Uepg\\LaravelSybase\\": "src/"
}
}
}
Loading