Skip to content

Commit

Permalink
Add field number to the error message.
Browse files Browse the repository at this point in the history
Co-authored-by: Benjamin Kietzman <bengilgit@gmail.com>
  • Loading branch information
EpsilonPrime and bkietz authored Sep 26, 2024
1 parent 181332d commit 737dadf
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/substrait/textplan/PlanPrinterVisitor.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -207,8 +207,9 @@ std::string PlanPrinterVisitor::lookupFieldReferenceForEmit(
auto actualParentQueryLocation = getParentQueryLocation(actualScope);
if (actualParentQueryLocation == Location::kUnknownLocation) {
errorListener_->addError(
"Requested steps out of " + std::to_string(stepsOut) +
" but not within subquery depth that high.");
"Requested field#" + std::to_string(fieldReference) + " at " +
std::to_string(stepsOut) + " steps out but subquery depth is only " +
std::to_string(stepsLeft));
return "field#" + std::to_string(fieldReference);
}
actualScope = symbolTable_->lookupSymbolByLocationAndType(
Expand Down

0 comments on commit 737dadf

Please sign in to comment.