In this chapter, we replaced the file-based CMS from Chapter 1 with a database version. You should now have a basic understanding of working with SQL Server Express 2005 and ASP.NET, as well as a basic understanding of how SQL Server works. You should be able to create a database, create a table in that database, and add columns to that table within SQL Server Management Studio Express.
We also explored the SqlDataSource, and using SQL Server 2005 Express as a source for data in our application. We created both a SelectCommand
and an UpdateCommand
to be used in that SqlDataSource to select records and modify the data in specific fields. You should also understand the role of the ConnectionString
in the web.config
in providing a connection to the database. As you work with ASP.NET and databases, you will find that moving applications to new systems will require changes to the connection string to get the database connected to the application. The web site at http://www.connectionstrings...