Create Server Data Store
Key Lesson: In this step, you learn how to create a **Server Data Store** and configure which transactional entities are persisted to the application database.
Create a Server Data Store for the Purchasing app and add the four transactional entities created earlier as part of defining the data model.
1. Create the Server Data Store
Section titled “1. Create the Server Data Store”- Go to Design.
- Select ServerDataStore under Object Types.
- Click +.
- Enter PurchaseDB and click OK.
When the editor opens, leave the following GENERAL settings at their default values:
| Setting | Value |
|---|---|
| STORE TYPE | DataBase |
| USE SYSTEM DATABASE | Enabled (default) |
| DATABASE SCHEMA NAME | solution |
| CREATE DB TABLES FOR STATIC ENTITIES | Disabled (default) |
2. Add the transactional entities
Section titled “2. Add the transactional entities”Under Entity configurations, use SELECT ENTITIES to select the four transactional entities created earlier:
| Entity | Selection |
|---|---|
| Purchasing.PurchaseRequest | Selected |
| Purchasing.PurchaseRequestItem | Selected |
| Purchasing.Quotation | Selected |
| Purchasing.QuotationItem | Selected |
Note
After an entity is selected, it appears under CONFIGURATION. Leave the entity configuration settings at their default values for this tutorial.
Save and close the editor.
3. Add the transactional entities
Section titled “3. Add the transactional entities”The Entity configurations section lists the entities available in the application.
-
Add the following transactional entities to the Server Data Store:
- Purchasing.PurchaseRequest
- Purchasing.PurchaseRequestItem
- Purchasing.Quotation
- Purchasing.QuotationItem
-
Leave all properties at their default values.
-
Save and close the editor.