title: C# Prepared Statements - @ sign (at / strudel sign) queries
body: <p>I Have a problem with a prepared statement in C#:</p>
  
  <pre><code>OdbcCommand cmd = sql.CreateCommand();
  cmd.CommandText = "SELECT UNIQUE_ID FROM userdetails WHERE USER_ID = ?";
  cmd.Parameters.Add("@USER_ID", OdbcType.VarChar, 250).Value = email;
  </code></pre>
  
  <p>(of course email contains a valid email address, with @ sign).</p>
  
  <p>This code returns a random error - </p>
  
  <blockquote>
    <p>"The connection has been disabled"
    {"ERROR [01000] [Microsoft][ODBC SQL
    Server Driver][TCP/IP
    Sockets]ConnectionWrite (send()).
    ERROR [08S01] [Microsoft][ODBC SQL
    Server Driver][TCP/IP Sockets]General
    network error. Check your network
    documentation."}</p>
  </blockquote>
  
  <p>However if I run my code without a prepared statement, meaning:</p>
  
  <pre><code>cmd.CommandText = "SELECT UNIQUE_ID FROM userdetails WHERE USER_ID = '"+email+"'";
  </code></pre>
  
  <p>Everything works perfectly.</p>
  
  <p>Maybe it's related to the fact that I have a @ sign in the parametrized value? I tend to think I'm not the first one trying to create a prepared statement with an email address...</p>
  
  <p>I have no idea what's wrong! Other prepared statements work normally...</p>
  
  <p>Can you please help? :)
  Thanks,
  Nili</p>