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

  • SEARCH
  • Home
  • 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 1019061
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 16, 20262026-05-16T10:57:11+00:00 2026-05-16T10:57:11+00:00

Users in our application participate in forums and create various entities. In the schema

  • 0

Users in our application participate in forums and create various entities. In the schema you mark references from those tables back to the User table as foreign key references. We are unable to remove this user entry from the database, since it has several foreign key constraints which can be removed.

One way of addressing would be to make the User field in other tables as nullable, so that you can mark these values as nullable before removing the user entry. Removing information from other tables is not an option at all as it will lead to inconsistency (e.g. remove a forum post belonging to the user will cause a problem).

The other option was to just mark the User entry as removable and don’t make it available as part of the user queries. This theoretically means that no user can ever be removed from the system and might be an issue if someone would want to use a similar loginid as the removed user.

Would like to know, how others tackle this issue?

  • 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-16T10:57:12+00:00Added an answer on May 16, 2026 at 10:57 am

    We just usually soft-delete the users. In other words, have a column in the users table indicating that they’re no longer active and modify all the queries so that they only work on active users.

    That has two advantages:

    • it doesn’t stuff up foreign key constraints with other tables; and
    • it preserves all the data on the off-chance that you need to recover it at some point.

    Unless your user quantity is into the billions or your turnover is massively high, keeping old users around will not stress most databases.

    This can be used to enact a similar scheme to what SO has. When users “disappear”, the questions and answers authored by them still have author information but it’s greyed out.

    If you NULLed the user information (or even if you had a single Unknown user to assign the posts to if you didn’t want to allow NULLs), you would not have this information.

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

Sidebar

Related Questions

My company needs to allow the internal users of our application to write queries
I'd like to encourage our users of our RCP application to send the problem
In our application we enable users to print pages. We do this by supplying
Our web application sends e-mails. We have lots of users, and we get lots
As we do not implement the users of our applications as users in SQL
Our application uses Hibernate for ORM, and stores data in several schemas, accessing them
Our application uses a large product database that is updated once a day. Updates
We're planning to use standard ASP.NET user authentication for our application. However, by default
At the moment, our application uses the Trident Win32 component, but we want to
I'm about to implement a feature in our application that allows the user to

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.