Skip to content

Instantly share code, notes, and snippets.

@ekaraman89
Last active Jul 18, 2019
Embed
What would you like to do?
t-sql random string
String > SUBSTRING(CONVERT(varchar(40), NEWID()),0,9)
0 - 1 > convert(bit, round(1*rand(),0))
5 - 40 > Cast(RAND()*(40-5)+5 as int)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment