source: people/peter.buschman/backup_monitoring/dal/builtins/one_column.py@ 1114

Last change on this file since 1114 was 976, checked in by peter, on Dec 6, 2011 at 10:19:33 AM

Raw checkin of current NetBackup / TSM parsing code.

File size: 202 bytes
Line 
1##
2## one_column - return the first column of all results from an SQL query as an array
3#
4def one_column(curs, query):
5
6 curs.execute(query)
7
8 return [row[0] for row in curs.fetchall()]
9
Note: See TracBrowser for help on using the repository browser.