memory (sqla_mapping): Add index on PrivateInd* tables:
`PriaveInd*` may be queried without `key`, in which case an index was missing.
This commit is contained in:
parent
b7b5797262
commit
399802455f
1 changed files with 44 additions and 0 deletions
|
|
@ -547,6 +547,9 @@ class PrivateGen(Base):
|
|||
|
||||
class PrivateInd(Base):
|
||||
__tablename__ = "private_ind"
|
||||
__table_args__ = (
|
||||
Index("private_ind__namespace_profile_id", "namespace", "profile_id"),
|
||||
)
|
||||
|
||||
namespace = Column(Text, primary_key=True)
|
||||
key = Column(Text, primary_key=True)
|
||||
|
|
@ -566,6 +569,9 @@ class PrivateGenBin(Base):
|
|||
|
||||
class PrivateIndBin(Base):
|
||||
__tablename__ = "private_ind_bin"
|
||||
__table_args__ = (
|
||||
Index("private_ind_bin__namespace_profile_id", "namespace", "profile_id"),
|
||||
)
|
||||
|
||||
namespace = Column(Text, primary_key=True)
|
||||
key = Column(Text, primary_key=True)
|
||||
|
|
|
|||
Loading…
Reference in a new issue