each-tuple ( query/tuple quot: ( tuple -- ) -- ) (original) (raw)
Inputs
query/tuple | a tuple |
---|---|
quot | a quotation with stack effect ( tuple -- ) |
Outputs
None
Word description
An SQL query is constructed from the slots of the exemplar tuple that are not f. The quot is applied to each tuple from the database that matches the query constructed from the exemplar tuple.
See also
select-tuple, select-tuples, count-tuples
Definition
USING: accessors db.tuples.private kernel ;
: each-tuple ( query/tuple quot: ( tuple -- ) -- )
[ >query [ tuple>> ] [ query>statement ] bi ] dip
do-each-tuple ; inline