MCPcopy Create free account
hub / github.com/ActiveState/code / pager

Function pager

recipes/Python/578490_sql_the_SQLPlus_killer/recipe-578490.py:241–248  ·  view source on GitHub ↗
(filename,reclen,totrec)

Source from the content-addressed store, hash-verified

239 pager(filename,reclen,len(rs))
240
241def pager(filename,reclen,totrec):
242 if totrec > int(LINES) or reclen > int(COLUMNS):
243 pydoc.pager(open(filename).read())
244 else:
245 print open(filename).read()
246 if _FD:
247 _FD.write(open(filename).read())
248 os.unlink(filename)
249
250def oracle_main(par):
251 if not par.get('cmd'):

Callers 1

show_qryFunction · 0.70

Calls 4

unlinkMethod · 0.80
openFunction · 0.50
readMethod · 0.45
writeMethod · 0.45

Tested by

no test coverage detected