소스 검색

[editor] SELECT 1 will fail with the auto LIMIT with Impala

sreenaths 5 년 전
부모
커밋
2197384ca3
1개의 변경된 파일1개의 추가작업 그리고 0개의 파일을 삭제
  1. 1 0
      desktop/core/src/desktop/js/apps/notebook2/execution/sqlExecutable.ts

+ 1 - 0
desktop/core/src/desktop/js/apps/notebook2/execution/sqlExecutable.ts

@@ -56,6 +56,7 @@ export default class SqlExecutable extends Executable {
       this.executor.defaultLimit &&
       !isNaN(this.executor.defaultLimit()) &&
       this.executor.defaultLimit() > 0 &&
+      /\sfrom\s/i.test(statement) &&
       !/\slimit\s[0-9]/i.test(statement)
     ) {
       const endMatch = statement.match(SELECT_END_REGEX);