title: How to generate random data in SQL server
body: <p>I want to create a stored procedure to insert random data in 'Video' table. I have already generated 30,000 record data for UserProfile table. </p>
  
  <p>Note: The username is FK element in Video table.</p>
  
  <pre><code>CREATE TABLE UserProfile 
  (
    Username VARCHAR(45)  NOT NULL  ,
    UserPassword VARCHAR(45)  NOT NULL  ,
    Email VARCHAR(45)  NOT NULL  ,
    FName VARCHAR(45)  NOT NULL  ,
    LName VARCHAR(45)  NOT NULL  ,
    Birthdate DATE   ,
    Genger VARCHAR(10)  NOT NULL  ,
    ZipCode INT    ,
    Image VARCHAR(50)      ,
  
    PRIMARY KEY(Username)
  );
  GO
  
  CREATE TABLE Video 
  (
    VideoId INT  NOT NULL DEFAULT 1000 ,
    Username VARCHAR(45)  NOT NULL  ,
    VideoName VARCHAR(160)  NOT NULL  ,
    UploadTime DATE    ,
    TotalViews INT    ,
    Thumbnail VARCHAR(100)      ,
  
    PRIMARY KEY(VideoId),
    FOREIGN KEY(Username)
      REFERENCES UserProfile(Username)
  );
  GO
  </code></pre>