Data Layer Generator

Data Layer Generator

Data Layer Generator is designed to save you time in developing your Visual Studio .Net applications, and to reduce the number of coding errors. This program is a code generator that will generate C# (Microsoft .Net 2.0 Framework) code that allows the business layer of an application to communicate with the data layer.

This utility allows you to easily create an object-oriented C# data layer for your SQL Server 2005/2008 database. Within approximately two minutes you can step through the three screens necessary to generate a complete set of classes for doing your basic insert, update, and delete functions on each table in the database without writing a single line of SQL code. In addition, the utility creates all the necessary stored procedures for inserting, updating, and deleting.

Data Layer Generator is now available for purchase.

The cost of Data Layer Generator is only $9.00 for the compiled program, or $29.00 for the application with the source code.

Click on the "Purchase" button to purchase Data Layer Generator:

Compiled Application - $9.00
Application with Source Code - $29.00

Development Language & Tools:  C#, Visual Studio 2005
Database:  Microsoft SQL Server
Operating Systems Supported:  Windows 2000 / XP / Vista
Special Requirements:  Microsoft .Net Framework 2.0

What Does Data Layer Generator Produce:

When you generate your data access layer, the program will create multiple classes, one for each table in your database. Each class contains methods for inserting, updating and deleting as well as properties that map to each column in the table the class represents. Each C# class represents a row in the related table and the program also produces custom collections that map to multiple records in the table.


For an easy example, let’s consider you have an existing database with one table called TCustomer. After running the utility and selecting your existing database, the program will output a class called TCustomer.cs and TCustomers.cs. The first class (TCustomer.cs) will contain properties that directly map to each column in the table so there might be a property called LastName, FirstName, and SocialSecurityNumber. This class will also have the following methods created that allow you manipulate data in that table:

1) Insert – inserts all of the properties into a new record in the database
2) Update – updates the current properties to an existing record in the database
3) Delete – removes a given record from the database
4) SelectOne – given a primary key, will retrieve one record from the database and returns an instance of the TCustomer class.
5) SelectAll – returns all the records in TCustomer in the form of an instance of the custom collection (TCustomers)
6) SelectByField – gets all records in TCustomer where the given field equals the given value and returns a collection of TCustomers

There are also some additional methods that are created when logical keys have been defined on a set of fields in a table (e.g. SelectOneByTCustomer_LogicalKeyName) and there are other methods created that handle returning child records from other tables by virtue of foreign keys (e.g. SelectOneWithTInvoices).


This utility will save you many hours of coding basic crud functionality and currently produces C# classes and stored procedures that support SQL Server 2005 and SQL Server 2008.

 

Screen Shots of Data Layer Generator:

Data Layer Generator

 

Data Layer Generator

 

Data Layer Generator

 

Data Layer Generator

 

Data Layer Generator