I have a container called Post that contains different type of Posts, for example: Post, SimplePost, MultimediaPost, etc.
I’m developing a web api with asp.net core and ef core. So I need a method that retreives me multiple type of Posts for the same container.
I have a class called Post which is the simplest Post, and the other type of Posts (more complex ones) inherit from this one, but are different DbSets. I did it like this but maybe is wrong so any suggestion will be much appreciated.
There is a type of post that will contain a list of Oids and each oid will point to another post, but this post can be any type of post, so I need a method to query the container and get multiple type of posts in the same query.
Francisco Echenique is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.