Was this helpful?
deleterow Statement--Delete Rows from the Table Field
When a row is deleted, it disappears from the table field's display. The remaining rows in the table field are compacted and a new row is scrolled in, so that a blank row is not left in the display. Even though the deleted row disappears from the display, normally it remains in the data set, with a state of DELETED. However, if the row's state before deletion was either UNDEFINED or NEW, then when you delete the row, it disappears forever; you cannot recover such a row.
To delete table field rows use the deleterow statement.
This statement has the following syntax:
deleterow formname tablename [row]
row
Specifies the number of the displayed row to be deleted. The specified row must be in the range from 1 to the number of rows in the table field display. If row is omitted, the current row is deleted.
Example:
...
 exec frs activate menuitem 'Delete';
exec frs begin;
     /* Delete the current row 
     ** and save the employee number. */
     exec frs getrow (:eno = eno);
     exec frs deleterow empform employee
     /* Delete the corresponding row from the database. */
     exec sql delete from employee
          where eno = :eno;
exec frs end;
...
Last modified date: 04/03/2024