![]() ![]() The row to be deleted is the one most recently fetched from this cursor. The name of the cursor to use in a WHERE CURRENT OF condition. Only rows for which this expression returns true will be deleted. conditionĪn expression that returns a value of type boolean. Do not repeat the target table as a from_item unless you wish to set up a self-join (in which case it must appear with an alias in the from_item). This uses the same syntax as the FROM clause of a SELECT statement for example, an alias for the table name can be specified. from_itemĪ table expression allowing columns from other tables to appear in the WHERE condition. For example, given DELETE FROM foo AS f, the remainder of the DELETE statement must refer to this table as f not foo. When an alias is provided, it completely hides the actual name of the table. aliasĪ substitute name for the target table. ![]() ![]() Optionally, * can be specified after the table name to explicitly indicate that descendant tables are included. If ONLY is not specified, matching rows are also deleted from any tables inheriting from the named table. If ONLY is specified before the table name, matching rows are deleted from the named table only. The name (optionally schema-qualified) of the table to delete rows from. When deleting a record from table a, I want to set the del flag at the current time and cascase the corresponding flag in table b ( but not delete records from database actually).The WITH clause allows you to specify one or more subqueries that can be referenced by name in the DELETE query. I have following database structure: table a (Ī_id bigint references a(id) on delete cascade, ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |