* Creates a DELETE query. * Use `where()` to specify which rows to delete. * * @example * ```ts * await em.createQueryBuilder(User) * .delete() * .where({ id: 1 }) * .execute(); * * // Or pass the condition directly * await em.createQueryBuilder(User) * .d
(cond?: QBFilterQuery<Entity, RootAlias, Context, RawAliases>)
| 951 | * ``` |
| 952 | */ |
| 953 | delete(cond?: QBFilterQuery<Entity, RootAlias, Context, RawAliases>): DeleteQueryBuilder<Entity, RootAlias, Context> { |
| 954 | return this.init(QueryType.DELETE, undefined, cond) as unknown as DeleteQueryBuilder<Entity, RootAlias, Context>; |
| 955 | } |
| 956 | |
| 957 | /** |
| 958 | * Creates a TRUNCATE query to remove all rows from the table. |