Chapter 9. Files and Databases

In this chapter, we're going to look at how to store, process, and interact with external sources of data from our Ruby programs. In Chapter 4, we briefly looked at how to load files to get data into an application, but this chapter will extend upon that greatly and allow you to create files from scratch from your Ruby programs.

Later in this chapter, we'll look at databases—specialized organizations of data—and how to interact with them, along with some notes on interacting with popular database systems such as SQLite, MySQL, PostgreSQL, Oracle, and Microsoft SQL Server. You can use databases for simple tasks such as storing information about a small set of items or as an address book, but databases are also used ...

Get Beginning Ruby: From Novice to Professional now with O’Reilly online learning.

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