How to make laravel integer data type migration

Here we will discuss Laravel integer type column migration. how to make integer type migration.

Laravel integer data type migration

Laravel migration integer() method create mysql INTEGER type column. Integer type column only store integer values.

public function up()
{
    Schema::create('users', function (Blueprint $table) {
        $table->integer('visitors');
    });
}
php laravel developer anmol sharma

Anmol Sharma

I am a software engineer and have experience in web development technologies like php, Laravel, Codeigniter, javascript, jquery, bootstrap and I like to share my deep knowledge by these blogs.

Random tutorial links