ah Ok. Now its allright.
Thank you again)
Fluent NHibernate tutorial Simple ORM application
#17
Posted 21 July 2011 - 07:08 AM
FlashM, on 06 January 2011 - 01:56 AM, said:
This was a quick fix of your solution that you sent to my mail account:
OK, this was just a quick check of your solution and I kind of fixed it...
In your BuildSessionFactory method I updated this line of code from this:
.Database(PostgreSQLConfiguration.Standard
into this:
.Database(PostgreSQLConfiguration.PostgreSQL82
Then I also added Mono.Security.dll reference to the project and everything worked as it should.
Remember to create an empty database with assigned user in PostgreSQL first.
Let me know if this worked for you as well.
best regards,
Kecman Ales
OK, this was just a quick check of your solution and I kind of fixed it...
In your BuildSessionFactory method I updated this line of code from this:
.Database(PostgreSQLConfiguration.Standard
into this:
.Database(PostgreSQLConfiguration.PostgreSQL82
Then I also added Mono.Security.dll reference to the project and everything worked as it should.
Remember to create an empty database with assigned user in PostgreSQL first.
Let me know if this worked for you as well.
best regards,
Kecman Ales
Hi FlashM
apology but performing the steps mentioned in the tutorial, even I have problems with the sample application. Please could you help me with this? using both database engines I have the following issue that was attached in the image file.
thanks for your help.
Attached image(s)
#18
Posted 07 September 2011 - 03:11 AM
Hi
i try the steps you give in this tutorial,but i have the same problem as franco148J.
any help
i try the steps you give in this tutorial,but i have the same problem as franco148J.
any help
#19
Posted 14 March 2012 - 09:04 PM
I also seem to have the same issue as the last two posters.
The text of the issue exception states that the FluentNHibernate.dll] Signature is incorrect.
I am using the latest version of FluentNhibernate.dll (1.2).
Any help is greatly appreciated.
Chris
The text of the issue exception states that the FluentNHibernate.dll] Signature is incorrect.
I am using the latest version of FluentNhibernate.dll (1.2).
Any help is greatly appreciated.
Chris
#20
Posted 20 April 2012 - 03:32 PM
Hi,
Thank you for this tutorial. I tried completing this and got the following exception.
"FluentNHibernate.Cfg.FluentConfigurationException was unhandled" and I cannot figure out why it's not connecting to my new empty DB.
The code which causes the exception is shown below
When I try and connect to the DB directly through VS2010, I have no problems. I have tried to match the connection settings, but still can't get it to work.
In VS2010, the connection string to the DB is :
Data Source=Ravi-PC;Initial Catalog=NHibernateTestDB;Integrated Security=True
Sorry if this is a basic question, I'm a newbie so still have a steep learning curve.
Thanks,
Ravi
Thank you for this tutorial. I tried completing this and got the following exception.
"FluentNHibernate.Cfg.FluentConfigurationException was unhandled" and I cannot figure out why it's not connecting to my new empty DB.
The code which causes the exception is shown below
private static ISessionFactory BuildSessionFactory()
{
AutoPersistenceModel model = CreateMappings();
return Fluently.Configure()
.Database(MsSqlConfiguration.MsSql2008
.ConnectionString(c => c
.Server("Ravi-PC")
.Database("NHibernateTestDB")
.Username(@"Ravi-PC\Ravi")
.Password("")
))
.Mappings(m => m
.AutoMappings.Add(model))
.ExposeConfiguration(BuildSchema)
.BuildSessionFactory();
}
When I try and connect to the DB directly through VS2010, I have no problems. I have tried to match the connection settings, but still can't get it to work.
In VS2010, the connection string to the DB is :
Data Source=Ravi-PC;Initial Catalog=NHibernateTestDB;Integrated Security=True
Sorry if this is a basic question, I'm a newbie so still have a steep learning curve.
Thanks,
Ravi
#21
Posted 15 May 2012 - 11:43 PM
Thanks for such a nice and comprehensive tutorial...
It works very correctly...
It works very correctly...
#22
Posted 14 October 2012 - 08:37 PM
Hi FlashM,
The guide is so good,
but when I add more class
class employee was adjusted as follow
Before running this sample, I delete all table on but the error appear at function
Please help me to fix it
Thankyou very much indeed
The guide is so good,
but when I add more class
namespace WindowsFormsApplication1.Model
{
public class Sex
{
public virtual int SexID { get; set; }
public virtual string SexName { get; set; }
}
}
class employee was adjusted as follow
namespace WindowsFormsApplication1.Model
{
public class Employee
{
public virtual int Id { get; set; }
public virtual string FirstName { get; set; }
public virtual string LastName { get; set; }
public virtual string Address { get; set; }
public virtual Post Post { get; set; }
public virtual DateTime DateEmployed { get; set; }
public virtual Sex Sex { get; set; }
}
}
Before running this sample, I delete all table on but the error appear at function
private static ISessionFactory BuildSessionFactory()
{
AutoPersistenceModel model = CreateMappings();
return Fluently.Configure()
.Database(MsSqlConfiguration.MsSql2008
.ConnectionString(c => c
.Server("SSGSERVER\\SQLEXPRESS")
.Database("ORMTest")
.Username("sa")
.Password("sa")))
.Mappings(m => m
.AutoMappings.Add(model))
.ExposeConfiguration(BuildSchema)
.BuildSessionFactory();
}
Please help me to fix it
Thankyou very much indeed
|
|

MultiQuote






|