class CreateSubjectRecords < ActiveRecord::Migration[5.2]
  def change
    create_table :subject_records do |t|
      t.references :subject
      t.integer :study_count, default: 0
      t.integer :course_study_count, default: 0
      t.integer :initiative_study, default: 0
      t.integer :passed_count, default: 0
      t.integer :course_used_count, default: 0
      t.integer :school_used_count, default: 0
      t.timestamps
    end
  end
end
