Yesterday I built most of a Postgres extension, using the excellent pgrx[1] project, that build on ulid to add prefixes. With it you get something like this
plid=# SELECT gen_plid('u');
gen_plid
---------------------------
u_06DHRQH6SJT7N2WEQK4910R
(1 row)
The aim is for it to be the same size as a UUID in storage, but I haven't quite gotten there yet.I haven't pushed it to GitHub yet, but it's fairly done at this point.