Subject | Re: [Firebird-Architect] for discussion Transient Data Set |
---|---|
Author | Dmitry Yemanov |
Post date | 2005-01-15T11:22:02Z |
"Ann W. Harrison" <aharrison@...> wrote:
expected/correct after a multiple rows DML statement or not.
implicitly defined. So I don't think this is a problem. But I would like to
avoid including YIELDING into a select expression. Recently I've extended
the parser to make all subselects true select expressions. Generally, now
the only difference between nod_select and nod_select_expr is FOR UPDATE and
WITH LOCK clauses. I'm sure we don't need YIELDING in subqueries.
Dmitry
>Perhaps. My main worry is whether a YIELDING result can be considered
> YIELDING works with singleton and mass modification verbs (insert/
> update/ delete), but requires a second round trip. Returning works only
> with singleton modifications, but works in a singe round trip. I'd
> argue that both are valuable in different contexts.
expected/correct after a multiple rows DML statement or not.
> I think that RETURNING is probably better for connectivity librariesAgreed.
> that want to provide a list of values from a singleton modification.
> You raise good points. If YIELDING is part of a query expression, thenThey're always based on a partial/simplified query expression which is
> a statement like this solves the problem of getting values from a mass
> insert...
>
> INSERT INTO <whatever> SELECT <list> FROM <data source> YIELDING ...
>
> A question is whether the ability to return a transient data set from an
> update or delete has value, since those operations are not based on a
> full query expression.
implicitly defined. So I don't think this is a problem. But I would like to
avoid including YIELDING into a select expression. Recently I've extended
the parser to make all subselects true select expressions. Generally, now
the only difference between nod_select and nod_select_expr is FOR UPDATE and
WITH LOCK clauses. I'm sure we don't need YIELDING in subqueries.
Dmitry