Visitors to VTC.com will be able to view all introductory videos for each training course.
Free Trial Members will gain access to first three chapters for each training course.
Full Access Members have full access to VTC.com�s entire library of video tutorials.
Now before we leave the topic of deployment, I want to talk to you just a little bit about this idea of Database Deployment that takes place in these Packages because what you need to understand how it's working to understand how to deal with some of the issues that could crop up when it happens. And if you've ever worked with databases very much, especially moving these things from one server to another, you know there's only about 43 and a half million different little error messages that can pop up. So you just need to understand that when you deploy a web application, it may include dependencies on a SQLServer database. Now the Web Packages can and will deploy databases as well as web files if you need them to. And if you watch the videos, there was a 2 part video on Web Packaging and if you watched both of those, especially the second part, I, I demonstrated in there how in the Visual Web Developer environment, you can configure these databases. Well if you remember, we configured a connection string for where the database is at the time we're you know getting the package ready to deploy and then we also specify connection string for the new server where the database is going to be located. Now understanding how that database is being deployed can help you troubleshoot problems in the real world, it could also maybe get you past question on the exam, I don't know about that one for sure, but when you're working with a Web Package and you're going to deploy a database along with it, even if you're not using data, if you're not moving data, you're still probably going to be wanting to locate the database over there. Visual Studio 2010 can, is going to first of all, Visual Studio 2010 going to create SQL Scripts for the Database Schema. Now the reason it's asking you for these connection strings, both where you are and where you're going, it is going to go out there and build some scripts for moving that database. And you can also provide custom scripts and specify their sequence. Now that's your first clue, something could go wrong here and under, you know, perfect conditions, 72 degrees, a light wind, little kittens hopping around everywhere, everybody's happy and I don't know if, when the last time that has happened at your workplace, but if that day happens, that's when you should move your databases. Alright. But anyway the rest of the time, you may have to go in there and provide some custom scripts, jiggle the wires here? But at deployment, you're going to provide that connection string also for the target server. Now what's going to happen here is, the deployment process uses that new connection string and it's going to run the script files on that target server to create the database structure. So you're going to have a Create Database Command, some Create Tables, you know, all that kind of stuff. So some things are going to be happening here that could be a problem, but you just need to understand that. Now if you're not a database person, you need to run all this by your database administrator. Then once we've got the structure all the Schema in place in the new location, then it's going to basically pump any data into that new database structure on the target server. And again, this might be a place where you want to customize the scripts. But understand at the bottom of it all, what you're really doing is like an old Copy Database Command in the old SSIS environment, so just understand what's going on in the background here. We're basically taking our database, we're generating scripts from it with the old Generate Script Command. We are then running those scripts on the new server and then we're going to load the data in there. If you have any problems with this, you start getting errors to stop and think, oh wait a minute, I'm copying a database over based on scripts, so it could be a security issue, it could be any number of issues, so put your database hat on. If you're doing Database Deployment as part of your Web Package and you start to have problems. Alright. If you're not a database person, involve your DBA in this, they're probably going to be there anyway. But that's what I wanted you to understand about the Database Deployment aspect of these Web Packages.
| Course: | Designing and Developing ASP.NET 4 Web Apps (Exam 70-519) |
| Author: | Mark Long |
| SKU: | 34292 |
| ISBN: | 978-1-61866-029-9 |
| Release Date: | 2011-12-31 |
| Duration: | 8.5 hrs / 108 lessons |
| Work Files: |
Yes |
| Captions: | No |
| Compatibility: |
Vista/XP/2000, OS X, Linux QuickTime 7, Flash 8 |