title: Concatenate or merge two json objects in SQL Server
body: <p>I have a table storing json in one column. I would like to update the json value by merging in another json. </p>
  
  <p>Something like:</p>
  
  <pre><code>insert into mytable 
  values ('{ "a": "b" ')
  
  update mytable 
  set jsonColumn = JSON_MERGE(jsonColumn, '{ "c": 2 }')
  </code></pre>
  
  <p>This should result in json like this:</p>
  
  <pre><code>{ "a": "b", "c": 2 }
  </code></pre>
  
  <p>Unfortunately there is no such <code>JSON_MERGE</code> function and <a href="https://docs.microsoft.com/en-us/sql/t-sql/functions/json-modify-transact-sql" rel="noreferrer">JSON_MODIFY</a> lets me modify only columns one by one. I have too many of them including nested properties.</p>
  
  <p>I'm basically searching for an equivalent to <a href="https://www.postgresql.org/docs/9.5/static/functions-json.html" rel="noreferrer">postgres || concatenation operator</a>.</p>