Questions tagged [dapper]

The tag has no usage guidance.

Filter by
Sorted by
Tagged with
1 vote
1 answer

How can I restore an entity from the database while keeping my entities database-independent?

Background I'm currently working on a project using domain-driven design and Dapper as my ORM. The entities are naturally slightly different than the tables in which they are stored (e.g. _id is ...
JansthcirlU's user avatar
1 vote
1 answer

Performing many SQL inserts quickly without using BulkCopy

I have a C# system that reads thousands of messages per minute from a Kafka topic. The messages are filtered and I need to insert the filtered messages into a MSSQL table. A normal insert statement is ...
Mulciber Coder's user avatar
-4 votes
1 answer

Changing databases in general repository methods when using Dapper [closed]

I'm developing a multi-database application. There is one admin database and many customer databases which are identical in structure. I also have a generic RepositoryBase which looks like the ...
Mitulát báti's user avatar
2 votes
1 answer

Best approach to connect master and child table while insert data in tables

I need advice what is best approach to connect data between master and child table. I have console application written in C# which scrape data from web, process data and insert them in table. Master ...
TJacken's user avatar
  • 123
0 votes
0 answers

Tradeoffs between Testability and Performance when filtering using SQL vs LINQ

My team has recently decided to adopt the CQRS pattern similar to the one used in the famous Microsoft EShopsOnContainers repository. In this solution, the queries are made in Query classes using ...
Josh L's user avatar
  • 103
-3 votes
1 answer

Defer insert data into a database

I need to insert some records into a database at a time when it normally it's not being used, what are some approaches I can take? I have considered using the SQL Server Agent to run some stored ...
Immac's user avatar
  • 97
2 votes
2 answers

Is it better to have a single query that returns all related entities, or separate queries for each case?

Summary When writing methods to query for related entities, is it better to have a single method for all related entities or separate methods for each combination? Full Problem I'm writing repository ...
Michael Brandon Morris's user avatar
3 votes
4 answers

Is it possible to cache data on a REST service that returns paginated data?

Under the REST architecture principles, a RESTful application should be stateless, therefore each time I invoke an ASP.NET 4 REST service (with GET verb) that pulls tens of thousands of records, the ...
Rikai no hōhō's user avatar
3 votes
1 answer

CQRS: how granular should the queries be?

I have a system that uses CQRS with the Queries written using Dapper. It's worked out well, except that there has been a proliferation of query classes that do almost the same thing. The downside of ...
NMrt's user avatar
  • 479
2 votes
2 answers

How to maintain database in open source application?

I'm building my first open source project. It's an API build with C#. My project has layers Api itself to receive requests Services library, for logic. Database library, for db operations. I'm ...
Sefa Ümit Oray's user avatar