FForm Platform
enzh-CN

Data models and ORM

Connect forms to relational data through portable models, reference-aware queries and provider-neutral operations.

Model the database deliberately

A data model represents a table or view. Its attributes match database columns and specify nullable, calculated, primary-key and reference behavior. A reference identifies a foreign-key-like relationship without requiring FormPlatform to create a database foreign key.

Map forms to models

Form and Data Mapping connects a form to a data model. Each input control uses its property name to select the attribute it reads or writes. A generated form is only a starting point: administrators can change labels, layout, validation and control type without changing the model.

Dynamic ORM and query safety

The ORM exposes dynamic entities, repository operations, filters, sort terms, paging and transactions. It compiles provider-specific SQL for PostgreSQL, SQL Server and MySQL while preserving a common model API. References can project only the columns requested by DataGrid or AsyncSelect instead of loading an entire related table.

Data lifecycle

System and functional forms create records unless a record ID is selected for editing. Surveys use their deployment response rules. Calculated columns are read but not written. SetFields triggers can enrich records with server time, current user ID or an application-generated ID.

For database changes read architecture; for provider and migration practices read testing and quality.