Search SSIS packages for table/column references

Posted by Nigel Rivett on Simple Talk See other posts from Simple Talk or by Nigel Rivett
Published on Thu, 07 Nov 2013 12:26:11 +0000 Indexed on 2013/11/07 16:07 UTC
Read the original article Hit count: 344

Filed under:

A lot of companies now use TFS or some other system and keep all their packages in a single project. This means that a copy of all the packages will end up on your local disk.

There is major failing with SSIS that it is sometimes quite difficult to find what a package is actually doing, what it accesses and what it affects.

This is a simple dos script which will search through all packages in a folder for a string and write the names of found packages to an output file.

Just copy the text to a .bat file (I use aaSearch.bat) in the folder with all the package scripts Change the output filename (twice), change the find string value and run it in a dos window. It works on any text file type so you can also search store procedure scripts – but there are easier ways of doing that.

echo. > aaSearch_factSales.txt for /f “delims=” %%a in (‘dir /B /s *.dtsx’) do call :subr “%%a” goto:EOF

:subr findstr “factSales” %1 if %ERRORLEVEL% NEQ 1 echo %1 >> aaSearch_factSales.txt goto:EOF

© Simple Talk or respective owner

Related posts about Uncategorized