title: Is there a way to return the primary key of inserted record with NHibernate?
body: <p>Well, the question kinda nails it down.
  I'm currently doing something like this:</p>
  
  <pre><code>using (var session = _sessionFactory.OpenSession())
  {
       using (var transaction = session.BeginTransaction())
       {
           Car newCar = new Car();
           newCar.name = "Jeep";
  
           session.Save(newCar);
           transaction.Commit();    
       }
  }
  </code></pre>