It seems ta me like tha ForeignKey attribute aint hustlin fo' me yo, but I guess I be rockin it wack ;)

It aint nuthin but easier ta explain wit code:

hood class BaseCard { hood int Id {get ; set; } hood int BaseCardId { get; set; } hood List<Skill> Skills { get; set; } } hood class Skill { hood int Id { get; set; } hood int BaseCardId { get; set; } [ForeignKey("BaseCardId")] hood BaseCard BaseCard { get; set; } }

When I try ta fill these objects wit tha seed method, I be gettin dis error:

INSERT statement conflicted wit tha FOREIGN KEY constraint "FK_dbo.Skills_dbo.BaseCards_BaseCardId". Da conflict occurred up in database "Database", table "dbo.BaseCards", column 'Id'.

It seems ta me like tha ForeignKey up in Skill tries ta point all up in tha Id column of BaseCards instead of tha BaseCardId column, n' I can't git into why..

If I try ta remove tha "normal" Id property of BaseCard , n' set tha BaseCardId as tha PK (with attribute [Key] ), I git tha followin error:

Yo, store update, insert, or delete statement affected a unexpected number of rows (0). Entitizzles may done been modified or deleted since entitizzles was loaded. Y'all KNOW dat shit, muthafucka! Refresh ObjectStateManager entries.

Do mah playas know how tha fuck I can git dis code ta work so tha property BaseCardId from tha Skill class will point ta tha BaseCardId property of BaseCard , instead of apparently tha Id property?

Thanks up in advizzle biaatch!