fixed issue 1391, sub for decimal
This commit is contained in:
@@ -1 +1 @@
|
|||||||
Version 2.4.4-stable+timestamp.2013.03.15.09.49.00
|
Version 2.4.4-stable+timestamp.2013.03.15.10.00.02
|
||||||
|
|||||||
@@ -8817,6 +8817,8 @@ class Expression(object):
|
|||||||
result_type = 'integer'
|
result_type = 'integer'
|
||||||
elif self.type in ['date','time','datetime','double','float']:
|
elif self.type in ['date','time','datetime','double','float']:
|
||||||
result_type = 'double'
|
result_type = 'double'
|
||||||
|
elif self.type.startswith('decimal('):
|
||||||
|
result_type = self.type
|
||||||
else:
|
else:
|
||||||
raise SyntaxError("subtraction operation not supported for type")
|
raise SyntaxError("subtraction operation not supported for type")
|
||||||
return Expression(db,db._adapter.SUB,self,other,result_type)
|
return Expression(db,db._adapter.SUB,self,other,result_type)
|
||||||
|
|||||||
Reference in New Issue
Block a user