라라벨/Migration 컬럼삭제하기 땀모 2020. 1. 1. 17:53 1.마이그레이션 파일을 작성한다.1php artisan make:migration drop_posts_tag_id_columcs2. 스키마를 작성한다. posts = 테이블명, tag_id = 삭제할 컬럼123456 public function up() { Schema::table('posts', function (Blueprint $table) { $table->dropColumn('tag_id'); }); }Colored by Color Scriptercs3. 마이그레이션실행한다.php artisan migrate컬럼이 삭제된것을 확인 할 수 있다. 저작자표시