diff options
author | D'Arcy J.M. Cain | 2003-02-26 13:16:50 +0000 |
---|---|---|
committer | D'Arcy J.M. Cain | 2003-02-26 13:16:50 +0000 |
commit | e9320841f5a98a18faeb2ed29c0921b66024c37e (patch) | |
tree | 0976f7094c348c55f7b1d40ccb630cc7a0fc1925 | |
parent | bb9c38c22a92fff88587db7690cab168de348a74 (diff) |
The quote function should return a string suitable for dropping into a
query string. This fixes a bug where bool types sometimes returned with
a string that could not be dropped into a query.
-rw-r--r-- | src/interfaces/python/pg.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/interfaces/python/pg.py b/src/interfaces/python/pg.py index 0e40a6e5a4..5fd36eed34 100644 --- a/src/interfaces/python/pg.py +++ b/src/interfaces/python/pg.py @@ -29,7 +29,7 @@ def _quote(d, t): if t == 'bool': # Can't run upper() on these - if d in (0, 1): return ('f', 't')[d] + if d in (0, 1): return ("'f'", "'t'")[d] if string.upper(d) in ['T', 'TRUE', 'Y', 'YES', '1', 'ON']: return "'t'" |