filter rules and deploy script

Hi

We have filter rules (filter.scpf file) to exclude tables that have the _TEMP_ , _REBUILD_TMP_ keywords in the tale name.

(@NAME LIKE '%[_]TEMP[_]%') OR (@NAME LIKE '%[_]REBUILD[_]TMP[_]%')

We have a bunch of temp tables that get created/dropped which have those keywords. While generating deployment script for sql promotions, we get interim failures due to these temp tables. 

Our understanding is that these tables should not be included in the comparison for the deployment script.

Are we missing something ?

regards
Kiran
Tagged:

Answers

  • Eddie DEddie D Posts: 1,807 Rose Gold 5
    Hi Kiran, thank you for your forum post.

    I suspect your post should be in the SQL Compare forum, as SQL Source Control does not generate deployment scripts.

    Despite the filter, all objects are included in the comparison.  If using the GUI, the filter objects are not shown on the results tab and therefore cannot be selected for deployment.  Likewise if using the command line, the filtered object is not selected for deployment.

    However, there is one scenario where a filtered object is still included for deployment if the option to 'Include Dependencies'  is enabled. 

    Using the GUI, you will need to observe for this when running the deployment wizard. 

    Or if using the command line, check the syntax and remove the option IncludeDependencies or its alias incd.  IncludeDependencies is one of the default options, so if the /options: switch is omitted or the /options:Default is included, IncludeDependcies is automatically included.  Further reading available here.

    Many Thanks
    Eddie


    Eddie Davis
    Senior Product Support Engineer
    Redgate Software Ltd
    Email: support@red-gate.com
Sign In or Register to comment.