By far the easiest is to use id and not worry about it.

If it's that important, I would suggest leaving id as-is and either adding a 
new field or using a virtual field that does a simple hash. I've seen hashes 
as simple as multiplying by a small prime number like 1007.

So:
Field('bigid', 'integer')
db.mytable.bigid.default = lambda r: r.id * 1007

And then always use bigid.

Reply via email to