Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commitf9ae973

Browse files
committed
Correct indenting in _quote() function.
Fix submitted by Andrew Kuchling <akuchlin@mems-exchange.org>
1 parentdcbbdb1 commitf9ae973

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

‎src/interfaces/python/pgdb.py

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -263,16 +263,16 @@ def _quote(x):
263263
x="'"+string.replace(
264264
string.replace(str(x),'\\','\\\\'),"'","''")+"'"
265265

266-
elif type(x)in (types.IntType,types.LongType,types.FloatType):
266+
eliftype(x)in (types.IntType,types.LongType,types.FloatType):
267267
pass
268-
elifxisNone:
268+
elifxisNone:
269269
x='NULL'
270-
elifhasattr(x,'__pg_repr__'):
270+
elifhasattr(x,'__pg_repr__'):
271271
x=x.__pg_repr__()
272-
else:
272+
else:
273273
raiseInterfaceError,'do not know how to handle type %s'%type(x)
274274

275-
returnx
275+
returnx
276276

277277
def_quoteparams(s,params):
278278
ifhasattr(params,'has_key'):
@@ -401,7 +401,7 @@ def __cmp__(self, other):
401401
INTEGER=pgdbType('int2','int4','serial')
402402
LONG=pgdbType('int8')
403403
FLOAT=pgdbType('float4','float8','numeric')
404-
BOOL=pgdbType('bool')
404+
BOOL=pgdbType('bool')
405405
MONEY=pgdbType('money')
406406

407407
# this may be problematic as type are quite different ... I hope it won't hurt

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp