Open joshuapinter opened 9 years ago
Would .seed_exactly
be a good name if we end up implementing this as a feature?
.seed
.seed_once
.seed_exactly
Not bad.
Is seed_once
a thing? I find that name non-descriptive.
seed_once
is a thing, and has been since 2010. :)
Wow, circling back to this 4 years later. :)
Was .seed_exactly
ever implemented?
No, I don't think so.
.seed
and .seed_once
are defined in SeedFu::ActiveRecordExtension
, and the actual logic in SeedFu::Seeder
. I suppose the main challenge is turning the listed constraints & data into a query, and then removing non-matching records.
This is a question and maybe a feature request if it's not possible.
I have a seeds file for a static lookup table. I would like the table to reflect exactly what is contained in the seeds file, so if I were to remove a record from the seeds file and run a
db:seed
it would remove the record from the table as well.Is this possible? If yes, what is required? If no, what would involved with supporting it?
Thanks!