Summary -
In this topic, we described about the below sections -
What is Data
Data is distinct useful information. It can be used in a variety of forms like text, numbers, media, bytes, file, pdf etc. generally it is raw and unprocessed. It can be stored in pieces of paper or electronic memory. Word 'Data' is originated from the word 'datum' that means 'single piece of information.' It is plural of the word datum. Data is interchangeable.
What is Database
Database is a systematic collection of data, then it can easily modify, read, and write. The main purpose of the database is to operate a large amount of information by storing, retrieving, and managing data. Database is combination of fields, records, files. It can store data only once. Database is interlinked that information of one file can combined with another file to get exact result.
Types of Databases
There are different types of databases as follows
- Non-relational Database
- Relational Database
Non-relational Database
A collection of data in the form of keys & values which is not organised is called Non-relational Database.
For Ex - JSON, XML.
Relational Database
A collection of data in the form which is organised by following some kind of rules is called Relational Database. In this type, all the data will be stored in the form of tables. SQL is used to interact with relational database. It is easy to relate multiple tables to fetch the required information.
What is SQL?
SQL is Structured Query Language that allows users to store, read and update data stored in a relational database. SQL is a standardised language to interact with RDBMS (Relational Database Management System). SQL is used to perform all types of data operations in RDBMS.
Different RDBMS like MySQL, Oracle, MS Access used different dialects as T-SQL, PL/SQL, JET SQL etc. The American National Standards Institute (ANSI) and the International Standards Organization (ISO) Considered SQL as Standard language. SQL is user-friendly and domain-specific language. SQL can also do database security, backup, user management etc.
History of SQL
1970 − Dr. Edgar Frank Todd Codd of IBM is known as the father of relational databases "A Relational Model of Data for Large Shared Data Banks".
1974 − IBM researchers Raymond Boyce and Donald Chamberlin developed SEQUEL Language by following Codd's published paper.
1978 − IBM's San Jose Research Laboratory worked to develop Codd's ideas and released a product named System/R.
1979 – A company called Relational Software, which later became Oracle, commercially introduced its own version of the SQL language called Oracle V2.
1986 - The American National Standards Institute (ANSI) and the International Standards Organization (ISO) Accepted SQL as standard language.
Advantages -
- In less time, users can get large number of records using SQL queries.
- SQL is portable and can use everywhere.
- SQL does not need too much code to manage database system.
- SQL is simple language, get quick answers to typical questions within seconds.
- SQL have well defined standards that are used by ANSI and ISO.
- SQL does not have complex code and it makes the process simple.
- SQL language users can make different views of the database structure for the different users.
- SQL avoid duplication of data, as data stored once in database.
- SQL uses a single uniform language (DDL) for different roles like developer, user, Database administrator.
Disadvantages -
- SQL can be managed by an expert user or programmer.
- SQL occupies some space i.e. extra memory location for each record.
- SQL has a difficult interfacing with database than adding new lines of code.
- Some versions operating cost is high; hence programmers cannot access it.
- Due to hidden business rules, complete control is not given to the database.
Why SQL is Used?
- SQL is simple to learn because it is pure textual.
- SQL is used to access data from relational database management systems.
- SQL allow users to execute queries against the database.
- SQL is used to describe the data.
- SQL is used to define and use the data, in the database when it needed.
- SQL is used to create and delete the database and table.
- SQL is used to create a view, stored procedure, function in a database.
- SQL allows users to set permissions on tables.
- SQL Allows to set in within other languages using SQL modules.
Applications using SQL
- Data Integration Scripts - The database administrators and developers are mainly used SQL to write data integration scripts.
- Analytical Queries - Setting and running analytical queries on a regular basis, data analysts use structured query language.
- Retrieve Information - To retrieve the subsets of information within a database for analytics applications and transaction processing, The SQL commands select, insert, update, add, delete, create, truncate, and alter are used commonly.
- Business Intelligence - It is widely used in the Business Intelligence tool. • Data science and Big data tools - Data Science tools and Big data tools such as Spark, Impala are dependent on SQL.
- Other Important Applications - Users can modify structure of the table, they can update or delete the existing data in the table by using SQL.