title: Calling stored procedures, passing NULL values, dealing with boolean values
body: <p>When calling a stored procedure I am concatenating values together, my question is how do you call a stored procedure but send a 'NULL' value in one of the params?</p>
  
  <p>Lets say that AID = null, but if I pass that to my query I get an error?!</p>
  
  <pre><code>QueryConn.Execute("Search_Res " &amp; Count &amp; "," &amp; AccessList("InvoiceLevel") &amp; "," &amp; AID)
  </code></pre>
  
  <p>Ok, so my next question is going to be how do I pass in a boolean variable?</p>
  
  <p>Within my stored procedure the var @SearchChildren is either true or false, but how do I define this or should I go with an int and make things simple for myself and just use 0 or 1?</p>
  
  <p>MS SQL Server 2005.</p>