title: Database query not returning full string
body: <p>I'm saving a json string in the database which appears to be stored correctly in SQL Server, however when trying to fetch the data it only returns part of the json string. </p>
  
  <p>I'm using PDO and json_encode to save the data.
  The json string stored is approximately 1000 characters long, and the table field allows a length of 4096.</p>
  
  <p><strong>Fetching result:</strong></p>
  
  <pre><code>$sql = "SELECT TOP 1 * FROM MyTable WHERE id = :id ORDER BY id DESC;";
  
  $params = array(
      ":id" =&gt; $id
  );
  
  $sth = $this-&gt;db-&gt;prepare($sql);
  $sth-&gt;execute($params);
  $result = $sth-&gt;fetch(PDO::FETCH_ASSOC);
  </code></pre>
  
  <p><strong>Saving result:</strong></p>
  
  <pre><code>$json = json_encode($_POST);
  
  $sql = "INSERT INTO MyTable(data) VALUES (:data);";
  
  $params = array(
      ":data" =&gt; $data
  );
  
  $stmt = $this-&gt;db-&gt;prepare($sql);
  $stmt-&gt;execute($params);
  </code></pre>
  
  <p><strong>Example Json stored in SQL Server:</strong></p>
  
  <pre><code>{  
      "checkbox_1":"on",
      "checkbox_2":"on",
      "checkbox_3":"on",
      "text_1":"my text",
      "images":[  
          13685
      ],
      "date":"11-11-2015"
  }
  </code></pre>
  
  <p><strong>Example Json returned:</strong></p>
  
  <pre><code>{  
      "checkbox_1":"on",
      "checkbox_2":"on",
      "checkbox_3":"on",
      "text_1
  </code></pre>
  
  <p><strong>Update</strong></p>
  
  <p>It appears that the length of the string returned is always: <strong>255</strong></p>
  
  <p>Could this be an SQL Server configuration or perhaps PDO?</p>