InvalidCastException on linq DB submit with non-integer key - by Wuzi

Status : 

  External<br /><br />
		This item may be valid but belongs to an external system out of the direct control of this product team.<br /><br />
		A more detailed explanation for the resolution of this particular item may have been provided in the comments section.


18
0
Sign in
to vote
ID 351358 Comments
Status Closed Workarounds
Type Bug Repros 17
Opened 6/16/2008 1:24:23 PM
Access Restriction Public

Description

When database contains two tables, both with automatic integer primary keys, and a relationship between a unique char field in one and a non-unique char field in the other, inserting new rows into the second table fails on submit with InvalidCastException.
Sign in to post a comment.
Posted by Vaccanoll on 10/27/2010 at 4:50 PM
This hotfix is not public. I don't know why. I had to call Microsoft Support and have them send me the hotfix. The support person said that they (tech support) don't control what is public and what is not, so she did not know why it was not public.

Just as a side note, a support call like this is free. If you have issues after the install of the hot fix that you have to pay/use support incidents.

The number I called was 1-800-936-4900. I had to say "Technical Support" and "I don't know" to get to a real person. It took that person a few tries to find it, but they can find it eventually.
Posted by smile2010 on 2/24/2010 at 5:26 PM
Thanks for posting about the hotfix. After apply NDP35SP1-KB963657-x86.exe, issue can be resolved.
Posted by JustKees on 12/10/2009 at 11:06 PM
The hotfix mentioned above can't be found anywhere. (At least by me) Will there be a new release for this hotfix?
Posted by Glen Little on 9/16/2009 at 10:48 AM
We have now got it working on both computers. It turns out that one had a hotfix applied. When the hotfix was applied to the other, and IIS restarted, the problem was fixed. The hotfix is NDP35SP1-KB963657-x86.exe.
Posted by Glen Little on 9/16/2009 at 10:09 AM
We have the same problem. However, the identical applciation works fine on one Windows XP computer, but fails in this manner on another Windows XP computer. We can't find any differences between them.

Both have .NET 3.5 SP1, Ria Services July '09.
Posted by TravisWhidden on 9/1/2009 at 10:33 PM
Could you please release a hotfix for this. I am hacking up my source; installing a beta version of 4.0; just to test it. I don't want to modify my database schema just because of an internal bug which will be fixed. This works perfectly in Win7, but 2003, and 2008 server reflect this bug.

ParentTable SomeParentID (bigint)
ChildTable SomeParentID(bigint) SomeOtherKeyID (short)

The SomeParentID is the relationship.

Please release a hotfix. I would be fine with a 3.5 System.Data.Linq.dll (if that where it exists) to reference manually. travis@hjtcentral.com

Thanks so much in advance!

Travis
Posted by didapape on 5/5/2009 at 7:58 AM
Let me know if there are any kb or service pack that finally solved this problem. I am developing a system with a database that contains many such relations and can not use a workaround I need a solution in the framework directly
Posted by Sarah Parra - MSFT on 1/6/2009 at 1:40 PM
I can confirm that this bug has been fixed for .NET 4.0, which is why it's still failing with .NET 3.5 SP1. We should have posted a note to that effect when the Connect issue was resolved, but it looks like this was reported around the time that we were in the middle of migrating some bugs between systems internally, and after the migration this particular bug had lost the link to Connect. So I apologize for the delay in updating this as a result of that, but did want to update this to let you know it will be fixed. Even now I can't update this issue like we normally do, so I am adding this note via the community comments instead.

Thanks,
Sarah Parra
LINQ to SQL Team
Posted by Dan Bruce on 1/5/2009 at 10:18 AM
This issue says it has been resolved on 26/06/2008 12:10:10 but I am still seeing it. I am using .NET 3.5 with SP1 published date 11/18/2008 on Windows Vista home premium.
Posted by Microsoft on 6/16/2008 at 11:44 PM
We were able to reproduce the issue you are seeing. We are escalating this bug to the product unit who works on that specific feature area. The product team will review this issue and make a decision on whether they will fix it or not for the next release