So i'm trying to insert an array of jsonb values into my database but I
can't seem to format it right, here's my code:
updated_old_passwords = []
updated_old_passwords.append({"index": 1, "password": hashed_password})
user.old_passwords = updated_old_passwords
Hi,
I've been using an array of enums with postgres and SQLAlchemy successfully
over the past year like so:
class MyModel(BaseModel):
enum_field = Column(postgresql.ARRAY(EnumField(MyEnum, native_enum=False)))
The EnumField is from the sqlalchemy_enum34
Hi Mike,
Thanks for SQLAlchemy. As a relatively new user I wanted case-insensitive
querying but the only reference for this that I could find in the
documentation was custom comparators. I spent a lot of time trying to get
these to work when, it turns out, ilike suited my needs perfectly.
Mike:
Actually, the classproperty I was using was a custom decorator that I made.
It doesn't work quite the same as the example you provided, so I will have
to compare the two approaches.
Here is the one I had:
class classproperty(property):
"""
This defines a decorator that can be used