You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Thanks for adding the primary key.
I do have an issue with using the produced script.
Due to the replication I am not able/allowed to drop the table.
"Cannot drop the table 'dbo.SqlServerVersions' because it is being used for replication."
Would be nice if there was a commandline option which let's you decide to create a full script (including creation of the table), or 'just' the data, with an additional DELETE statement to clean the table first.
DELETE
FROM dbo.SqlServerVersions
The text was updated successfully, but these errors were encountered:
I like your proposed solution. But as I think about it, dropping the table feels a bit unnecessary in the default case. I'm thinking I'll change to TRUNCATE / DELETE as the default behavior - rather than through a command line option.
What do you think about that?
If the schema of the table ever needs to be changed, detection of old schemas / migration can be included then.
We are using a 'central' database DBADB which we replicate into our infrastructure.
Similar to what has been explained here http://allen-mcguire.blogspot.com/2014/11/work-smarter-not-harder-utility-instance.html
This allows us to just install/manage our utility scripts/procedures and tables at one central location.
We use the SqlServerVersions table in conjunction with the FirstResponderKit from Brent
Creating the table only when it is not there yet, and always doing a DELETE first would work. TRUNCATING is not supported.
Thanks for adding the primary key.
I do have an issue with using the produced script.
Due to the replication I am not able/allowed to drop the table.
"Cannot drop the table 'dbo.SqlServerVersions' because it is being used for replication."
Would be nice if there was a commandline option which let's you decide to create a full script (including creation of the table), or 'just' the data, with an additional DELETE statement to clean the table first.
DELETE
FROM dbo.SqlServerVersions
The text was updated successfully, but these errors were encountered: