You can add, modify, or delete rows in the Preview view. When you have finished manipulating the data, you can apply the changes to the database.
If looking at data from a view or from more than one table By default, you cannot update data in a DataWindow object that contains a view or more than one table. For more about updating DataWindow objects, see Chapter 21, “Controlling Updates in DataWindow Objects.”
To modify existing data:
Tab to the field and enter a new value.
The Preview view uses validation rules, display formats, and edit styles that you have defined for the columns, either in the Database painter or in this particular DataWindow object.
To save the changes to the database, you must apply them, as described below.
To add a row:
Click the Insert Row button.
PowerBuilder creates a blank row.
Enter data for a row.
To save the changes to the database, you must apply them, as described below.
Adding a row in an application Clicking the Insert Row button in the Preview view is equivalent to calling the InsertRow method and then the ScrollToRow method at runtime.
To delete a row:
Click the Delete Row button.
PowerBuilder removes the row from the display.
To save the changes to the database, you must apply them, as described below.
Deleting a row in an application Clicking the Delete Row button in the Preview view is equivalent to calling the DeleteRow method at runtime.
To apply changes to the database:
Click the Update Database button.
PowerBuilder updates the table with all the changes you have made.