C# 2010 Coding Briefs Data Access
In today's high-tech, information driven world, the security of personal data is vital. We have all heard the horror stories of personal data being compromised from companies, both large and small.
The data access framework that we will develop in Coding Briefs will allow us to create datasets, execute queries, and select data in a secure, managed process.
This framework will provide a solid foundation for managing secure data access through stored procedures, allowing us to select, insert, update, and delete records from a SQL Server database. We will have access to parameterized queries and will develop an automated process for discovering stored procedure parameters.
The major areas that we will address in this brief are as follows:
-Discussing the Data Access Framework (DAL)
-Importing Libraries and Declaring Values
-Managing the Database Connections
-Preparing the Select and Execute Methods
-Working with Parameters
-Testing the Data Access Framework
And, as a bonus, two complete sample applications have been added; one for Windows, and one in ASP .Net, that will test all of the features on the data access framework.
What people are saying - Write a review
We haven't found any reviews in the usual places.
Other editions - View all
ASPX Business Object calling procedure calling program catch Exception Catch statement code in Listing Coding Briefs Data connection string Contacts database create the Command creates the SQLCommand Creating a DataSet Creating Stored Procedures data access framework Data Access Layer Data Integrity Database Connection declared as ByRef DeriveParameters method develop dialog box e.Message error is encountered errorParms[0 errorParms[2 ExecuteNonQuery method exit if int)errorParms[0 Follow these steps GetCurrentMethod().Name input parameter insert int numOutParms manipulate data normal error trapping number of Output number of rows Open the connection Output parameters Output parms Parameters collection parms variable Press F5 ref errorParms ref numOutParms ref Object retrieve return null Return the error sample projects select and execute Select form select records SELECT statement SetOutParms SetUpSP procedure shown in Listing SQL Server 2008 SQLCommand object SqlDataAdapter SSMS Stored Procedure Parameters String cbConn System.Reflection.MethodBase Transact-SQL Visual Basic Visual Studio 2010 Windows Sample Application Zip Code