DZone
Web Dev Zone
Thanks for visiting DZone today,
Edit Profile
  • Manage Email Subscriptions
  • How to Post to DZone
  • Article Submission Guidelines
Sign Out View Profile
  • Post an Article
  • Manage My Drafts
Over 2 million developers have joined DZone.
Log In / Join
  • Refcardz
  • Trend Reports
  • Webinars
  • Zones
  • |
    • Agile
    • AI
    • Big Data
    • Cloud
    • Database
    • DevOps
    • Integration
    • IoT
    • Java
    • Microservices
    • Open Source
    • Performance
    • Security
    • Web Dev
DZone > Web Dev Zone > HTML5's IndexedDB: tutorial series

HTML5's IndexedDB: tutorial series

John Esposito user avatar by
John Esposito
·
Oct. 28, 11 · Web Dev Zone · Interview
Like (0)
Save
Tweet
10.44K Views

Join the DZone community and get the full member experience.

Join For Free

As a former database developer/admin, I'm often tempted to think of all computers as datastores that sometimes store particularly interesting data. After all, the most fundamental split in modern computer architecture occured over exactly where different kinds of data (including instructions) are stored.

Some of the confusion over HTML5's new database support has orbited around the data/instruction issue too. For some clarification on that front, look over Gerard Gallant's post from a few weeks ago. As Gerard observes:

To avoid any confusion, HTML 5 Web Storage is not the Index Database API or the Web SQL Database which are also HTML 5 related features that some browsers have started to support.

HTML 5 Web Storage is a form of browser storage that is similar to cookies but with several advantages.


Gerard goes on to list and discuss some of these advantages (worth browsing).

But in a way (as Gerard observes) Web Storage isn't fundamentally different from cookies. It's just a lot more powerful.

IndexedDB, on the other hand, is something different altogether. The specification is designed specifically for applications that address much larger stores than browsers using Web Storage will permit (usually just 5MB).

You can read the full spec (specs are always fascinating until they alter your state of consciousness), but for a quick overview you'd probably prefer a developer's perspective over W3's.

Providing that developer's perspective, Kristof Degrave just updated his multi-part tutorial series on creating and deleting a database, opening and a closing database connection, and defining a database structure in IndexedDB, with a nice little 'IndexedDB basics' intro thrown in for good measure.

Kristof's summary of the specification gets to the heart of IndexDB's power:

The Indexed DB specification provides an advanced key-value data management. It does this by using a transactional database to store their keys and corresponding values (more than one value for 1 key is allowed) and providing a means of traversing keys in a deterministic order.

 
Read the intro here, the creating/deleting/opening/closing tutorial here, and the defining tutorial here.

Database HTML

Opinions expressed by DZone contributors are their own.

Popular on DZone

  • How Low Code Demands More Creativity From Developers
  • Understand Source Code — Deep Into the Codebase, Locally and in Production
  • Monolith vs Microservices Architecture: To Split or Not to Split?
  • Kotlin vs Java: Which One Is the Best?

Comments

Web Dev Partner Resources

X

ABOUT US

  • About DZone
  • Send feedback
  • Careers
  • Sitemap

ADVERTISE

  • Advertise with DZone

CONTRIBUTE ON DZONE

  • Article Submission Guidelines
  • MVB Program
  • Become a Contributor
  • Visit the Writers' Zone

LEGAL

  • Terms of Service
  • Privacy Policy

CONTACT US

  • 600 Park Offices Drive
  • Suite 300
  • Durham, NC 27709
  • support@dzone.com
  • +1 (919) 678-0300

Let's be friends:

DZone.com is powered by 

AnswerHub logo