title: razor and cshtml: how to db.Execute for select statement?
body: <p>I am doing a quick CSHTML page for the purpose of testing.</p>
  
  <p>I need to access database based on the id parameter on the URL:</p>
  
  <pre><code>var id = Request.QueryString["id"];
  var db = Database.Open("mydatabase_connection");
  var query = "select * from myrecord where id =  " + id;
  var row = db.QuerySingle(query);
  </code></pre>
  
  <p>//i am able to display the field (called name) of the selected record in the following way:</p>
  
  <pre><code>@row.name
  </code></pre>
  
  <p>Obviously, the above approach is subject to security attack. I am hoping to retrieve the record the following way:</p>
  
  <pre><code>var query = "select * from myrecord where id=@0";
  var row = db.Execute(query, id);
  </code></pre>
  
  <p>However, I get runtime error when retrieving the field value:</p>
  
  <pre><code>@row.name
  </code></pre>
  
  <p>What is the correct way of getting the "row" in the second approach?</p>
  
  <p>Thanks and regards.</p>