7

ULID (26 characters in Crockford's base32) conversion for MySQL function

 1 year ago
source link: https://gist.github.com/kenji4569/47ce8bbd6bef7b85ba1f97e018f34cf3
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.

vredcloud commented on May 12

@kenji4569

This is super useful. However, when I use any of the ULID libraries i get a different kind of ULID that what this produces.

For E.g:- For the same date time.

01G2V2W6DTAY06GA54RXT1TRN6 --> using https://github.com/f4b6a3/ulid-creator
01G2V2RC7S64R0000000000000 --> using this function.

I don't see trailing 0's in any of the other ULID generators.


About Joyk


Aggregate valuable and interesting links.
Joyk means Joy of geeK