Re: [Firebird-net-provider] Entity Framework Foreign Key Relation

2010-01-21 Thread Scott Price
en Borrie [mailto:[email protected]] > Sent: Wednesday, January 20, 2010 6:08 PM > To: For users and developers of the Firebird .NET providers > Subject: Re: [Firebird-net-provider] Entity Framework Foreign Key Relation > > At 10:48 AM 21/01/2010, you wrote: > >> Yes.

Re: [Firebird-net-provider] Entity Framework Foreign Key Relation

2010-01-21 Thread Radwan Khershif
ailto:[email protected]] Sent: Wednesday, January 20, 2010 6:08 PM To: For users and developers of the Firebird .NET providers Subject: Re: [Firebird-net-provider] Entity Framework Foreign Key Relation At 10:48 AM 21/01/2010, you wrote: >Yes. The trigger will make the insert value, only if the PK

Re: [Firebird-net-provider] Entity Framework Foreign Key Relation

2010-01-21 Thread Jiri Cincura
On Thu, Jan 21, 2010 at 00:48, Muthu Annamalai wrote: > Yes. The trigger will make the insert value, only if the PK value is null. > But from entity framework, all my PK's are integer and sending zero value to > database. Of course. The default value for int is 0, hence when the entity is created

Re: [Firebird-net-provider] Entity Framework Foreign Key Relation

2010-01-20 Thread Muthu Annamalai
Sent: Wednesday, January 20, 2010 6:08 PM To: For users and developers of the Firebird .NET providers Subject: Re: [Firebird-net-provider] Entity Framework Foreign Key Relation At 10:48 AM 21/01/2010, you wrote: >Yes. The trigger will make the insert value, only if the PK value is null. >But

Re: [Firebird-net-provider] Entity Framework Foreign Key Relation

2010-01-20 Thread Muthu Annamalai
context.SaveChanges. -Original Message- From: Jiri Cincura [mailto:[email protected]] Sent: Wednesday, January 20, 2010 5:09 PM To: For customers and developers of the Firebird .NET providers Subject: Re: [Firebird-net-provider] Entity Framework Foreign Key Relation On Wed, Jan 20

Re: [Firebird-net-provider] Entity Framework Foreign Key Relation

2010-01-20 Thread Helen Borrie
At 10:48 AM 21/01/2010, you wrote: >Yes. The trigger will make the insert value, only if the PK value is null. >But from entity framework, all my PK's are integer and sending zero value to >database. If you want your trigger to work, don't include the PK in the INSERT statement! Helen -

Re: [Firebird-net-provider] Entity Framework Foreign Key Relation

2010-01-20 Thread Muthu Annamalai
s and developers of the Firebird .NET providers Subject: Re: [Firebird-net-provider] Entity Framework Foreign Key Relation On Wed, Jan 20, 2010 at 18:51, Muthu Annamalai wrote: > How would you avoid zero value for all PK's. Didn't you just said that you're generating PKs w

Re: [Firebird-net-provider] Entity Framework Foreign Key Relation

2010-01-20 Thread Jiri Cincura
On Wed, Jan 20, 2010 at 18:51, Muthu Annamalai wrote: > a record in customer table using Entity Framework all the PK’s were inserted > as 0. I searched online and changed all the PK’s as Identity column, still > no luck. See the sample row. Reading this looks like you're talking about FK. Anyway

Re: [Firebird-net-provider] Entity Framework Foreign Key Relation

2010-01-20 Thread Jiri Cincura
On Wed, Jan 20, 2010 at 18:51, Muthu Annamalai wrote: > How would you avoid zero value for all PK’s. Didn't you just said that you're generating PKs with trigger? If so, the trigger should populate the proper value. -- Jiri {x2} Cincura (CTO x2develop.com) http://blog.cincura.net/ | http://www.

[Firebird-net-provider] Entity Framework Foreign Key Relation

2010-01-20 Thread Muthu Annamalai
I have the following installed VS 2010 Dot Net Framework 4.0 Firebird 2.5.0 Dot Net Provider 2.5.1 I have following issues, I have a Customer Table which has foreign key relationship with Person and Address Table. I create PK values for these tables using triggers. When I insert a re

[Firebird-net-provider] Entity Framework Foreign Key Relation

2010-01-20 Thread Muthu Annamalai
I have the following installed VS 2010 Dot Net Framework 4.0 Firebird 2.5.0 Dot Net Provider 2.5.1 I have following issues, I have a Customer Table which has foreign key relationship with Person and Address Table. I create PK values for these tables using triggers. When I insert a re