title: Sql Server - Insufficient result space to convert uniqueidentifier value to char
body: <p>I am getting below error when I run sql query while copying data from one table to another,</p>
  
  <blockquote>
    <p>Msg 8170, Level 16, State 2, Line 2
    Insufficient result space to convert
    uniqueidentifier value to char.</p>
  </blockquote>
  
  <p>My sql query is,</p>
  
  <pre><code>INSERT INTO dbo.cust_info (
  uid,
  first_name,
  last_name
  )
  SELECT
  NEWID(),
  first_name,
  last_name
  FROM dbo.tmp_cust_info
  </code></pre>
  
  <p>My create table scripts are,</p>
  
  <pre><code>CREATE TABLE [dbo].[cust_info](
      [uid] [varchar](32) NOT NULL,
      [first_name] [varchar](100) NULL,
      [last_name] [varchar](100) NULL)
  
  CREATE TABLE [dbo].[tmp_cust_info](
      [first_name] [varchar](100) NULL,
      [last_name] [varchar](100) NULL)
  </code></pre>
  
  <p>I am sure there is some problem with <strong>NEWID()</strong>, if i take out and replace it with some string it is working.</p>
  
  <p>I appreciate any help. Thanks in advance.</p>