Commit Graph

3 Commits (5ac5fe2f9c39c77a6834b2ed80df840d8e7f7b39)

Author SHA1 Message Date
Jonathan A. Sternberg 0f304690c5 Enable casting values from a subquery
This also fixes the cursor system to abandon iterators that will not
produce meaningful results since the variables are all unknown types.

This creates a weird behavior that existed in previous releases and we
are keeping here for backwards compatibility. If a subquery referenced a
field that didn't exist in the subquery, it will return nothing. But, if
there are two subqueries and one of them has the field exist and the
other doesn't, the second will return all null values.
2018-03-30 16:58:37 -05:00
Jonathan A. Sternberg 2fb67dd4be Fix subquery conditions with the cursor refactor 2018-03-28 13:13:46 -05:00
Jonathan A. Sternberg d4db76508f Add some unit tests to subqueries
This is not complete, but it is a starting point for more thorough tests
of subqueries.

This also reorders the use of `cmp.Diff` so the `want` is first and
`got` is second. This way, the `want` shows up as a minus sign in the
diff rather than, confusingly, as a plus sign.
2018-03-27 14:56:27 -05:00