Loading JSON Data

Although many JSON datasets are available, sometimes they are problematic to feed into a database. Often, at the start of a new programming project, a developer will be provided with some sample data that needs to be shoehorned onto the server, usually with little guidance other than “just get it on the server.” This chapter offers some examples of how to do just that.

From Download to Database

Our first example involves a list of US postal, or ZIP, codes. It can be downloaded from and it is free. (There are other similar datasets available that could use the same steps.) Taking the data ...

Get MySQL and JSON: A Practical Programming Guide now with O’Reilly online learning.

O’Reilly members experience live online training, plus books, videos, and digital content from 200+ publishers.