as well as to target result set columns originally bound to a
table or selectable to an aliased, "corresponding" expression. The new
rewrite features completely consistent and accurate behavior.
+
+ - Added a field ("info") for storing arbitrary data on schema items
+ [ticket:573]
- orm
- eager loading with LIMIT/OFFSET applied no longer adds the primary
else:
m = self.metadata
return m and m.bind or None
-
-
bind = property(lambda s:s._get_bind())
+ def info(self):
+ try:
+ return self._info
+ except AttributeError:
+ self._info = {}
+ return self._info
+ info = property(info)
+
+
def _get_table_key(name, schema):
if schema is None:
return name
``Table`` object. Defaults to ``None`` which indicates all
columns should be reflected.
+ info
+ Defaults to {}: A space to store application specific data;
+ this must be a dictionary.
+
mustexist
Defaults to False: indicates that this Table must already
have been defined elsewhere in the application, else an
else:
self.fullname = self.name
self.owner = kwargs.pop('owner', None)
+ if kwargs.get('info'):
+ self._info = kwargs.pop('info')
autoload = kwargs.pop('autoload', False)
autoload_with = kwargs.pop('autoload_with', None)
specify indexes with explicit names or indexes that
contain multiple columns, use the ``Index`` construct instead.
+ info
+ Defaults to {}: A space to store application specific data;
+ this must be a dictionary.
+
unique
Defaults to False: indicates that this column contains a
unique constraint, or if `index` is True as well,
self.autoincrement = kwargs.pop('autoincrement', True)
self.constraints = util.Set()
self._foreign_keys = util.OrderedSet()
+ if kwargs.get('info'):
+ self._info = kwargs.pop('info')
if kwargs:
raise exceptions.ArgumentError("Unknown arguments passed to Column: " + repr(kwargs.keys()))