Support labels in query
As seen in Datafusion when attempting to parse the sqlite test suite:
External error: task 27341 panicked with message "called Result::unwrap() on an Err value: ParseError { kind: UnexpectedToken("label-1"), loc: Location { file: "../../datafusion-testing/data/sqlite/random/select/slt_good_21.slt", line: 47, upper: None } }"
The line referenced above is:
query I rowsort label-1
SELECT + 94 / - col2 + col1 + 9 FROM tab0 AS cor0
----
12
93
99
I believe the issue is the new retry code does not account for labels as documented @ https://sqlite.org/sqllogictest/doc/trunk/about.wiki
likely introduced by https://github.com/risinglightdb/sqllogictest-rs/pull/239?
@mikel879881 has been blocked from the repo
Yes, label was removed from parser in #239, because it's actually never supported in runner. It seems it's used in sqlite's test suite. You may use 0.24.0 for now. PR to add it back is welcome!
Sorry about that, I'll try to see if I can bring back this feature. Unfortunately, there isn't a test case that covers this functionality (label).
Oh, wait, I must clarify one thing. As mentioned in #238,
Also removed label from
QueryExpect::Resultsbecause it's never used.
The <label> was supported by Parser, but never functions as expected:
The
Thus, <label> is actually a missing feature compared with sqllogictest. Feel free to contribute.
If I find time this month I may work on this as it would be a nice feature to have.