-
Notifications
You must be signed in to change notification settings - Fork 55
Open
Description
In Chapter 3, there are two examples of code, followed by this text:
This query takes two arguments: $ is the database itself (implicit, if no :in clause is specified) and ?name which presumably will be the name of some actor.
The above query is executed like (q query db "Sylvester Stallone"), where query is the query we just saw, and db is a database value. You can have any number of inputs to a query.
In the above query, the input pattern variable ?name is bound to a scalar - a string in this case. There are four different kinds of input: scalars, tuples, collections and relations.
I find the wording here is confusing, requiring careful re-reading to parse between "The above query" and "In the above query" which refer to, it appears to me (please correct me if I am mistaken!) the two different queries.
I suggest either:
- labeling the examples "query A" and "query B" to be extra clear
- refer to examples specifically as "non-reusable query" and "parameterized query", respectively
- moving the descriptive text to be adjacent to their respective examples (and not interleaved, if this is the case)
Metadata
Metadata
Assignees
Labels
No labels