How do I get this use case working? I want the ticker attribute to
retrieve the values from the value defined in the Enum column.
class Security(Base):
cusip = Column(String)
sedol = Column(String)
isin = Column(String)
symbol = Column(String)
_ticker =
Never mind, the hybrid_property was needed not declared_attr. My bad.
On Thursday, 29 October 2015 11:46:32 UTC-7, drMental wrote:
>
> How do I get this use case working? I want the ticker attribute to
> retrieve the values from the value defined in the Enum column.
>
>
> class Security(Base):
Hi all,
I used alembic to generate (auto) a migration which added a table to my
postgresql DB which had a foreign key constraint matching two columns in
the new table to two columns in an existing one. The two columns in the
existing table where a joint primary key (hence unique). The
I've spent an hour trying to reproduce this bug and can't. I'm hoping
someone can suggest what might be going on so I can make this reproducable
for a bug report
I have 2 classes:
class Foo(Base):
__tablename__ = 'foo'
id = Column(Integer, primary_key=True)
bar_id
On 10/29/15 6:50 PM, Jonathan Vanasco wrote:
> I've spent an hour trying to reproduce this bug and can't. I'm hoping
> someone can suggest what might be going on so I can make this
> reproducable for a bug report
>
> I have 2 classes:
>
> class Foo(Base):
> __tablename__ = 'foo'
On 10/29/15 4:26 PM, Gastón Avila wrote:
> Hi all,
>
> I used alembic to generate (auto) a migration which added a table to my
> postgresql DB which had a foreign key constraint matching two columns in
> the new table to two columns in an existing one. The two columns in the
> existing table
On Thursday, October 29, 2015 at 7:33:47 PM UTC-4, Michael Bayer wrote:
>
> i dont have an immediate answer, though i wonder why you aren't using
> ~Bar.is_x.is(True) for that "IS NOT"...
>
Old habits and styleguide. The `~` ended up being missed on too many
glances and code-reviews.
>
Thanks for pointing me in the right direction @zzzeek. For me it worked
really well to just add these lines to *alembic.autogenerate.render*:
@renderers.dispatch_for(ops.ExecuteSQLOp)
def _execute_sql(autogen_context, op):
assert isinstance(op.sqltext, str)
return