Can sql compare force a set of indexes on a table, no matter what indexes were there before
davidf
Posts: 8 New member
in SQL Compare
updating my customers (police forces) is a one way street, it is not possible to get them to reliably send me information or to run snapper so i can compare the databases. They also have a habit of creating their own indexes. Can i create an update script that will ensure that only my indexes will exist for a table, and delete ANY other index that may exist? A sort of "blind" update?
Tagged:
Answers
Unfortunately, you can't filter on index differences on SQL Compare. It has to be done on a table level since the indexes are part of the table. If you are okay with deploying all table differences (which would include the indexes), you can deploy "source only" and "in both but different" differences.
Kind regards,
David David
Product Support Engineer
SQL Compare can only create deployment scripts using a source against a target. If you are able to run a comparison between your database (source) and your customer's database (target), then you should be able to create a deployment script that will replace what your customers may have added to the table.
I hope this answer helps you out! Don't hesitate to let me know if you have any other questions.
Kind regards,
David Dang
i have another question, if i have an index on a view that needs to be created on an existing view, why does the view have to be dropped in its entirely? this is a problem for me because if the index already exists then nothing should be done (and save the customer upgrade time). is there not a setting to not drop views and just add an index if it doesnt exist?
david
Thanks for your question. Depending on the operations that are being performed by the script we may need to drop and recreate indexes or constraints. If you can provide an example, I may be able to provide more information on why specifically in your case this is occurring.
Thank you,
David Dang
Product Support Engineer