Monday, December 7, 2009

SQL and RDBMS

SQL:
SQL is an acronym for Structured Query Language and is a standard relational query language (SQL has been standardized by both ANSI and ISO) used for interaction with databases.

SQL was developed by IBM in 1970s and has its roots in the relational algebra defined by Codd in 1972. SQL functionality goes beyond the relational algebra, allowing to retrieve data, insert data, modify existing data and delete data from/to a RDBMS. SQL features arithmetic operators like division, multiplication, subtraction and addition, and comparison operators (=, >=, <=). SQL also defines several aggregate functions like MAX, MIN, AVG, COUNT, and SUM. SQL defines many keywords, which can be divided into several categories. The first SQL keyword category is for keywords used for data retrieval like the SELECT keyword. The second category is for the SQL keywords used for data manipulation like the INSERT, UPDATE, and DELETE SQL keywords. The third category is the transactional SQL keywords category, featuring keywords like COMMIT and ROLLBACK. Another SQL keyword category is the SQL Data Definition Language category featuring words like CREATE and DROP. Yet another category of SQL keywords controls the authorization and permission aspects of RDBMS (GRANT and REVOKE keywords). SQL is pronounced as “S-Q-L” or “see-quill”. SQL uses -- character sequence as a single line comment identifier. SQL commands are not case sensitive and the following SQL queries are equivalent:
SELECT * FROM Users

select * from Users

There are many SQL implementations also called SQL dialects and SQL extensions. For example MS SQL Server specific version of the SQL is called Transact-SQL, Oracle version of SQL is called PL/SQL, MS Access version of SQL is called JET SQL.

This SQL Tutorial will show you how to use SQL and its commands. You will be able to apply most of the knowledge gathered from this SQL tutorial to any Relational Database Management System.

RDBMS:

RDBMS is an acronym for Relational Database Management System. The data in RDBMS is stored in database objects called tables. The database tables are the primary data storage for every RDBMS and essentially they are collections of related data entries. For example a table called Users might store information about many persons, and each entry in this table will represent one unique user. Even though all user entries in the Users table are unique, they are related in the sense that they describe similar objects.

Table Users

FirstNameLastNameDateOfBirth
JohnSmith12/12/1969
DavidStonewall01/03/1954
SusanGrant03/03/1970

Each database table consists of columns and rows. Each table column defines the type of data stored in it, and this data type is valid for all rows in this table. A table row is a collection of data having 1 entry for each column in this particular table.

RDBMS store the data into group of tables, which might or might not be related by common fields (database table columns). RDBMS also provide relational operators to insert/update/delete information stored into the database tables.

MS SQL Server, DB2, Oracle and MySQL are all Relational Database Management Systems.

I’ll be using the RDBMS and database words interchangeably throughout this SQL Tutorial, so whenever I use the word database I mean RDBMS and the other way around.

0 comments:

Post a Comment

 

Friends

Followers

Fave This

Computer Technology Tips and Tricks for Devlopment Copyright © 2009 Magazine 3 Column is Designed by kamrul