summaryrefslogtreecommitdiff
path: root/lib/sqlalchemy/databases/maxdb.py
diff options
context:
space:
mode:
authorMike Bayer <mike_mp@zzzcomputing.com>2008-08-24 19:52:54 +0000
committerMike Bayer <mike_mp@zzzcomputing.com>2008-08-24 19:52:54 +0000
commit6f60e768837f6b91a75dc2d62dbd215471bf09f7 (patch)
tree3db99506d1901e0e809821816d899e8a81a8d370 /lib/sqlalchemy/databases/maxdb.py
parente01e972ac305d634cac3d63de6c5fa6688cd56c5 (diff)
downloadsqlalchemy-6f60e768837f6b91a75dc2d62dbd215471bf09f7.tar.gz
- The 'length' argument to all Numeric types has been renamed
to 'scale'. 'length' is deprecated and is still accepted with a warning. [ticket:827] - The 'length' argument to MSInteger, MSBigInteger, MSTinyInteger, MSSmallInteger and MSYear has been renamed to 'display_width'. [ticket:827] - mysql._Numeric now consumes 'unsigned' and 'zerofill' from the given kw, so that the same kw can be passed along to Numeric and allow the 'length' deprecation logic to still take effect - added testlib.engines.all_dialects() to return a dialect for every db module - informix added to sqlalchemy.databases.__all__. Since other "experimental" dbs like access and sybase are there, informix should be as well.
Diffstat (limited to 'lib/sqlalchemy/databases/maxdb.py')
-rw-r--r--lib/sqlalchemy/databases/maxdb.py8
1 files changed, 4 insertions, 4 deletions
diff --git a/lib/sqlalchemy/databases/maxdb.py b/lib/sqlalchemy/databases/maxdb.py
index c9ea2b579..34629b298 100644
--- a/lib/sqlalchemy/databases/maxdb.py
+++ b/lib/sqlalchemy/databases/maxdb.py
@@ -169,17 +169,17 @@ class MaxSmallInteger(MaxInteger):
class MaxNumeric(sqltypes.Numeric):
"""The FIXED (also NUMERIC, DECIMAL) data type."""
- def __init__(self, precision=None, length=None, **kw):
+ def __init__(self, precision=None, scale=None, **kw):
kw.setdefault('asdecimal', True)
- super(MaxNumeric, self).__init__(length=length, precision=precision,
+ super(MaxNumeric, self).__init__(scale=scale, precision=precision,
**kw)
def bind_processor(self, dialect):
return None
def get_col_spec(self):
- if self.length and self.precision:
- return 'FIXED(%s, %s)' % (self.precision, self.length)
+ if self.scale and self.precision:
+ return 'FIXED(%s, %s)' % (self.precision, self.scale)
elif self.precision:
return 'FIXED(%s)' % self.precision
else: