MCPcopy Create free account
hub / github.com/FlyingFeather/DEA-SQL / isValidSQL

Function isValidSQL

evaluation/ts_old/spider-master/evaluation.py:434–441  ·  view source on GitHub ↗
(sql, db)

Source from the content-addressed store, hash-verified

432
433
434def isValidSQL(sql, db):
435 conn = sqlite3.connect(db)
436 cursor = conn.cursor()
437 try:
438 cursor.execute(sql)
439 except:
440 return False
441 return True
442
443
444def print_scores(scores, etype):

Callers

nothing calls this directly

Calls 1

executeMethod · 0.45

Tested by

no test coverage detected