probcomp/bayeslite

BQL does not include IN expression

Open

#263 geöffnet am 18. Okt. 2015

Auf GitHub ansehen
 (5 Kommentare) (0 Reaktionen) (1 zugewiesene Person)Python (63 Forks)batch import
help wantedk min/hr

Repository-Metriken

Stars
 (915 Stars)
PR-Merge-Metriken
 (Keine gemergten PRs in 30 T)

Beschreibung

This command is not supported

bdb.execute('select * from satellites where Purpose IN ("Communications", "Reconnaissance")')
  File "build/bdist.macosx-10.9-x86_64/egg/bayeslite/bayesdb.py", line 149, in execute
  File "build/bdist.macosx-10.9-x86_64/egg/bayeslite/parse.py", line 104, in <genexpr>
  File "build/bdist.macosx-10.9-x86_64/egg/bayeslite/parse.py", line 91, in <genexpr>
  File "build/bdist.macosx-10.9-x86_64/egg/bayeslite/parse.py", line 77, in parse_bql_phrases
bayeslite.parse.BQLParseError: Parse error: syntax error near Communications

But with sql_execute it is:

bdb.sql_execute('select * from satellites where Purpose IN ("Communications", "Reconnaissance")

In the longer-tmer, is the intention for SQL to co-exist alongside BQL with a separate entry point? Is there a plan for extending BQL to implement a superset of SQL syntax?

In the short-term, are we intending for users to use sql_execute() as well as execute()? Is there a list of SQL features that are not currently supported by BQL somewhere?

Contributor Guide