I was asked to create a single SQL script from a document that has cvs links for each sql. Here is what I did,
- Download DAP a.ka. Download accelerator
- Copy all the CVS links into a text file
- Replace "&view=markup" and "&view=auto" with blanks
- Open Download accelerator and import the text file (File -> Import -> Plan text file)
- Download all
- exeute dos2unix command in downloaded directory
- execute this command in unix (or cygwin for windows)
find . -type f -iname "*.prc" -exec cat {} >> ../sp_implementation_script.txt \; - execute this command to generate list of file names included with number of files
$ echo -e "Number of files \n---------------\n`ls -1 | wc -l`\n\nFile Name\n---------" > ../sp_implementation_script_list.txt
find . -type f -iname "*.prc" -exec ls {} >> ../sp_implementation_script_list.txt \; - execute this command in unix (or cygwin for windows)
find . -type f -iname "*.prc" -exec cat {} >> ../sp_rollback_script.txt \; - execute this command to generate list of file names included with number of files
$ echo -e "Number of files \n---------------\n`ls -1 | wc -l`\n\nFile Name\n---------" > ../sp_rollback_script_list.txt
find . -type f -iname "*.prc" -exec ls {} >> ../sp_rollback_script_list.txt \;