Try OpenEdge Now
skip to main content
SQL Development
OpenEdge SQL Data Manipulation Language : Using Data Manipulation Language statements : DELETE


The DELETE statement deletes table rows specified in the statement's WHERE clause. If the optional WHERE clause is not specified, then the DELETE statement deletes all rows of the table.
When deleting row(s) of a multi-tenant table, a regular tenant can only delete rows in its partition, but a super-tenant or a DBA can delete rows in all the tenant partitions and group partitions. A super-tenant or a DBA may refine which tenants' rows must be affected by using the tenantid_tbl() or the tenantName_tbl() function in the WHERE clause search_condition.
The DELETE statement uses the following syntax:
DELETE FROM [owner_name]{table_name|view_name}[ WHERE search_condition] ;
The following example depicts a simple delete on a single table.
DELETE from Customer
WHERE Name = 'Hoops' ;
The following example deletes the row from a multi-tenant table using custnum and tenantid_tbl() in the WHERE clause.
DELETE FROM mtcustomer
WHERE custnum = 1428 AND tenantName_tbl (pub.mtcustomer) = 'SNCSoftware';
Note: A DELETE statement will fail in the event it attempts to remove rows from primary or candidate keys that reference other tables.
For more information on the DELETE statement, see OpenEdge Data Management: SQL Reference.