Comments
8 comments
-
Hi @DBADave !
I'm afraid it's not possible to exclude a folder at the moment. Can you please add a feature request for this on our uservoice forum? https://redgate.uservoice.com/forums/141379-sql-compare
Just to confirm though, are you mainly looking to exclude static data? You should be able to do this via the /Include:StaticData switch.
>>If not, then what's the /exclude:Table syntax to exclude any table starting with a #
Just to confirm, do you mean temporary tables in a pre/post deployment scripts?
-
@DBADave - what are you trying to achieve? Are you just needing to deploy schema changes and not static data? If so, can you explain why? -
Yes, it's to ignore scripts with # or ## table names in them. These are sometimes created for data migration purposes and developers often use the same #table names in multiple scripts.Jessica R said:Hi @DBADave !
I'm afraid it's not possible to exclude a folder at the moment. Can you please add a feature request for this on our uservoice forum? https://redgate.uservoice.com/forums/141379-sql-compare
Just to confirm though, are you mainly looking to exclude static data? You should be able to do this via the /Include:StaticData switch.
>>If not, then what's the /exclude:Table syntax to exclude any table starting with a #
Just to confirm, do you mean temporary tables in a pre/post deployment scripts?
-
I'm trying to compare my local Git repository with a database. When building the snapshot if there's multiple files in my Scripts folder that contain a reference to the same #temp table then the snapshot creation fails.David Atkinson said:@DBADave - what are you trying to achieve? Are you just needing to deploy schema changes and not static data? If so, can you explain why? -
@DBADave - In your opinion should the snapshot creation succeed (ie, is this a bug in SQL Compare) or do you think these #temp tables shouldn't be used in your scripts? -
@David Atkinson - Yes I think the snapshot should succeed as these scripts are manipulating data rather than creating database objects. Would it be fair to say if the static data exclusion is used then these files would get ignored if they were in the StaticData folder? -
I would _guess_ that the contents of the Data folder would be ignored if this option is used. Howevever, if this turns out to be a SQL Compare bug, it might be best to open a support ticket, particularly if you can attach the simplest example of a failure case scripts folder, as having something reproducible makes it easier for us to consider a fix.DBADave said:@David Atkinson - Yes I think the snapshot should succeed as these scripts are manipulating data rather than creating database objects. Would it be fair to say if the static data exclusion is used then these files would get ignored if they were in the StaticData folder? -
Yes, it's to ignore scripts with # or ## temp table definition.Jessica R said:Hi @DBADave !
I'm afraid it's not possible to exclude a folder at the moment. Can you please add a feature request for this on our uservoice forum? https://redgate.uservoice.com/forums/141379-sql-compare
Just to confirm though, are you mainly looking to exclude static data? You should be able to do this via the /Include:StaticData switch.
>>If not, then what's the /exclude:Table syntax to exclude any table starting with a #
Just to confirm, do you mean temporary tables in a pre/post deployment scripts?
Add comment
Please sign in to leave a comment.
Is there a way when using the command line with a Script source to exclude either an entire subfolder of the Scripts root folder? If I have \Database\Tables\ & \Database\Static Data\, can I exclude "Static Data"? If not, then what's the /exclude:Table syntax to exclude any table starting with a # ?
Thanks.