1
0
Fork 0
mirror of https://github.com/LemmyNet/lemmy.git synced 2025-01-25 15:09:19 +00:00
lemmy/migrations/2022-04-11-210137_fix_unique_changeme/down.sql

7 lines
277 B
MySQL
Raw Normal View History

create or replace function generate_unique_changeme()
returns text language sql
as $$
select 'http://changeme_' || string_agg (substr('abcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyz0123456789', ceil (random() * 62)::integer, 1), '')
from generate_series(1, 20)
$$;