Skip to content

Bits of .NET

Daily micro-tips for C#, SQL, performance, and scalable backend engineering.

  • Asp.Net Core
  • C#
  • SQL
  • JavaScript
  • CSS
  • About
  • ErcanOPAK.com
  • No Access
C#

Why record Types Reduce Bugs in DTOs

- 25.01.26 - ErcanOPAK
public record UserDto(int Id, string Name);

Why this matters
Immutability + value equality = fewer accidental mutations.

Related posts:

Task.Run Inside ASP.NET Core Hurts Scalability

Convert List to List in one line in C#

EF Core — Change Tracking Is a Hidden Performance Tax

Post Views: 18

Post navigation

Use EXISTS Instead of IN for Better Query Plans
Use FrozenDictionary for Read-Heavy Workloads (.NET 8+)

Leave a Reply Cancel reply

Your email address will not be published. Required fields are marked *

February 2026
M T W T F S S
 1
2345678
9101112131415
16171819202122
232425262728  
« Jan    

Most Viewed Posts

  • Get the User Name and Domain Name from an Email Address in SQL (934)
  • How to add default value for Entity Framework migrations for DateTime and Bool (830)
  • Get the First and Last Word from a String or Sentence in SQL (822)
  • How to select distinct rows in a datatable in C# (799)
  • How to make theater mode the default for Youtube (708)
  • Add Constraint to SQL Table to ensure email contains @ (571)
  • How to enable, disable and check if Service Broker is enabled on a database in SQL Server (552)
  • Average of all values in a column that are not zero in SQL (517)
  • How to use Map Mode for Vertical Scroll Mode in Visual Studio (473)
  • Find numbers with more than two decimal places in SQL (436)

Recent Posts

  • Windows 11 Snap Layouts: Organize 10+ Windows Without Alt+Tab Hell
  • Kubernetes Ingress: Expose Multiple Services Through One Load Balancer
  • Docker Compose: Launch Full Stack Apps with One Command (Node + Redis + Postgres)
  • Visual Studio Live Share: Real-time Collaborative Coding Like Google Docs
  • WordPress REST API: Turn Your Site into a Headless CMS for React/Vue Apps
  • WordPress Custom Post Types: Build Real Estate, Job Board, or Product Catalogs
  • Photoshop Batch Processing: Edit 1000 Images While You Sleep
  • Photoshop Smart Objects: Edit Once, Update Everywhere Without Quality Loss
  • Windows 11 WSL2: Run Linux at Native Speed Without Dual Boot
  • WordPress Speed Hack: How Lazy Loading Images Cuts Page Load Time in Half

Most Viewed Posts

  • Get the User Name and Domain Name from an Email Address in SQL (934)
  • How to add default value for Entity Framework migrations for DateTime and Bool (830)
  • Get the First and Last Word from a String or Sentence in SQL (822)
  • How to select distinct rows in a datatable in C# (799)
  • How to make theater mode the default for Youtube (708)

Recent Posts

  • Windows 11 Snap Layouts: Organize 10+ Windows Without Alt+Tab Hell
  • Kubernetes Ingress: Expose Multiple Services Through One Load Balancer
  • Docker Compose: Launch Full Stack Apps with One Command (Node + Redis + Postgres)
  • Visual Studio Live Share: Real-time Collaborative Coding Like Google Docs
  • WordPress REST API: Turn Your Site into a Headless CMS for React/Vue Apps

Social

  • ErcanOPAK.com
  • GoodReads
  • LetterBoxD
  • Linkedin
  • The Blog
  • Twitter
© 2026 Bits of .NET | Built with Xblog Plus free WordPress theme by wpthemespace.com