yajra / laravel-oci8

Oracle DB driver for Laravel via OCI8

Home Page:https://yajrabox.com/docs/laravel-oci8

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Use startingValue() instead of start() for compatibility

nmalcolm opened this issue · comments

commented

Summary of problem or feature request

With MySQL/Postgres, we can specify where the auto increments value starts from using startingValue(). With this package, the method is start(). If using startingValue() it will fail silently.

It's possible this was done for a reason (perhaps not being able to override startingValue()). Either start() should be renamed to startingValue() or it should fail loudly as something like this is easy to miss.

Code snippet of problem

$table->id()->startingValue(10000); // Will be ignored

System details

  • Ubuntu 22.04
  • PHP 8.1
  • Laravel 10
  • Laravel-OCI8 10

If I recall correctly, I implemented that feature even before Laravel does. We could add an alias method to conform with the framework without breaking any code.