title: Update a view doesn't work
body: <p>I'm working on a view which is then updated by the user. This update basically changes the value of column. But right now it doesnt let me do that and produces this :</p>
  
  <pre><code>Update or insert of view or function '' failed because it contains a derived or constant field.
  </code></pre>
  
  <p>I know this is because I have a constant in the select statement but is there a way to get around it? Please help</p>
  
  <p>This is my code for the view</p>
  
  <pre><code>Create view Schema.View1
  as
  SELECT
  Convert(Varchar(20),l.jtpName) as JobType, Convert(Varchar(10),' &lt;All&gt; ')as SubCategory , Convert(varchar (3), Case when a.jtpName= l.jtpName and a.subName= ' &lt;All&gt; ' then 'Yes' else 'No' end) As AutoProcess from Schema.JobType l left join Schema.Table1 a on l.jtpName=a.jtpName
  UNION
  SELECT
  Convert(Varchar(20),a.jtpName) as JobType, Convert(Varchar(10),a.subName) as SubCategory, Convert(varchar (3),Case when b.jtpName= a.jtpName and b.subName= a.subName then 'Yes' else 'No' end) As AutoProcess from Schema.SubCategory a left join fds.Table1 b on a.subName=b.subName
  
  GO
  </code></pre>
  
  <p>Finally the update statement:</p>
  
  <pre><code>UPDATE Schema.View1 SET AUTOPROCESS = Case WHEN AUTOPROCESS = 'Yes' Then 'No' END Where JOBTYPE = 'Transport' and SUBCATEGORY= 'Cargo'
  </code></pre>
  
  <p>Thank You</p>