Definition Database
The database is a set of data stored in the magnetic disk, optical disk or other secondary storage. Collection of integrated data-related data of an enterprise (company, government or private).
For example:
- Manufacturing business –> Production planning data, recent production data, materials order data, etc
- Hospital –> Patient data, doctor, nurse, etc
Database management system (DBMS)
Database management System is database collection with software application in based of database. This application programs is use for accessing and maintaining the database. The first aim of DBMS is to preparing an easy and efficient environment for using, collecting and storing data and information.
- Bit: is the smaller part of data, which contain of value 1 or 0
- Byte: collection of bits that of a kind
- filed: collection of byte that of a kind, which in database is called "attribute".
ATTRIBUTE OR FIELD
Attribute is the nature or characteristics of an entity that provides provide detail on these entities. A relationship can also have attributes. Example attributes:
- STUDENTS: NIM, NAME, ADDRESS
- CAR: NOMOR_PLAT, COLOR, TYPE, CC
Type of attribute
1. Single vs. multivalue
Single: only can fill by one value
multivalue: can fill with more one value with the same of kind
2. Atomic vs. composition
Atomic: can not divided into smaller attribute
Composition: boundless from some smaller attribute
Derived attribute is an attribute which its value can be produced from other attribute
4. Null value attribute
Null value attribute is an attribute with no value for a record
5. Mandatory value attribute is an attribute which must have value
RECORD / TUPLE
It is a line of data in a relationship, and consists of a set of attributes where the attribute-attribute-attribute is to inform each other entity / relationship fully
Entity / FILE
File is a collection of similar records and have the same elements, the same attributes but different data value.
File Type
In processing applications, files can categorized as follows:
- Master File
- Transaction Files
- File Reports
- File History
- File Protection
- File Work
Domain
Domain is collection of values which enabled to stay in one or more attribute. Every attribute in a relational database is defined as a domain
Key of element data
Key is the element of record which used to find the record when accessing or can also used to identify every entity / record / row.
Kind of key:
Super key is one or more attribute from a table which can be used for identifying entity / record from table uniquely
Candidate key is super key with minimum attribute. Candidate key may not contain attribute of other table so that the candidate is super key, but not the contrary
Primary key
One of the attribute of candidate key can be selected / determined into primary key with 3 criteria:
- The key is more natural for use as reference
- The key is simpler
- The key is unique
Alternate key
Alternate key is attribute of candidate key which is not chosen become primary key
Foreign key
Foreign key is any attribute subjecting to primary key at other tables. Foreign key will be happened in a relation which have one to many cardinality or many to many cardinality. Foreign key usually put at the table which direct to many cardinality.
External key
External key is lexical attribute or collection of lexical attribute which values always identify one object instance
ERD (ENTITY RELATIONSHIP DIAGRAM)
- ERD is a network model that use wording that kept in system according to abstract.
- Difference between DFD and ERD :
- DFD is a function network model that would carried out by the system
- ERD is a data network model that emphasized in structure and relationship data
ELEMENTS OF ERD
Entity
In ER Diagram entity described with long square form. Entity is something that there in real system also or abstract where does stored data or where does found data.
Relationship
in ER Diagram relationship can be described with a trapezoid. relationship is a natural connection that happen between entity. in general given name with verb base so that make easy to do the relation reading.
Relationship degree
Is a total entity that participate in one relationship. degree often worn in ERD.
Attribute
Is a character or characteristics from every entity and also relationship
Cardinality
Show optimum tupel that can be related with entity in another entity
Relationship degree
Unary relationship is Relationship model happen between the entity which coming from the same entity set.Binary relationship is relationship model happen between 2 entity. Ternary relationship between instance of 3 entity unilaterally.
Cardinality
There are 3 cardinality relation, that is :
- One-to-one : relationship degree one-to-one expressed by one event in first entity, only have one relation with one event in second entity and on the contrary.
- One-to-many or many-to-one : relationship degree one-to-many is equal many-to-one dependent from where that relationship seen. For one event in first entity can have many relationship with event in second entity, the other way, one event in second entity only have relationship with one event in first entity.
- Many-to-many : happen if each event in an entity having a lot of relationship with event in other entity
Example : cardinality



Tidak ada komentar:
Posting Komentar