XiaoMi / soar

SQL Optimizer And Rewriter
Apache License 2.0
8.67k stars 1.32k forks source link

SQL file with BOM will raise syntax error #110

Closed martianzhang closed 5 years ago

martianzhang commented 5 years ago

Please answer these questions before submitting your issue. Thanks!

  1. What did you do?
vi 1.sql
# set bomb
:set bomb
# edit file
select col from tb c = 1;
# save and quit

soar -query 1.sql -only-syntax-check
  1. What did you expect to see?

ok

  1. What did you see instead?

syntax error at position 2 near '�'

  1. What version of are you using (soar -version)?

0.9.0