Skip to content

Flowing large hash values to Postgres BigInt #1499

Discussion options

You must be logged in to vote
    class Hero(SQLModel, table=True):
        id: Optional[int] = Field(default=None, primary_key=True)
        normhash: Optional[int] = Field(default=None, index=True, sa_column=Column(BigInteger())) 

UPD YuriiMotov: to avoid conflicts it's now better to use sa_type:

    class Hero(SQLModel, table=True):
        id: Optional[int] = Field(default=None, primary_key=True)
        normhash: Optional[int] = Field(default=None, index=True, sa_type=BigInteger) 

Replies: 10 comments

Comment options

You must be logged in to vote
0 replies
Answer selected by YuriiMotov
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
8 participants
Converted from issue

This discussion was converted from issue #191 on August 12, 2025 17:28.