A lmost all e-commerce related applications tie a Web server to a database. At the most obvious level, a database is used to store information about a companies products, its customers, and their orders. Databases may store a wide variety of other information, including manufacturing information, multimedia data, advertising information, etc. The most popular type of database is the relational database. From the users perspective, data is stored in tables.
References can exist between columns, or fields , in one table and fields in another table.
For instance, a column in the orders table will refer to the user ID of the customer who placed an order. The customer's information is stored in another table. A standardized language has been developed to provide a product-independent interface to relational databases. More often, the database is a component of a larger system, and the SQL must be embedded into the application program. The actual techniques for doing this vary by database product and application development environment.