--生成数字+英文字母大小写彩虹字符集(6位),共有62^6种可能with cte as ( select number as ascii_no,CHAR(number) as ascii_char from master..spt_values where number between 48 and 57--0-9 ascii or number between 97 and 122--a-z ascii or number between 65 and 90--A-Z ascii) --生成0-9,a(A)-z(Z)字符集合select 彩虹字符,HASHBYTES('md5',彩虹字符) as MD5加密from ( select top 1000000 a.ascii_char+b.ascii_char+c.ascii_char+d.ascii_char+e.ascii_char+f.ascii_char as 彩虹字符--100万行 from cte as a cross join cte as b cross join cte as c cross join cte as d cross join cte as e cross join cte as f ) as c_table