0

The get,values,count function of ydn db is not working in safari and ios9.

I have tried to reopen the db and then access it but still no luck.

  db_mob_audit = new ydn.db.Storage('idb_mob_auditor', schema);
  db_mob_audit.values('DomainInfo',key_range,9999).done(function (tempDdata) {
            if (tempDdata.length > 0) {}
  });

After doing this i get error "can't find variable window-ydn db".

1 Answers1

0

I think because of schema or some platform problem. Please check error during opening the database (always better to check error). Use dev version to get more information about the problem.

db_mob_audit = new ydn.db.Storage('idb_mob_auditor', schema);
db_mob_audit.onReady(function(e) {
  if (e) {
     window.console.error(e);
     // do plan B here
  }
  // begin using db from here
}

Also check out limitation on Safari by running unit tests on different storage mechanisms. Safari does look good.

http://dev.yathit.com/test/test_all.html?websql

http://dev.yathit.com/test/test_all.html?indexeddb

If still have problem, create a minimal unit test and file an issue at github.

Kyaw Tun
  • 12,447
  • 10
  • 56
  • 83