public ResponsibleLegalPerson(Organisation organisation) { if (organisation == null) { throw new ArgumentNullException("organisation"); } this.organisation = organisation; }
public void TheTest() { using (ISession session = OpenSession()) { var organisation = new Organisation(); session.SaveOrUpdate(organisation); session.Flush(); organisation.TradingNames.Add(new TradingName(organisation) {Name = "Trading Name", StartDate = DateTime.Today}); session.SaveOrUpdate(organisation); //this line below fails //AbstractBatcher:0 - Could not execute command: UPDATE tblTrnOrganisation SET WHERE OrganisationId = @p0 AND RVersion = @p1 //System.Data.SqlClient.SqlException: Incorrect syntax near the keyword 'WHERE'. session.Flush(); session.Delete(organisation); session.Flush(); } }
public TradingName(Organisation organisation) { if (organisation == null) { throw new ArgumentNullException("organisation"); } this.organisation = organisation; }