Skip to content

Commit

Permalink
added subject migration
Browse files Browse the repository at this point in the history
  • Loading branch information
deepikagonuguntla committed Jan 16, 2025
1 parent 0963d33 commit 40d07d1
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 2 deletions.
6 changes: 6 additions & 0 deletions db/migrate/20250116145738_change_title_to_text_in_subjects.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
class ChangeTitleToTextInSubjects < ActiveRecord::Migration[7.2]
def change
# Change the column from string to text
change_column :subjects, :title, :text
end
end
4 changes: 2 additions & 2 deletions db/schema.rb
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
#
# It's strongly recommended that you check this file into your version control system.

ActiveRecord::Schema[7.2].define(version: 2024_11_03_215851) do
ActiveRecord::Schema[7.2].define(version: 2025_01_16_145738) do
# These are extensions that must be enabled in order to support this database
enable_extension "plpgsql"

Expand Down Expand Up @@ -173,7 +173,7 @@
end

create_table "subjects", id: :serial, force: :cascade do |t|
t.string "title", limit: 30
t.text "title"
t.datetime "created_at", precision: nil
t.datetime "updated_at", precision: nil
t.index ["title"], name: "index_subjects_title", unique: true
Expand Down

0 comments on commit 40d07d1

Please sign in to comment.