title: Retrieve a single row and column with nhibernate and convert it to a string
body: <p>I am creating a login function in MVC 4.0 with a Salt. The Salt is constant for each registered user, because the security doesn't have to be top-notch. Now to create the hash (to compare with the hash in the database) I need to retrieve the salt for the specific user from the DB and with the password which has been inserted create the hash. I use Nhibernate for database trafic. Yet, since I'm fairly new to Nhibernate, I don't know how to retrieve the salt as a string, I tried this: </p>
  
  <pre><code> var salt = session.QueryOver&lt;Translator&gt;()
       .Where(x =&gt; x.EmailAddress == emailAddress)
       .Select(x =&gt; x.Salt)
       .List()
       .ToString();
  </code></pre>
  
  <p>Where the x. is the mapping and <code>emailAddress</code> is a parameter in the function.
  The error mentions that the salt value (it actually shows the string) is not of type models.translator and cannot be used in this generic collection.</p>