On 08/05/2011 10:46 PM, Mark Erbaugh wrote:
This is more of a Python issue than a SA issue, but I had trouble getting this to
work. I did, but the code seems a little awkard to mesigh. In addition to
the requirements already, I also wanted toe default value to be a class level
'constant'.
In my application, some tables have several fields that need to have the same
type and default value, i.e.:
field1 = Column(Integer, default=2)
field2 = Column(Integer, default=2)
...
Is there some way to refactor the Common(Integer, default=2), short of creating
a custom column type? I could
On Aug 5, 2011, at 1:36 PM, Mark Erbaugh wrote:
In my application, some tables have several fields that need to have the same
type and default value, i.e.:
field1 = Column(Integer, default=2)
field2 = Column(Integer, default=2)
...
Is there some way to refactor the Common(Integer,
On Aug 5, 2011, at 3:51 PM, Michael Bayer wrote:
On Aug 5, 2011, at 1:36 PM, Mark Erbaugh wrote:
In my application, some tables have several fields that need to have the
same type and default value, i.e.:
field1 = Column(Integer, default=2)
field2 = Column(Integer, default=2)
...