Skip to content

SQL未格式化导致提交失败 #609

@jia9iZhang

Description

@jia9iZhang

Describe the bug
Leetcode-183的SQL答案在本地提交控制台报错,在LeetCode官网提交显示成功.
> 2022/12/30 14:19:42 运行失败: Line 1: error: class, interface, enum, or record expected select Customers.Name as 'Customers' ^ Line 1: error: unclosed character literal select Customers.Name as 'Customers' ^ Line 1: error: illegal line end in character literal select Customers.Name as 'Customers' ^ 3 errors

To Reproduce
Steps to reproduce the behavior:

  1. 打开SQL提
  2. 输入SQL回答
    select Customers.Name as 'Customers' from Customers where Customers.Id not in ( select CustomerId from Orders)
  3. 点击运行按钮
  4. 控制台提示报错:
    > 2022/12/30 14:19:42 运行失败: Line 1: error: class, interface, enum, or record expected select Customers.Name as 'Customers' ^ Line 1: error: unclosed character literal select Customers.Name as 'Customers' ^ Line 1: error: illegal line end in character literal select Customers.Name as 'Customers' ^ 3 errors

image

Software versions(Help -> About)

  • Product: IDEA 2022.2.4 UE
  • Runtime version:17.0.5+7-b469.71 aarch64
  • VM:OpenJDK 64-Bit Server VM,JetBrains s.r.o.
  • OS: macOS 12.1

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions