Hi, I'm new to nhibernate, and everything is was working fine until now.
I have a problem and I can't find an answer to it on the docs nor the forum, so I would appreciate if somebody could help me.
The thing is, I'm trying to develop a small app to control a warehouse with C# - Nhibernate - MySQL.
I have a class called StockMovement.
When I save a new StockMovement with session.Save (also using ITransaction) the INSERT query is executed in Mysql and the record is saved in the correct table, but, when I open another separate session and try to calculate stock by adding/substracting the StockMovements recorded on the database using
Code:
session.Find("FROM StockMovement")
I don't get the records saved with the other session until the reference to the other session is disposed.
I tried flushing the first session with session.Flush(); and changing the flushmode to Commit(), but nothing happened.
I'm sure there is something I didn't understand about how the O/R mapper works, but I can't figure it out.