Data Access has been discontinued. Please refer to this page for more information.

Using the Database First Approach

This article is relevant to entity models that utilize the deprecated Visual Studio integration of Telerik Data Access. The current documentation of the Data Access framework is available here.

Telerik Data Access applications and services are based on the domain model. This model represents application data as a set of persistent classes and relationships that are mapped to a defined data source. A domain model consists of a conceptual model expressed as types and relationships, a storage model that represents the schema of the logical model, and a mapping between the two. To meet the needs of developers who want to derive a domain model from an existing database, Telerik Data Access provides a set of modeling tools that generate a domain model, validate a domain model, and create persistent classes based on the storage (database) model. The database first scenario has been available since the very beginning of Telerik Data Access.

Namely, this is the first approach you can choose to migrate your NHibernate data model to Telerik Data Access Domain Model.

Pros and Cons

The Telerik Data Access Visual Designer is designed to help you build Telerik Data Access applications. With the Visual Designer you can create a domain model from an existing database and then graphically visualize and edit your domain model. Basically, it allows point-and-click modification of your data (domain) classes. You can also validate a domain model.

The biggest disadvantage of this approach is that you won't be able to re-use the currently existing data classes. You will have to delete them and re-generate them by using the Add New Domain Model Wizard.

References

  • Getting Started with Database First Scenario - demonstrates how to create a domain model based on an existing database. It will show you how to connect to the database, select the necessary objects and define the Domain Model naming settings and advanced options.
  • Consuming a Model - Configuration - demonstrates how to create a new Telerik Data Access Domain Model, capsulate it in a separate project (assembly), and then reuse the model in different applications.
  • Consuming a Model - CRUD - shows how to utilize your Telerik Data Access Domain Model for your Create, Retrieve, Update and Delete operations.