• Categories
    • PHP
    • phpMyAdmin
    • PHPMailer
    • FFMpeg
    • PHPEXcel
    • PHPDoc
    • PHPUnit
    • CakePHP
    • CakePHP 2.0
    • Cake PHP 2.1
    • CakePHP Model
    • Facebook PHP SDK
    • composer-php
    • PHP 7
    • PHP GD
    All Categories
  • About

Is it possible to change the table name in the migration file-laravel

phplaravellaravel-5


PHP Snippet 1:

protected $table = 'todoapps';

PHP Snippet 2:

<?php

namespace App;

use Illuminate\Database\Eloquent\Model;

class Flight extends Model
{
    /**
     * The table associated with the model.
     *
     * @var string
     */
    protected $table = 'my_flights';
}

Related Snippets

Laravel Pagination links() not working

Dropzone: Submit both form data and dropzone at once

Laravel Pagination links() not working

(Laravel) How to delete multiple models including optional relationships?

Symfony Make:Migration : The metadata storage is not up to date, please run the sync-metadata-storage command to fix this issue

Fetch files from next cloud storage and display in Laravel website

Maatwebsite Excel 3.1 : how do I skip duplicate data when imported?

Redis Command To Sort Keys

Laravel passport auth token not working after moving to different server

Is it possible to re-use an array taken from PHP via JSON in a $.ajax function?

advanced custom fields wordpress custom class

How to Display Data in Yajra Datatables Laravel 7?

Split comma separated value from table column into rows using mysql?

How do I set the maximum php memory limit

Laravel s3 upload file with metadata using pre-signed url

About Contact Privacy policy Terms and conditions