diff options
author | Martin Pihlak | 2012-08-16 09:47:10 +0000 |
---|---|---|
committer | Martin Pihlak | 2012-08-16 09:47:10 +0000 |
commit | e1c22bd6d598dcf86a2a930bd19904e330b085b6 (patch) | |
tree | c32d23315afe3d3c15b24f62dcc212df03e34671 /python/skytools/dbservice.py | |
parent | 37e91db8fb3a1fcd9a7a54934a2e882a5a953d0c (diff) | |
parent | f8d90af0912db0a2ed29aa5e8fb912be3ab309a6 (diff) |
Merge branch 'master' of internal-git:/git/dba/skytools-3
Diffstat (limited to 'python/skytools/dbservice.py')
-rwxr-xr-x | python/skytools/dbservice.py | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/python/skytools/dbservice.py b/python/skytools/dbservice.py index e49576ce..d1ddb666 100755 --- a/python/skytools/dbservice.py +++ b/python/skytools/dbservice.py @@ -92,7 +92,11 @@ def get_record_list(array): """ if array is None: return [] - return map(get_record, skytools.parse_pgarray(array)) + + if isinstance(array, list): + return map(get_record, array) + else: + return map(get_record, skytools.parse_pgarray(array)) def get_record_lists(tbl, field): """ Create dictionary of lists from given list using field as grouping criteria |