rroblak/seed_dump

Last N records instead of first

samuelcouch opened this issue · 1 comments

Is it possible to get a dump of the last latest records rather than the earliest?

You can use the Seed Dump in the Rails console to do this. For example:

SeedDump.dump(User.order(created_at: :desc), file: 'db/seeds.rb')