This database is at a known version. The schema_migrations table lists every migration that ran on it.
The team needs the next migration. It makes two changes to suppliers:
- a new column
rating, an exact decimal from0.0to9.9(one digit before the point, one after) - the column
sincegets the clearer namepartner_since
The editor has a place for each script. To run only one script, select its lines and push Run: only the selection runs.
- Which number does the new migration get?
- Write the up script and run it.
- Write the down script. It must bring back the schema of before the up, and keep every date in
since. Run it. - A good down lets the up run again. Run your up script a second time.