Category Archives: Database

[database]Functions provided by DBMS

Here is a list of non-exhaustive functions provided by DBMS (Database management system) To prevent data lost during system failure, it should provide reliable recovery service. Provide transaction service for user such as read (select), update, delete, commit, insert, rollback. … Continue reading

Posted in Database | Tagged | Leave a comment

[DATABASE] File base vs database

This post illustrates the need for database approach to manage data. Problems with file base approach Data is stored in file defined by application, hence there is a possibility of potential useful data needed by another application but not aware … Continue reading

Posted in Database | Tagged | Leave a comment

[DATABASE]ACID property of DBMS

Atomicity refers to a transaction is either fully completed or not completed at all, there is no partial complete transaction. This also refers to all or none rule. Consistency refers during transaction the integrity constraints are maintained so that the … Continue reading

Posted in Database | Tagged , | Leave a comment

[DATABASE] VIEWS

Views are virtual tables derived from columns and rows from the base table. Views provide what data are needed by the users, saving the trouble for users to understand the complexity and abstraction of the base tables. Views are dynamic, … Continue reading

Posted in Database | Tagged | Leave a comment

[DATABASE]SQL query examples

There are three relations used for this example – RENTAL_CUSTOMER, CAR, RENTAL. Below are the SQL statements used to create the relations. Data have been inserted to the relations: RENTAL_CUSTOMER CAR RENTAL List all cars rented by Smith since 1st … Continue reading

Posted in Database | Tagged | Leave a comment

[DATABASE] Difference between intersect and union

I have two relations namely PROPERTY and LEASE, see the PROPERTYNO attributes returned from PROPERTY and LEASE respectively: In intersect, tuples which exists in both relations will be displayed removing duplicates. In union, all tuples from property and all tuples … Continue reading

Posted in Database | Tagged , | Leave a comment

[DATABASE]Difference between inner join, right and left outer join

Creating the tables Data from T1 Data from T2 Left outer join In the below example left table is T1 and right table is T2. Left outer join will cause tuples of the left table (T1) to be preserved, the … Continue reading

Posted in Database | Tagged , , | Leave a comment