Mercurial > repos > jjohnson > query_tabular
changeset 1:24f0911f75ee
Uploaded
author | jjohnson |
---|---|
date | Sat, 03 Oct 2015 09:23:08 -0400 |
parents | 763c4f968dc6 |
children | ffa5e34a55c1 |
files | query_tabular.py query_tabular.xml |
diffstat | 2 files changed, 6 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/query_tabular.py Thu Oct 01 09:50:16 2015 -0400 +++ b/query_tabular.py Sat Oct 03 09:23:08 2015 -0400 @@ -103,6 +103,7 @@ c.close() except Exception, e: print >> sys.stderr, 'Failed: %s' % (e) + exit(1) def __main__(): #Parse Command Line @@ -175,6 +176,7 @@ outputFile.write("%s\n" % '\t'.join([str(val) for val in row])) except Exception, exc: print >> sys.stderr, "Error: %s" % exc + exit(1) if __name__ == "__main__": __main__()
--- a/query_tabular.xml Thu Oct 01 09:50:16 2015 -0400 +++ b/query_tabular.xml Sat Oct 03 09:23:08 2015 -0400 @@ -28,7 +28,8 @@ -t ${tbl.table}=${tname}${$col_names} #end for #if $query: - -q "$query" + -q "$query" + $no_header -o $output #end if ]]></command> @@ -53,6 +54,8 @@ <sanitizer sanitize="False"/> <validator type="regex" message="">^(?i)\s*select\s+.*\s+from\s+.*$</validator> </param> + <param name="no_header" type="boolean" truevalue="-n" falsevalue="" checked="False" label="Omit column headers"/> + <param name="save_db" type="boolean" truevalue="yes" falsevalue="no" checked="false" label="Save the sqlite database"/> </inputs> <outputs>