I’m trying to create a String based sequence in SQLAlchemy ORM. I know that the best practice is to use a Integer based column to manage ID of a table but in my case, due to some requirements of the project I need to store the data as a String based PK for ID’s.
I know that in some databases it is possible to store data using a string based sequence like:
But in SQL alchemy I can’t achieve this by using Sequence method. It only generates Integer based sequences and I can’t find an options to “append” a prefix in the sequence generation.
There is a easy solution to achieve this?