def __init__(self, engine, statement, parameters=None, typemap=None, **kwargs):
"""constructs a new ANSICompiler object.
engine - SQLEngine to compile against
statement - ClauseElement to be compiled
parameters - optional dictionary indicating a set of bind parameters
specified with this Compiled object. These parameters are the "default"
key/value pairs when the Compiled is executed, and also may affect the
actual compilation, as in the case of an INSERT where the actual columns
inserted will correspond to the keys present in the parameters."""
sql.Compiled.__init__(self, engine, statement, parameters)
self.binds = {}
self.froms = {}
self.wheres = {}
self.strings = {}
self.select_stack = []
self.typemap = typemap or {}
self.isinsert = False
评论列表
文章目录