title: Insert JSON into SQL Server 2016 using C# and OPENJSON
body: <p>I'm trying to use the <code>OPENJSON</code> to insert data into my database writing code in C#.</p>
  
  <p>I've managed to insert the desired JSON object, but I can do that only once - which is not the goal. I want to use this way to insert more than one JSON objects into the database and keep them there.</p>
  
  <p>The SQL string I'm using is this:</p>
  
  <pre><code>@"SELECT BulkColumn INTO unparsed2 FROM OPENROWSET(BULK 'C:\\JSON\\data.json', SINGLE_CLOB) as j";
  </code></pre>
  
  <p>For testing purposes, the code runs only once. If I execute it again, I get the following message: </p>
  
  <blockquote>
    <p>There is already an object named 'unparsed2' in the database.</p>
  </blockquote>
  
  <p>I've also tried passing the object as an argument inside the T-SQL script, which results in an error (but receive an error near the first key value - probably due to the semicolon in the json object).</p>
  
  <pre><code>@"declare @json nvarchar (max) = " +json_object+ " "INSERT INTO unparsed SELECT * FROM OPENJSON(@json) AS json)";
  </code></pre>
  
  <blockquote>
    <p>Incorrect syntax near 'device'.</p>
  </blockquote>
  
  <p>My JSON object:</p>
  
  <pre><code>{
    "device":"1234",
    "status":1,
    "level":100,
    "dni":true,
    "value":50
  }
  </code></pre>