NHibernate - Execute SQL to populate DTO

后端 未结 2 1697
有刺的猬
有刺的猬 2021-01-05 15:15

I have some instances for reporting where executing sprocs is easier and simpler than complicated QueryOver statements.

I have a DTO, not an entity, that represents

2条回答
  •  Happy的楠姐
    2021-01-05 16:14

    If you want the simplest solution I suggest you add in your architecture a micro / orm like Dapper to do this. It is just dropping a single file in your project and follow the sample. In order to me it is the best solution to pair to NH when you have to do the thinghs that are for some reason out of the entity logic.

提交回复
热议问题