More on SQL

Read this chapter. Take notes and be able to provide details about SQL, data definition language (DDL), data manipulation language (DML), and Structured English Query Language (SEQUEL). 

SQL is a universal and standard language that interfaces with relational databases. SQL is used to communicate, analyze, and provide results from the data fields stored in a relational database. This next section will cover user-defined SQL objects, also known as functions. Your ability to understand and specify functions reduces the chance of errors in your SQL programming code. Also, remember when we discussed SQL injection attacks while looking at database security? Poorly constructed SQL code is what makes these kinds of attacks possible.

SQL Structured Query Language

Structured Query Language (SQL) is a database language designed for managing data held in a relational database management system. SQL was initially developed by IBM in the early 1970s (Date 1986). The initial version, called SEQUEL (Structured English Query Language), was designed to manipulate and retrieve data stored in IBM's quasi-relational database management system, System R. Then in the late 1970s, Relational Software Inc., which is now Oracle Corporation, introduced the first commercially available implementation of SQL, Oracle V2 for VAX computers.

Many of the currently available relational DBMSs, such as Oracle Database, Microsoft SQL Server (shown in Figure 15.1), MySQL, IBM DB2, IBM Informix, and Microsoft Access, use SQL.


Figure 15.1. Example of Microsoft SQL Server, by A. Watt.

In a DBMS, the SQL database language is used to:

  • Create the database and table structures
  • Perform basic data management chores (add, delete and modify)
  • Perform complex queries to transform raw data into useful information

In this chapter, we will focus on using SQL to create the database and table structures, mainly using SQL as a data definition language (DDL). In Chapter 16, we will use SQL as a data manipulation language (DML) to insert, delete, select and update data within the database tables.



Source: Adrienne Watt and Nelson Eng, https://opentextbc.ca/dbdesign01/chapter/sql-structured-query-language/
Creative Commons License This work is licensed under a Creative Commons Attribution 4.0 License.