comparison sqlpyPlus.py @ 94:5df8e2477ca3

command-line args working
author catherine@cordelia
date Sun, 25 May 2008 05:22:34 -0400
parents fa8c9eb8908f
children 84a26822e28c
comparison
equal deleted inserted replaced
93:f40bb62c625f 94:5df8e2477ca3
324 itms.append(sqlcommand[0]) 324 itms.append(sqlcommand[0])
325 return itms 325 return itms
326 326
327 pipeSeparator = Parser(pyparsing.SkipTo((pyparsing.Literal('|') ^ pyparsing.StringEnd()), include=True), retainSeparator=False) 327 pipeSeparator = Parser(pyparsing.SkipTo((pyparsing.Literal('|') ^ pyparsing.StringEnd()), include=True), retainSeparator=False)
328 bindScanner = Parser(pyparsing.Literal(':') + pyparsing.Word( pyparsing.alphanums + "_$#" )) 328 bindScanner = Parser(pyparsing.Literal(':') + pyparsing.Word( pyparsing.alphanums + "_$#" ))
329 commandSeparator = Parser(pyparsing.SkipTo((pyparsing.Literal(';') ^ pyparsing.StringEnd()), include=True))
330 329
331 def findBinds(target, existingBinds, givenBindVars = {}): 330 def findBinds(target, existingBinds, givenBindVars = {}):
332 result = givenBindVars 331 result = givenBindVars
333 for finding, startat, endat in bindScanner.scanner.scanString(target): 332 for finding, startat, endat in bindScanner.scanner.scanString(target):
334 varname = finding[1] 333 varname = finding[1]