BLACK FRIDAY
From November 21
to December 02
99Days : 99Hrs : 99Min : 99Sec
SAVE UP TO$3K
Also valid for the
existing customers!
Version

Generating CRUD Pages From an Existing Database Table

If you have an existing database table, you can generate the entities using ABP Suite and create a CRUD page based on those entities, let's get started.

Create/open your project

abpsuite

Either create a new project or open an existing project that's based on an app or module template.

Generate the Entities

After opening the project in ABP Suite, scroll down to the bottom and click the Load Entity From Database button:abpsuite2

This will open the window seen below, choose the data source of your database and add the connection string of your project:abpsuite3

Click the lightning icon to test the connection, and then connect to the database by clicking connect, and this should extend the window as the following window:abpsuite4

Uncheck the Id property since it automatically gets generated, it'll cause an error if we generate it twice, then click OK:abpsuite5

After that, make sure the primary key type is selected, then click Save and generate:abpsuite6

The following GIF is a summary of the previous steps: SUTIE_GIF

Run the Project!

After that, run the project and watch the magic! An easy CRUD app using the entities from an existing database table!SUITE_GIF_2

What's next?

Accessing source code of modules

In this document
Mastering ABP Framework Book
Mastering ABP Framework