O'Reilly logo

Dreamweaver CS5: The Missing Manual by David Sawyer McFarland

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Databases: A Quick Introduction

Simply put, databases store information. You encounter them every day in one way or another, whether searching Amazon.com for new books, or updating your Facebook profile.

A database is like an electronic filing cabinet that stores related information. At home, you might have a filing cabinet that stores the bits and pieces of your life: a folder labeled “Insurance,” for example, in which you keep information about the various insurance policies you carry. Other folders might contain information on phone bills, car service records, and so on. Databases work more or less the same way, as the following sections explain.

Tables and Records

Databases use an electronic equivalent to filing folders: tables. A table is a container that holds information about a set of similar items. In the CosmoFarmer online store database, one table stores information on all the products the site sells, for example.

This Products table tracks certain information—the name of the product for sale, its price, a short description, and a few other items. The table stores each piece of information, like price, in a column. All the information for each product (all the columns taken together, in other words) makes up a single record, which the table stores in a row (see Figure 23-8).

This diagram shows part of CosmoFarmer’s Products table’s structure, with information for four records. Each row in the table represents a single record, or item, while each piece of information for a record is stored in a single field, or cell.

Figure 23-8. This diagram shows part of CosmoFarmer’s Products table’s structure, with information for ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required