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

176
Views
indexddb A version change transaction is running

i am new in indexedddb.

when I want to create a transaction with a inceased version of the database (I increase the version because otherwise the upgradneeded event is never executed), I have the error "A version change transaction is running" which displays.

that's my code (it's from MDN):

var request = window.indexedDB.open("new-db", 8);

request.addEventListener('upgradeneeded', event => {
    console.log("bonjour");

    var db = event.target.result;

    var request = db.transaction([], "readwrite")
        .objectStore("customers")
        .delete("444-44-4444");
    request.onsuccess = function (event) {
        // c'est supprimé !
    };

});

request.onsuccess = function () {
    console.log("open");

}

THANKS FOR YOUR HELP.

about 4 years ago · Juan Pablo Isaza
1 answers
Answer question

0

Replace this:

var request = db.transaction([], "readwrite")
        .objectStore("customers")
        .delete("444-44-4444");

With this:

var existingVersionChangeTransaction = event.target.transaction;
existingVersionChangeTransaction.objectStore('customers').delete('444-44-4444');
about 4 years ago · Juan Pablo Isaza Report
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!