Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

235
Views
Avoid dupliacte entries in MySQL table with auto suggestions

I'm working on a system, where authenticated users can suggest ideas, what to do next...

To be more precise, users can suggest activites, which are then entered into the MySQL database. Then, all users can see those activites and can vote for the ones, they like the most.

The problem is: I always have to think about the laziest users, that just enter something new, without checking, if this entry (or something similar) already exists...

The point is: say its about gaming, then in the end, I might have

  • Zelda
  • Zelda: Breath of the Wild
  • Zelda Breath of the Wild
  • Zelda BOTW
  • Zelda: BOTW

and propably 5 other alternatives, that I forgot about.

And no, I can't just compare it to a game library and insert the full names, as games would only be 10% of the hole list. Topics are from every category, so you can't compare it to databases, as I'd say...

What I thought about is: On keydown (when users are entering a new topic), the database is searched for entries and theres something showing saying "did you mean xxxx" and users would be able to click on it to vote for the already existing entry, rather then creating a new one with a more or less similar name.

Even with that way, users COULD still enter new entries though. Of course, I could prevent them from creating the EXACT SAME entry again, but not, if it's a variation.

Anybody has an idea, on how to prevent them from submitting the varieties, rather then taking/voting for an already existing entry?

Again, comparing to a database won't work most propably, as it can be everything from lifestyle, gaming, programming, etc....

about 4 years ago · Santiago Gelvez
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!