Creating Databases  «Prev  Next»

Lesson 5Connecting databases to the Web
ObjectiveExplain the process used to connect a database to the Web using ODBC and SQL.

Using ODBC to connect to a Relational Database

ODBC is a database access protocol based on the Windows NT platform. IBM, Microsoft, and others developed this most widely supported database protocol. It uses the SQL database access language.
To connect a Web site to a relational database using ODBC, you need:
  1. An ODBC driver
  2. A client software that can communicate with the driver, such as a Perl module
The process to connect the Web site to the database is as follows:
  1. Configure the driver on the Web server.
  2. Write the database query.
  3. The query returns the results.

Using SQL

SQL is a standardized database language that lets you access data in relational database management systems by describing the data you want to see. It also lets you define the data in a database as well as manipulate and update that data. An SQL statement consists of a command followed by one or more qualifying clauses, such as a table name or column name.
You can see examples of SQL commands and their functions in the following image.

The relationship between eBusiness and eCommerce
1) The statement above creates a table named "CLIENT" consisting of 7 columns

Grant Select
2)
GRANT SELECT ON CLIENT TO MANAGER
SELECT * FROM CLIENT WHERE ZIP_CODE = 97140

ODBC Sql - Quiz

Click the Quiz link below to test your understanding of ODBC and SQL functions.
ODBC Sql - Quiz