I want to merge multiple SQL files into a single SQL file. All I could find over the internet is to create a batch file and execute all the files. However, I want to create a single script file. Any help would be appreciated?
Also, can this be done using C#?
assuming your files are in one place/folder
you can use like this from the command line in windows,
cd c:\folder
for %F in (*.sql) do ( type %F >> final.sql )
Note: >> is used for appending to an existing file, wherein > will overwrite the file everytime
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With