11-02-2013, 10:15 AM
SQL COMMANDS
1SQL .docx (Size: 34.98 KB / Downloads: 19)
WHAT IS DATA?
Data is the name given to facts or entities such as names and numbers. e.g. Weight, prices, marks etc.
WHAT IS INFORMATION?
Information is the data that has been covered into more useful forms.
WHAT IS DATABASE?
A database can be defined as a collection of coherent, meaningful data (information) or database is the facts or information placed in an organized form.
Without any organization information has no meanings.
A database is an organized collection of data that is useful to us. The data inside in a database can be modified, deleted or new data can be added. They are stored in the form of records as shown in the table below:
Advantages of DBMS:
1. Controlling Redundancy: In file system, each application has its own private files, which can’t be shared between multiple applications. This can often lead to considerable redundancy in the stored data, which results in wastage of storage space. In DBMS by having centralized database this can be avoided.
2. Integrity can be enforced: Integrity of data means that data in database is always accurate, such that inaccurate information cannot be stored in database.
3. Standards can be enforced: Since DBMS is a central system, so standard can be enforced easily may be at company level, department level, national level or international level.
4. Inconsistency can be avoided: When the same data is duplicated and changes are made at one site, which is not propagated to the other site, it gives rise to inconsistency and the two entries regarding the same data will not agree. At such time the data is said to be inconsistent. So if redundancy is removed chances of having inconsistent data is also removed.
5. Data can be shared: DBMS is a centralized system in which data can be shared by multiple applications.
Disadvantages of DBMS:
1. Complexity: The provision of the functionality that is expected of a good DBMS makes the DBMS an extremely complex piece of software.
2. Size: The complexity and breadth of functionality makes the DBMS an extremely large piece of software, occupying many megabytes of disk space and requiring substantial amount of memory to run efficiently.
3. Performance: Performance is slow as compared to file processing system.
4. Higher impact of failure: In DBMS system failure of any component can bring operations to a halt.
INTRODUCTION TO SQL
SQL is ANSI standard computer language for Relational Database Management Systems such as Oracle, Sybase, Microsoft SQL Server, Access, Ingress etc. It is an industry standard language for creating, updating and querying relational database management systems.
SQL, which talks to a relational database, is a language about manipulating sets of data stored in tables. It consists of relatively small number of main commands such Create, Alter, Drop, Select, Insert, Update etc to accomplish this.SQL has a special version named PL/SQL, which is sometimes termed as a superset of SQL. It bridges the gap between database technology and procedural languages as programmers can use PL/SQL to create programs for validation and manipulation of table, something that was not possible with SQL.
While SQL, also called Interactive SQL, is used to create maintain tables, indexes etc. and also for data manipulation interactively, PL/SQL is used to create programs for validation and manipulation of table data. PL/SQL is thus a language closely related to SQL but allows you to write programs as ordered series of statements.