SQL is a relational database management system that can be used across various platforms like Linux, Unix, and Windows. It is commonly used for web applications and is an important part of the LAMP web development stack. SQL was originally created by the company SQL AB and is now owned by Oracle. It allows users to define schemas, tables and indexes using DDL commands, manipulate data using DML commands like SELECT, INSERT, UPDATE, DELETE, and control access permissions using DCL commands like GRANT.
Download as DOCX, PDF, TXT or read online on Scribd
0 ratings0% found this document useful (0 votes)
57 views
Question 1. What Is SQL?
SQL is a relational database management system that can be used across various platforms like Linux, Unix, and Windows. It is commonly used for web applications and is an important part of the LAMP web development stack. SQL was originally created by the company SQL AB and is now owned by Oracle. It allows users to define schemas, tables and indexes using DDL commands, manipulate data using DML commands like SELECT, INSERT, UPDATE, DELETE, and control access permissions using DCL commands like GRANT.
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 6
QUESTION 1. WHAT IS SQL?
SQL is an Oracle-backed open source relational database
management system (RDBMS) based on Structured Query Language (SQL). SQL runs on virtually all platforms,
Including LINUX, UNIX and WINDOWS. Although it can be used
in a wide range of applications, SQL is most often associated with web applications and online publishing.
SQL is an important component of an open source enterprise
stack called LAMP. LAMP is a web development platform that uses Linux as the operating system, APACHE as the web server, SQL as the relational database management system and PHP as the object-oriented scripting language. (Sometimes Perl or Python is used instead of PHP.)
Originally conceived by the Swedish company SQL AB, SQL was
acquired by Sun Microsystems in 2008 and then by Oracle when it bought Sun in 2010. Developers can use SQL under the GNU General Public License (GPL), but enterprises must obtain a commercial license from Oracle.
Today, My SQL is the RDBMS behind many of the top websites in
the world and countless corporate and consumer-facing web-based applications, including Facebook, Twitter and YouTube. For security, MySQL uses an access privilege and encrypted password system that enables host-based verification. MySQL clients can connect to MySQL Server using several protocols, including TCP/IP sockets on any platform. MySQL also supports a number of client and utility programs, command-line programs and administration tools such as MySQL Workbench.
Offshoots of MySQL, also known as forks, include the following:
Drizzle, a lightweight open source database management system
in development based on MySQL 6.0;
MaraiaDB, a popular community-developed "drop-in" replacement
for MySQL that uses MySQL APIs and commands; and
Percona Server with XtraDB, an enhanced version of MySQL
known for horizontal scalability
QUESTION 2. INTRODUCTION ABOUT DDL, DML,
DCL?
DDL- ( DATA DEFINITION LANGUAGE )
A data definition language (DDL) is a computer language used
to create and modify the structure of database objects in a database. These database objects include views, schemas, tables, indexes, etc. This term is also known as data description language in some contexts, as it describes the fields and records in a database table.
Commonly used DDL in SQL querying are:
CREATE: This command builds a new table and has a predefined
syntax.
ALTER: An alter command modifies an existing database
table. This command can add up additional column, drop existing columns and even change the data type of columns involved in a database table. An alter command syntax is ALTER object type object name parameters. ALTER TABLE Employee ADD DOB Date.
DROP: A drop command deletes a table, index or view. Drop
statement syntax is DROP object type object name. DROP TABLE Employee. DML- ( DATA MANIPULATION LANGUAGE )
A data manipulation language (DML) is a family of computer
languages including commands permitting users to manipulate data in a database. This manipulation involves inserting data into database tables, retrieving existing data, deleting data from existing tables and modifying existing data. DML is mostly incorporated in SQL databases
DML resembles simple English language and enhances efficient user
interaction with the system. The functional capability of DML is organized in manipulation commands like SELECT, UPDATE, INSERT INTO and DELETE FROM, as described below:
SELECT: This command is used to retrieve rows from a
table. The syntax is SELECT [column name(s)] from [table name] where [conditions]. SELECT is the most widely used DML command in SQL.
UPDATE: This command modifies data of one or more
records. An update command syntax is UPDATE [table name] SET [column name = value] where [condition]. INSERT: This command adds one or more records to a database table. The insert command syntax is INSERT INTO [table name] [column(s)] VALUES [value(s)].
DELETE: This command removes one or more records from a
table according to specified conditions. Delete command syntax is DELETE FROM [table name] where [condition].
DCL- ( DATA CONTROL LANGUAGE )
Introduction to DCL. DCL is used to control user access in a
database. This command is related to the security issues. Using DCL command, it allows or restricts the user from accessing data in database schema.
A data control language (DCL) is a syntax similar to a
computer programming language used to control access to data stored in a database (Authorization). In particular, it is a component of Structured Query Language (SQL). Examples of DCL commands include: GRANT to allow specified users to perform specified tasks.