StrataFrame Forum

How to deploy a package into another server (selecting specifics objects)

http://forum.strataframe.net/Topic17258.aspx

By Angela Sampaio - 6/23/2008

Hi,



I would like to deploy my package to another server but i would like to exclude some objects as described attached.



ps. The destination server has a database installed with other filegroups and DDT Package-It shown me an error about these filegroups.

Is it possible to configure the exclusion objects?





Thanks






By Trent L. Taylor - 6/23/2008

No.  You cannot pick and choose a file group to deploy.  There would be all types of negative consequences that would come from this.  When you deploy, the file groups (data files) must be consistent.  This is the foundation of the database.  Now you can pick and choose deployment data, but the file groups must be the same.  This is an SMO (SQL Server Management Objects) rule, not the DDTs.
By Angela Sampaio - 6/24/2008

we will fix the problem about filegroups, but we'll have a lot of customers (greather than 500).

How can we solve the problem to deploy database changes automatically?

What's the best practice? Do it inside the code or running DDT Package-It at each database's customers?

Today in our old technology we running a script at each database but we have a lot of problem.



What do you advise me?



Thanks.


By Trent L. Taylor - 6/24/2008

The DDT is intended to upgrade data structures, and you should be able to create a DDT package that 100% upgrades an existing structure.  However, it may require that you create some pre or post execution scripts to ensure that there is not any "residue" out there.

If you do not take the time to work through an upgrade solution via the DDT right now, then you will always be creating scripts and it goes against the purpose of the DDT.

The problem is that you have some existing structures, and honestly I don't totally understand your environment or problem, but it sounds as though your current deployments are not consistent.  If this is the case, whether using the DDT or scripts, you would have to take this into account.

We created the pre deployment scripts for this very purpose, to clean up a dirty environment prior to allowing the DDT to do its thing.  The DDT will move tables from one file group into another.  So if you have a table called Customers in FileGroupA in a deployed environment, and when you deploy with the DDT it is assigned to FileGroupB, the Customers table will be moved into FileGroupB.

I hope that makes sense as I do not totally understand your problem and what types of environments and issues you are dealing with.

By Angela Sampaio - 6/24/2008

Trent, our basic needs consists in:

We created a new column on a table customers called flag_email in our enviroment.

We have to deploy this new column for all of customers that runs our system (developed with strataframe).

Is there a solution to do this when the users dowlnload the new version?



ps. Note that our customers are spreaded in our whole country.



Thanks.
By Trent L. Taylor - 6/24/2008

Absolutely.  That is the entire purpose of the DDT.  We have the very same need for our medical application.  The DDT is to be used to design the data structures.  So when you have a change that you want to deploy, you would just recreate the package.  Then you can either send out a program that uses the DDT API (DatabaseMigrator...there is a sample that comes with the framework) to update those structures.  We implement this into our installations, but you can just as easily have a program that is just a console app or a WinForms dialog that pops up and runs.  Or, if you want to get really fancy, just have a service that runs on the client and looks for an update on a server somewhere, and when it finds one, it downloads and automatically schedules a time for an update...that would be the 100% automated route.
By Angela Sampaio - 6/24/2008

Thanks Trent!

I will study this. Wink