Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6242319
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 24, 20262026-05-24T11:56:02+00:00 2026-05-24T11:56:02+00:00

I hate to ask the classic question of business logic in database vs code

  • 0

I hate to ask the classic question of “business logic in database vs code” again, but I need some concrete reasons to convince an older team of developers that business logic in code is better, because it’s more maintainable, above all else. I used to have a lot of business logic in the DB, because I believed it was the single point of access. Maintenance is easy, if I was the only one doing the changing it. In my experience, the problems came when the projects got larger and complicated. Source Control for DB Stored Procs are not so advanced as the ones for newer IDEs, nor are the editors. Business logic in code can scale much better than in the DB, is what I’ve found in my recent experience.

So, just searching around stackoverflow, I found quite the opposite philosophy from its esteemed members:

https://stackoverflow.com/search?q=business+logic+in+database

I know there is no absolute for any situation, but for a given asp.net solution, which will use either sql server or oracle, for a not a particularly high traffic site, why would I put the logic in the DB?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-24T11:56:03+00:00Added an answer on May 24, 2026 at 11:56 am

    Depends on what you call business.

    The database should do what is expected.

    If the consumers and providers of data expect the database to make certain guarantees, then it needs to be done in the database.

    Some people don’t use referential integrity in their databases and expect the other parts of the system to manage that. Some people access tables in the database directly.

    I feel that from a systems and component perspective, the database is like any other service or class/object. It needs to protect its perimeter, hide its implementation details and provide guarantees of integrity, from low-level integrity up to a certain level, which may be considered “business”.

    Good ways to do this are referential integrity, stored procedures, triggers (where necessary), views, hiding base tables, etc., etc.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I hate to have to ask, but I'm pretty stuck here. I need to
I hate ask stupid questions like this, but why doesn't my code do what
I hate to ask such a dumb question, but I'm just starting out, so
I hate to ask this question on this forum, but I'm having a lot
Okay I hate to ask this question ... but here goes. I am writing
I hate to ask this here, but many people on stackoverflow have talked about
I hate to ask here but I am stumped and so were the guys
I hate asking for code but I just can't seem to do the below
I hate asking for code but I just can't seem to do the below
I hate case sensitivity in databases, but I'm developing for a client who uses

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.