small medium large xlarge

30 Oct 2008, 15:40
Abder-Rahman Hasan Ali (5 posts)

In the book, page (87) and in this paragraph:

Let’s create a data-only migration. The up method CLEARS out the products table, then adds three rows containing typical data to our products table. The down method EMPTIES the table. The migration is created just like any other.

What is the difference between “Clearing” a table and between “Emptying” a table?

30 Oct 2008, 19:37
James West (104 posts)

Hi, You could do with updating the book to the latest version This is on page 90!

If you look at the code you’ll see that the up method deletes all records then adds some new ones and the down method just deletes all the records

Empty and clear out are just interchangeable terms that mean the same thing. i.e. clear out the car and empty out the car. Same dofference in this instance.



You must be logged in to comment