You are on page 1of 22

Database Systems

දත්ත සමුදාය පද්ධති


1
දත්ත සමුදායක් යනු...
A Database is…
• විවිධ පුද්ග඼යන්ට භාවිතා කෂ ශැකි අයුරින් විධිමත් ආකාරයකට,
එකිනනකට වම්බන්ධිත දත්ත ර඲ලා තබාගැනීමක් දත්ත වමුදායකි.
– A collection of data stored in a standardized format, designed to be
shared by multiple users.
– A database is an organized collection of data.
- www.wikipedia.org
– A collection of related data. – Elmasri and Navathe

2
• දත්ත සමුදාය කළමනාකරණ පද්ධතියක් යනු :
ඳරිගණකගත ආකාරයට දත්ත වමුදාය ඳද්ධතියක් වෑදීමට
වශ ඳලත්ලා ගැනීමට නිර්මාණය කර ඇති මෘදුකාාංග නේ.
• Database Management System (DBMS):
A software package/ system to facilitate the
creation and maintenance of a computerized
database.
• දත්ත සමුදාය පද්ධතියක් යනු:
දත්ත ඇතු඼ත් කර ඇති දත්ත වමුදාය ඳද්ධතියක් නබොනශෝ
විට නම් නමින් ශැඳින්නේ. නබොනශෝ විට නම් වමග නලනත්
මෘදුකාාංගද භාවිතා නේ.
• Database System:
The DBMS software together with the data itself.
Sometimes, the applications are also included.
3
දත්ත වමුදායන් භාවිතා ලන අලව්ථා
Where is database used mostly
• ඳාවැල් / Schools
• බැාංකු / Banks
• ගුලන් නතොටුඳ඼ / Air Ports
• දුරකථන වමාගම් / Telecommunication
Companies
• දුම්රිය ගමනාගමනය / Railways
• ලයාඳාරික ව්ථාන / Business Environment
• මාධය ආයතන / Media Companies
• නරෝශල් / Hospitals
4
දත්ත වමුදායන් භාවිතනේ ලාසි
Advantages of Databases
• පුද්ග඼යන් අතර දත්ත නබදාගැනීම වශ හුලමාරු කරගත
ශැකිවීම.
• Sharing of data among multiple users.
• අලවර නනොමැතිල දත්ත ශැසිරවීම ඳා඼නය කෂ ශැකිවීම.
• Restricting unauthorized access to data.
• අල඾ය විටක දත්ත අතරින් නිලැරදි නතොරතුරු
නවොයාගැනීම ඳශසුවීම.
• Providing Storage Structures for efficient Query
Processing.

5
දත්ත සමුදායන් භාවිතයේ ලාසි
Advantages of Databases
• දත්ත උඳව්ථ කරගැනීනම් ඳශසුකම.
• Providing backup and recovery services.
• දත්ත අතර ඳලතින වාංකීර්ණ වම්බන්ධතා ශඳුනාගත
ශැකිවීම.
• Representing complex relationships among data.
• දත්ත වමුදාය ඳද්ධති භාවිතා කරන විවිධ පුද්ග඼යන්ට
විවිධ අතුරු මුහුණත් වඳයා දිය ශැකි වීම.
• Providing multiple interfaces to different classes of
users.
6
දත්ත වමුදාය ඳද්ධති ලර්ග
Types of Database System
• වම්ප්‍රදායික දත්ත වමුදාය ඳද්ධති (Traditional Database)
• බහුමාධය දත්ත වමුදාය ඳද්ධති (Multimedia Database)
• භූනගෝලීය දත්ත වමුදාය ඳද්ධති (Geographical Database)
• Data warehouse & Online Transaction Processing Systems.
• Real Time Databases.

7
දත්ත සමුදාය පද්ධති ල඼ විකා඾ණය
Evolution of Databases
• ඳෂමු යුගය (1st Generation)
– ඳැතලි නගොනු ආකෘතිය / ඒක නගොනු ඳද්ධතීන් (Flat File Model)
– ධූරාලලි ආකෘතිය (Hierarchical Model)
– ජා඼ ආකෘතිය (Network Model)
• නදලන යුගය (2nd Generation)
– වම්බන්ධක ආකෘතිය (Relational Model)
• නතලන යුගය (3rd Generation)
– Object Oriented Model
– ලව්තු වම්බන්ධක ආකෘතිය (Object Relational Model)
– XML දත්ත වමුදාය ඳද්ධති

8
ඳැතලි නගොනු ආකෘතිය / ඒක නගොනු ඳද්ධතීන්
Flat File Model
• මුල්ම යුගනේ ඳරිගණක ල඼ දත්ත ගබඩා කර තබාගැනීමට
නයොදාගත් ක්‍රමයයි. නමහිදී සිදුවූනේ ඳරිගණකනයන් වකව්
ක඼ ඳාඨ නගොනුලක සියළුම දත්ත යතුරුලියනය කර
තිබීමයි. වෑම නේලියක්ම එක් නරනකෝඩයක් න඼ව වැ඼කිනි.
එම නරනකෝඩනේ ව඲ශන් කර තිබූ දත්ත එකිනනකට
නලන්වූනේ නකොමාලලින් නශෝ හිව් අලකා඾ මගිනි.
• A flat file database is a database that stores data in a
plain text file. Each line of the text file holds one
record, with fields separated by delimiters, such as
commas or tabs.

9
පැතලි ය ොනු ආකෘතිය / ඒක ය ොනු පද්ධතීන්
Flat File Model

නමහිදී වම්පූර්ණ දත්ත ඳාදකනේ නතොරතුරු එක් ලගුලක ගබඩා කරයි.

10
පැතලි ය ොනු ආකෘතියේ ලාසි
Advantages of Flat File Model
• සියළුම දත්ත එක් ලගුලක තැම්ඳත් කිරීම.
– All records are store in one place.
• ඳශසුනලන් අලනබෝධ කරගත ශැකිවීම.
– Easy to understand.
• දත්ත අනුපිළිනල඼කට වැකසීම වශ ඼බාගැනීම
ඳශසුවීම.
– Simple sorting & filtering can be carried out.

11
පැතලි ය ොනු ආකෘතියේ අලාසි
Disadvantages of Flat File Model
• එකම දත්තය නැලත නැලත ලියවීමට ඇති ශැකියාල
– Potential Duplicate
• යාලත්කාලීන කිරීම අඳශසු වීම.
– Harder to update
• ඇතු඼ත් කර ඇති දත්ත ල඼ ලර්ගය නලනව් කිරීම
අඳශසු වීම.
– Harder to change data format
• දත්ත නවොයාගැනීනම් අඳශසුතා.
– Poor at complex queries
12
ධූරාලලි ආකෘතිය
Hierarchical Model
• A hierarchical database model is a data model in
which the data is organized into a tree -like structure.
The structure allows representing information using
parent/child relationships: each parent can have many
children, but each child has only one parent (also
known as a 1-to-many relationship). All attributes of a
specific record are listed under an entity type.
13
ධූරාලලි ආකෘතිය
Hierarchical Model
• ගවක ලූශයක ආකාරයට පිළිනය඼ වූ දත්ත වමුදාය ආකෘතියකි. නමම
ලූශනේදී නදමාපිය - දරු වම්බන්ධතා ආකාරයට දත්ත ශා නතොරතුරු
එකිනනකට වම්බන්ධ නේ.
• නමහි ඳාදය න඼ව තනි ලගුලක් ක්‍රියාකරයි. අනිකුත් ලගු එහි අතු ඾ාඛා
න඼ව ක්‍රියාකරයි.
• නදමාපිය - දරු වම්බන්ධතාලයට අනුක෕඼ වම්බන්ධයක් ඳලතී. එනම් එක්
දරුලකුට එක් නදමේපිනයකු සිටින අතර නදමේපියන්ට දරුලන්
කිහිඳනදනනකු සිටිය ශැක.
• නමහිදී ඳශ඼ මට්ටනම් ලගුලක නතොරතුරු ඼බාගැනීනම්දී ඳාදමය ලගුනේ
සිට පිළිනලලින් ඳශ඼ට යා යුතු නේ.

14
ජා඼ ආකෘතිය
Network Model
• ධූරාලලි ආකෘතිනේම උඳ කු඼කයක් න඼ව ශැඳින්විය ශැකිය.
• එකිනනකට වම්බන්ධ අතු වහිත ගව් රාශියක එකතුලක් න඼ව ද
ශැඳින්විය ශැකිය.
• ඉශත නදමාපිය වම්බන්ධතාලයට අනුල නමහිදී එක් දරුනලකුට
නදමාපියන් රාශියක් සිටිය ශැක.
• නමලැනි ඳද්ධතියක් ඳලත්ලානගන යාම ශා නඩත්තු කිරීම
ප්‍රානයෝගිකල ඉතා අඳශසු කාර්යයකි.
15
ධූරාලලි ආකෘතිය
Hierarchical Model

16
ජා඼ ආකෘතිය
Network Model
• A network database model is a database model that allows multiple
records to be linked to the same owner file.
• The multiple linkages which this information allows the network database
model to be very flexible.
• In addition, the relationship that the information has in the network
database model is defined as many-to-many relationship because one
owner file can be linked to many member files and vice versa.

17
ජා඼ ආකෘතිය
Network Model

18
සම්බන්ධක ආකෘතිය
Relational Model
• නමලැනි ආකෘතියක් ශඳුන්ලා දීමට නශේතුවූ කරුණ වූනේ දත්ත
ඳද්ධති භාවිතා කරන්නන්ට අල඾ය නතොරතුරු ක්඿ණිකල ශා
නිලැරදිල නතෝරා නේරා දත්ත ඳද්ධතිය තුලින් ඼බාගැනීමයි.

• The purpose of the relational model is to provide


a declarative method for specifying data and queries: users
directly state what information the database contains and
what information they want from it, and let the database
management system software take care of describing data
structures for storing the data and retrieval procedures for
answering queries.
19
සම්බන්ධක ආකෘතිය
Relational Model

20
ලස්තු සම්බන්ධක ආකෘතිය
Object Relational Model
• නමයද වාමානය වම්බන්ධක ආකෘතියට නබනශවින් වමාන නේ.

• විව්තෘත වම්බන්ධක ආකෘතිය න඼වද ශැඳින්නේ.


• නමහිදී දත්ත වමුදාය ඳද්ධති කෂමනාකරණය ව඲ශා Python, Java, C++ ලැනි
ලව්තු නැඹුරු භා඿ාලන් භාවිතා කරයි.
• මුල් ආකෘති ල඼ට ජයගැනීමට නනොශැකි වූ ඳරිගණක ආශ්‍රිත නිර්මාණකරණය
(Computer Aided Drawing), භූනගෝලීය නතොරතුරු ඳද්ධති (Geographic
Information Systems), බහුමාධය ආචයන ඳද්ධති (Multimedia Storage
Systems) ලැනි අාං඾ ජයගැනීමට නමම ක්‍රමනයන් ශැකිවිය.
21
22

You might also like