Write changes to the database
- Last UpdatedJan 16, 2025
- 1 minute read
You can write changes to the database if the following conditions are met:
-
The database query (or table) can be updated.
-
The ConfiguredReadOnly custom property value is False.
-
SQL Server security allows the security mode configured at the grid to perform an update.
-
Changes made in the grid are consistent with the database schema.
Changes made in the grid are written to the database using the Write command. Changes are handled as a single database transaction. If any change fails, the entire set of changes is rolled back.
If you have sufficient privileges, you can change a value and select Write. You can also use a script to set the CmdWrite property. This action causes the grid contents to be evaluated for changes and for the changes to be written to the database.
Tip: After you modify cells in the grid and write them back to the database, you should also verify that the data is correctly written. In certain cases, such as a database table with an automatically incrementing primary key or interdependent cells, the grid does not show the true contents of the database table after you write back to it. Also, no error message is shown. It is recommended that you execute a retrieve or auto refresh command after writing to the database to make sure it is showing the current data.