typeorm-seeding
typeorm-seeding copied to clipboard
Generate SQL commands
Is there a way to generate a SQL file of all the commands instead of running them directly in the db? Something like the SCHEMA file that RubyOnRails creates.
We are trying to improve the speed of DB preparation for automated testing. Currently the seed takes >1min to run. So If we could generate the SQL in an upfront step, then we could potentially save some time (30sec)
Any idea how this could be done.
Probably what you are looking for should be on TypeORM (synchronize option), probably generating all the schema at once that could be done with a simple command.
If your problem is that you already have the schema and need the seeding on SQL, I'm sorry, but the library currently doesn't have any functionality like that (and don't expect in short term, I'm out of time).