Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- use Illuminate\Database\Migrations\Migration;
- use Illuminate\Database\Schema\Blueprint;
- use Illuminate\Support\Facades\Schema;
- class CreateKaryawansTable extends Migration
- {
- /**
- * Run the migrations.
- *
- * @return void
- */
- public function up()
- {
- Schema::create('tbl_karyawan', function (Blueprint $table) {
- $table->string('employee_number', 50)->primary('employee_number');
- $table->string('employee_name', 150);
- $table->enum('gender', ['M', 'L']);
- $table->tinyInteger('status', 1)->default(1)->autoIncrement(false);
- $table->timestamps();
- });
- }
- /**
- * Reverse the migrations.
- *
- * @return void
- */
- public function down()
- {
- Schema::dropIfExists('tbl_karyawan');
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement