i have following db schema:
users -id (uniqueidentifier) -firstname -lastname -email authproviders -id (smallint) -name userauthproviders -id (uniqueidentifier) -user (uniqueidentifier, fk) -authprovider (smallint, fk) -identity (nvarchar)
i need map authproviders user object. started idbag, looks allows me have id, user relationship, , authprovider relationship. need able include identity well.
what else can use map it?
you need use many-to-one , one-to-many, ends 3 classes instead of two. can eliminate joining class public api, you'll still have deal in poco class internals.
a more complete answer can found here:
nhibernate many-to-many - how retrieve property join table , associate child?
Comments
Post a Comment