Advanced Data Base Note
Advanced Data Base Note
By HABTESH
.• DBMS contains information about a particular enterprise
• Collection of interrelated data
• Set of programs to access the data
• An environment that is both convenient and efficient to use
• Database Applications:
• Banking: all transactions
• Airlines: reservations, schedules
• Universities: registration, grades
• Sales: customers, products, purchases
• Online retailers: order tracking, customized recommendations
• Manufacturing: production, inventory, orders, supply chain
• Human resources: employee records, salaries, tax deductions
• Databases touch all aspects of our lives
Purpose of Database Systems
Data redundancy and inconsistency
• Multiple file formats, duplication of information in different files
• Difficulty in accessing data
• Need to write a new program to carry out each new task
• Data isolation — multiple files and formats
• Integrity problems
. • Atomicity of updates
• Failures may leave database in an inconsistent state with partial updates carried out
• Concurrent access by multiple users
• Concurrent accessed needed for performance
• Uncontrolled concurrent accesses can lead to inconsistencies
• Security problems
• Hard to provide user access to some, but not all, data
• Database systems offer solutions to all the above problems
Levels of Abstraction
• Physical level: describes how a record (e.g., customer) is stored.
• Logical level: describes data stored in database, and the relationships among the data.
• View level: application programs hide details of data types. Views can also hide information (such as an
employee’s salary) for security purposes.
Instances and Schemas
Schema – the logical structure of the database
• Analogous to type information of a variable in a program
• Physical schema: database design at the physical level
• Logical schema: database design at the logical level
• Instance – the actual content of the database at a particular point in time
• Analogous to the value of a variable
.• Physical Data Independence – the ability to modify the physical schema without changing the logical schema
• Applications depend on the logical schema
• In general, the interfaces between the various levels and components should be well defined so that changes
in some parts do not seriously influence others
Data Models
• A collection of tools for describing
• Data
• Data relationships
• Data semantics
• Data constraints
• Relational model
• Entity-Relationship data model (mainly for database design)
• Object-based data models (Object-oriented and Object-relational)
• Semi structured data model (XML)
• Other older models:
• Network model
• Hierarchical model
Data Manipulation Language (DML)
• Language for accessing and manipulating the data organized by the appropriate data model
• DML also known as query language
• Two classes of languages
• Procedural – user specifies what data is required and how to get those data
• Declarative (nonprocedural) – user specifies what data is required without specifying how to get those data
• SQL is the most widely used query language
.• Data Definition Language (DDL)
• Specification notation for defining the database schema
Example: create table account (
account-number char(10),
balance integer)
• DDL compiler generates a set of tables stored in a data dictionary
• Data dictionary contains metadata (i.e., data about data)
• Database schema
• Data storage and definition language
• Specifies the storage structure and access methods used
• Integrity constraints
• Domain constraints
• Referential integrity (references constraint in SQL)
• Assertions
• Authorization
• Application programs generally access databases through one of
• Language extensions to allow embedded SQL
• Application program interface (e.g., ODBC/JDBC) which allow SQL queries to be sent to a
database
.Database Design
The process of designing the general structure of the database:
Logical Design – Deciding on the database schema. Database design requires that we find a “good” collection
of relation schemas.
Physical Design – Deciding on the physical layout of the database.
The Entity-Relationship Model
• Models an enterprise as a collection of entities and relationships
• Entity: a “thing” or “object” in the enterprise that is distinguishable from other objects
• Described by a set of attributes
• Relationship: an association among several entities
• Represented diagrammatically by an entity-relationship diagram
Storage Management
• Storage manager is a program module that provides the interface between the low-level data stored in the
database and the application programs and queries submitted to the system.
• The storage manager is responsible to the following tasks:
• Interaction with the file manager
• Efficient storing, retrieving and updating of data
• Issues:
• Storage access
• File organization
• Indexing and hashing
.Transaction Management
• A transaction is a collection of operations that performs a single logical function in a database application
• Transaction-management component ensures that the database remains in a consistent (correct) state despite
system failures (e.g., power failures and operating system crashes) and transaction failures.
• Concurrency-control manager controls the interaction among the concurrent transactions, to ensure the
consistency of the database.
Database Architecture
The architecture of a database systems is greatly influenced by
the underlying computer system on which the database is running:
• Centralized
• Client-server
• Parallel (multi-processor)
• Distributed
Database Users
Users are differentiated by the way they expect to interact with
the system
• Application programmers – interact with system through DML calls
• Sophisticated users – form requests in a database query language
• Specialized users – write specialized database applications that do not fit into the traditional data processing
framework
• Naïve users – invoke one of the permanent application programs that have been written previously
• Examples, people accessing database over the web, bank tellers, clerical staff
.Database Administrator
• Coordinates all the activities of the database system; the database administrator has a good understanding of
the enterprise’s information resources and needs.
• Database administrator's duties include:
• Schema definition
• Storage structure and access method definition
• Schema and physical organization modification
• Granting user authority to access the database
• Specifying integrity constraints
• Acting as liaison with users
• Monitoring performance and responding to changes in requirements
Relational Model
Basic Structure
Formally, given sets D1, D2, …. Dn a relation r is a subset of
D1 x D2 x … x Dn
Thus, a relation is a set of n-tuples (a1, a2, …, an) where each ai Di
Then r = { (Jones, Main, Harrison),
(Smith, North, Rye),
(Curry, North, Rye),
(Lindsay, Park, Pittsfield) }
is a relation over
customer_name x customer_street x customer_city
.Attribute Types
• Each attribute of a relation has a name
• The set of allowed values for each attribute is called the domain of the attribute
• Attribute values are (normally) required to be atomic; that is, indivisible
• Note: multivalued attribute values are not atomic
• Note: composite attribute values are not atomic
• The special value null is a member of every domain
• The null value causes complications in the definition of many operations
• We shall ignore the effect of null values for now.
Relation Schema
• A1, A2, …, An are attributes
• R = (A1, A2, …, An ) is a relation schema
Example:
Customer_schema = (customer_name, customer_street, customer_city)
Where p is a formula in propositional calculus consisting of terms connected by : (and), (or), (not)
Each term is one of:
<attribute> op <attribute> or <constant>
where op is one of: =, , >, . <.
• Example of selection:
branch_name=“Perryridge”(account)
.Project Operation
• Notation:
where A1, A2 are attribute names and r is a relation name.
• The result is defined as the relation of k columns obtained by erasing the columns that are not listed
• Duplicate rows removed from result, since relations are sets
• Example: To eliminate the branch_name attribute of account
• Assume that attributes of r(R) and s(S) are disjoint. (That is, R S = ).
• If attributes of r(R) and s(S) are not disjoint, then renaming must be used.
Composition of Operations
• Can build expressions using multiple operations
• Example: A=C(r x s)
.Rename Operation
• Allows us to name, and therefore to refer to, the results of relational-algebra expressions.
• Allows us to refer to a relation by more than one name.
• Example:
x (E)
returns the expression E under the name X
• If a relational-algebra expression E has arity n, then
returns the result of expression E under the name X, and with the
attributes renamed to A1 , A2 , …., An .
Set-Intersection Operation
• Notation: r s
• Defined as:
• r s = { t | t r and t s }
• Assume:
• r, s have the same arity
• attributes of r and s are compatible
.Natural-Join Operation
Notation: r s
• Let r and s be relations on schemas R and S respectively.
Then, r s is a relation on schema R S obtained as follows:
• Consider each pair of tuples tr from r and ts from s.
• If tr and ts have the same value on each of the attributes in R S, add a tuple t to the result, where
• t has the same value as tr on r
• t has the same value as ts on s
• Example:
R = (A, B, C, D)
S = (E, B, D)
• Result schema = (A, B, C, D, E)
• r s is defined as:
r.A, r.B, r.C, r.D, s.E ( r.B = s.B r.D = s.D (r x s))
Division Operation
• Notation:
• Suited to queries that include the phrase “for all”.
• Let r and s be relations on schemas R and S respectively where
• R = (A1, …, Am , B1, …, Bn )
• S = (B1, …, Bn)
The result of r s is a relation on schema
R – S = (A1, …, Am)
r s = { t | t R-S (r) u s ( tu r ) }
Where tu means the concatenation of tuples t and u to produce a single tuple
.Division Operation (Cont.)
• Property
• Let q = r s
• Then q is the largest relation satisfying q x s r
• Definition in terms of the basic algebra operation Assignment Operation example
Let r(R) and s(S) be relations, and let S R Example: Write r s as temp1 R-S (r )
r s = R-S (r ) – R-S ( ( R-S (r ) x s ) – R-S,S(r )) temp2 R-S ((temp1 x s ) – R-S,S (r ))
result = temp1 – temp2
To see why
• R-S,S (r) simply reorders attributes of r
• R-S ( R-S (r ) x s ) – R-S,S(r) ) gives those tuples t in
• R-S (r ) such that for some tuple u s, tu r.
Assignment Operation
• The assignment operation () provides a convenient way to express complex queries.
• Write query as a sequential program consisting of
• a series of assignments
• followed by an expression whose value is displayed as a result of the query.
• Assignment must always be made to a temporary relation variable.
.Extended Relational-Algebra-Operations
• Aggregate Functions
• Outer Join
Aggregate Functions and Operations
• Aggregation function takes a collection of values and returns a single value as a result.
avg: average value
min: minimum value
max: maximum value
sum: sum of values
count: number of values
• Aggregate operation in relational algebra
E is any relational-algebra expression
• G1, G2 …, Gn is a list of attributes on which to group (can be empty)
• Each Fi is an aggregate function
• Each Ai is an attribute name
• Result of aggregation does not have a name
• Can use rename operation to give it a name
• For convenience, we permit renaming as part of aggregate operation
.Outer Join
• An extension of the join operation that avoids loss of information.
• Computes the join and then adds tuples form one relation that does not match tuples in the other relation to the
result of the join.
• Uses null values:
• null signifies that the value is unknown or does not exist
• All comparisons involving null are (roughly speaking) false by definition.
• We shall study precise meaning of comparisons with nulls later
Null Values
. It is possible for tuples to have a null value, denoted by null, for some of their attributes
. null signifies an unknown value or that a value does not exist.
. The result of any arithmetic expression involving null is null.
. Aggregate functions simply ignore null values (as in SQL)
. For duplicate elimination and grouping, null is treated like any other value, and two nulls are assumed to be the
same (as in SQL)
Modification of the Database
• The content of the database may be modified using the following operations:
• Deletion
• Insertion
• Updating
• All these operations are expressed using the assignment operator.
.Deletion
• A delete request is expressed similarly to a query, except instead of displaying tuples to the user, the selected tuples are removed from
the database.
• Can delete only whole tuples; cannot delete values on only particular attributes
• A deletion is expressed in relational algebra by:
rr–E
where r is a relation and E is a relational algebra query.
Insertion
• To insert data into a relation, we either:
• specify a tuple to be inserted
• write a query whose result is a set of tuples to be inserted
• in relational algebra, an insertion is expressed by:
r r E
where r is a relation and E is a relational algebra expression.
• The insertion of a single tuple is expressed by letting E be a constant relation containing one tuple.
Updating
• A mechanism to change a value in a tuple without charging all values in the tuple
• Use the generalized projection operator to do this task
• Each Fi is either
• the I th attribute of r, if the I th attribute is not updated, or,
• if the attribute is to be updated Fi is an expression, involving only constants and the attributes of r, which gives the new value for
the attribute
.Why database standards?
• Having a standard for a particular type of database system is very important because of following reasons:
1. It provides support for portability of database applications. Portability is generally defined as the
capability to execute a particular application program on different systems with minimal modifications
to the program itself.
2. It helps to achieve interoperability. It generally refers to the ability of an application to access multiple
distinct systems. In terms of database systems, this means that same application program may access
some data stored under one ODBMS package, and other data store under another package.
3. It allow customers to compare commercial products more easily by determining which parts of the
standards are good
ODMG
ODMG ( Object Data Management Group) is a consortium of ODBMS vendors.
• It proposed a standard for ODBMS in 1993 as ODMG 1.0, in 1995 ODMG 2.0 and in 2000 ODMG 3.0.
• The ODMG 3.0 standard is made up of several parts:
‣ Object model
‣ Object definition language (ODL)
‣ Object query language (OQL)
.The Object Model
The Object Model specifies the constructs that are supported by an ODMS:
• The basic modeling primitives are the objectand the literal. Each object has a unique identifier.
• The state of an object is defined by the values it carries for a set of properties. These properties can be
attributes of the object itself or relationships between the object and one or more other objects.
• The specification defines the aspects that are visible to users of the type: the operations that can be invoked on
its instances, the properties, or state variables, whose values can be accessed, and any exceptions that can be
raised by its operations.
• The main difference between the two is that an object has That is, numbers, characters, Boolean values
both an object identifier and a state where as a literal has a etc. are examples of atomic literal types.
value but no identifier.
• Structured Literals
Literals • Correspond to the values constructed by
tuple constructor. They include: date, time,
• Literals do not have their own identifiers and cannot stand
interval and timestamp as built-in structures
alone as objects; they are embedded in objects and cannot
and any other user defined structures.
be individually referenced.
• Collection Literals
• The value of a literal cannot change.
• The ODMG Object Model supports collection
• The Object Model supports the following three literals of the following types: set<t> ,
literal types: bag<t>, list<t>, array<t>,
‣ atomic literal dictionary<t, v>, where t is a type of
‣ collection literal objects or values in the collection
‣ structured literal
.Objects Object Names
• In addition to being assigned an object identifier by
• An object has four characteristics the ODMS, an object may be given one or more
names that are meaningful to the programmer or
1. Identifier: unique system-wide identifier end user.
. The application can refer at its convenience to an
2. Name: unique within a particular database and/or object by name; the ODMS applies the mapping
program; it is optional function to determine the object identifier that
locates the desired object.
3. Lifetime: persistent vs. transient
Object Lifetime
4. Structure: specifies how object is constructed by the
• The lifetime of an object determines how the
type constructor and whether it is an atomic object or memory and storage allocated to the object are
collection object. managed.
Object Identifiers • Two lifetimes are supported in the Object Model:
• An object can always be distinguished from all other objects ‣ transient
within its storage domain by using object identifier. ‣ persistent
• An object retains the same object identifier for its entire • An object whose lifetime is transient, is allocated
lifetime. Thus, the value of an object’s identifier will never memory that is managed by the programming
language runtime system. When the process
change.
terminates, the memory is de-allocated.
• The object remains the same object, even if its attribute
values or relationships change. • An object whose lifetime is persistent, is allocated
memory and storage managed by the ODMS
• Object identifiers are generated by the ODMS, not by runtime system. These objects continue to exist
applications. after the procedure or process that creates them
.Object Structure
• The structure of object can be either atomic or not, in which case the object is composed of other objects.
• An atomic object type is user-defined. There are no built-in atomic object types included in the ODMG Object
Model.
• In the ODMG Object Model, instances of collection objects are composed of distinct elements, each of which can be
an instance of an atomic type, another collection, or a literal type.
Collection Objects
An important distinguishing characteristic of a collection is that all the elements of the collection must be of the same
type.
They are either all the same atomic type, or all the same type of collection, or all the same type of literal.
• The collections supported by the ODMG Object Model include:
‣ Set<t>: A Set object is an unordered collection of elements, with no duplicates allowed.
‣ Bag<t>: A Bag object is an unordered collection of elements that may contain duplicates.
‣ List<t>: A List object is an ordered collection of elements.
‣ Array<t> : An Array object is a dynamically sized, ordered collection of elements that can be located by position.
‣ Dictionary<t,v>: A Dictionary object is an unordered sequence of key-value pairs with no
• duplicate keys.
• Each of these is a type generator, parameterized by the type shown within the angle brackets.
.Structured Object ODMG Interface
• All structured objects support the Object ODL • An interface is a specification of the
interface. abstract behavior of an object type.
• The ODMG Object Model defines the following • It is a signature for the persistent object.
structured objects: Interface tells external world how to interact
with an object. That is, an interface describes the
‣ Date
interface of types of objects: their visible
‣ Interval
attributes, relationships and operations.
‣ Time
‣ Timestamp • Interfaces are non-instantiable but they serve to
define operations that can be inherited by the
‣ User defined structured objects
user-defined objects for a particular application.
• Example: user defined structured object
• struct Address { • State properties of an interface
(i.e., its attributes and
• string dorm_name; relationships) cannot be
inherited.
• string
};
room_no; Object Interface
• In the object model, all the objects inherit the
basic interface
• attribute
Address • Object.
dorm_ad
dress; • Typical interface of an object of ODMG showing
operation declarations is given below:
.Collection Interface
• Collection interface: Any collection object inherits the basic collection interface.
• This interface provides following operations: cardinality() // returns no. of objects in the
collection
• is_empty() // returns true if collection is empty
• insert_element() // inserts an element from the collection
• remove_element() // removes an element from the collection
• contains_element()// returns true if an element is in the collection
• create_iterator() // creates an iterator object for the collection
• object
Interfaces and Behavior Inheritance
• In ODMG, two types of inheritance relationships exist.
• An interface is a specification of the abstract behavior of an object type, which specifies the operation
signatures.
• Interfaces are noninstantiable – that is, one cannot create objects that correspond to an interface definition.
• They are mainly used to specify abstract operations that can be inherited by classes or by other interfaces.
• Subtyping pertains to the inheritance of behavior only and it is specified by colon ( : ).
.Extents
• The extent of a type is the set of all instances of the type within a particular ODMS.
• If an object is an instance of type A, then it will necessarily be a member of the extent of A.
• If type A is a subtype of type B, then the extent of A is a subset of the extent of B.
• The ODMS schema designer can decide whether the system should automatically maintain the extent of
each type.
• In some cases, the individual instances of a type in the extent can be uniquely identified by the values they
carry for some property or set of properties. These identifying properties are called keys.
• The scope of uniqueness is the extent of the type; thus, a type must have an extent to have a key.
PL/SQL
• PL/SQL stands for Procedural Language extension of SQL.
• The purpose of PL/SQL is to combine database language and procedural programming language.
. PL/SQL is a combination of SQL along with the procedural features of programming languages.
• Following are notable facts about PL/SQL:
• PL/SQL is a completely portable, high-performance transaction-processing language.
• PL/SQL provides a built-in interpreted and OS independent programming environment.
• PL/SQL can also directly be called from the command-line SQL*Plus interface.
• Direct call can also be made from external programming language calls to database.
.PL/SQL PL/SQL Block Structure
Features
Tight integration with SQL
Supports data types, functions, etc.
Increased performance
A block of statements sent as a single statement
Increased productivity
Same techniques can be used with most Oracle
products
Portability
Works on any Oracle platform
Tighter security
Users may access database objects without granted
privileges PL/SQL Programs
Output statement in PL/SQL • Declaration section (optional)
DBMS_OUTPUT.PUT_LINE (); • Any needed variables declared here
Input statement in PL/SQL • Executable or begin section
&variable name • Program code such as statements to retrieve or
manipulate data in a table
Assignment operator in PL/SQL • Exception section (optional)
:= • Error traps can catch situations which might
Concatenation operator in PL/SQL ordinarily crash the program
||
.PL/SQL Variables
Variables are local to the code block control Structures
• In addition to SQL commands, PL/SQL
Names can be up to 30 characters long and must begin with a character
can also process data using flow of
Declaration is like that in a table statements. The flow of control
statements are classified into the
Name then data type the semi-colon
following categories.
Can be initialized using := operator in the declaration • Conditional control -
Can be changed with := in the begin section Branching
Can use constraints • Iterative control - looping
Variables can be composite or collection types • Sequential control
Multiple values of different or same type • Conditional control in PL/SQL
IF-THEN-ELSE STATEMENT:
Syntax:
h
NESTED IF statements
h Syntax:
.SELECTION IN PL/SQL(Sequential Controls) SIMPLE LOOP
SEARCHED CASE Syntax:
LOOP
Syntax: statement1;
EXIT [ WHEN Condition];
CASE END LOOP;
For loop
WHEN searchcondition1 THEN statement1;
• The FOR LOOP statement runs one or more statements
WHEN searchcondition2 THEN statement2; while the loop index is in a specified range. The statement
has this structure:
ELSE • Syntax:
Statementn; FOR counter IN [REVERSE]
lower_bound..upper_bound
END CASE; LOOP
LOOP Statements Statements
END LOOP;
• Loop statements run the same statements with
a series of different values. The loop While loop
statements are: The WHILE LOOP statement runs one or more statements
while a condition is true. It has this structure:
• Simple LOOP
Syntax:
• FOR LOOP WHILE condition LOOP
• WHILE LOOP statements
END LOOP;
• The statements that exit a loop are: EXIT Statement
• EXIT The EXIT statement exits the current iteration of a loop
conditionally or unconditionally and transfers control to the
• EXIT WHEN end of either the current loop or an enclosing labeled loop.
.Functions and Procedures • Modes:
• Up until now, our code was in an anonymous block • IN: procedure must be called with a value for the
• It was run immediately parameter. Value cannot be changed
• OUT: procedure must be called with a variable
• It is useful to put code in a function or procedure so for the parameter. Changes to the parameter are
it can be called several times
seen by the user (i.e., call by reference)
• Once we create a procedure or function in a • IN OUT: value can be sent, and changes to the
Database, it will remain until deleted (like a table). parameter are seen by the user
Difference between Procedure and function is:- • Default Mode is: IN
Procedure
Creating a Function
No return.
Almost exactly like creating a procedure, but you
Function: supply a return type
Returns a value • CREATE [OR REPLACE] FUNCTION
Creating Procedures • function_name
• CREATE [OR REPLACE] PROCEDURE • [(parameter1 [mode1] datatype1,
procedure_name
• parameter2 [mode2] datatype2,
• [(parameter1 [mode1] datatype1,
• . . .)]
• parameter2 [mode2] datatype2,
• RETURN datatype
• . . .)]
• IS|AS
• IS|AS
• PL/SQL Block;
• PL/SQL Block;
.Triggers Syntax to create trigger
• A trigger is a pl/sql block structure which is fired
when a DML statements like Insert, Delete, Update is
executed on a database table.
• A trigger is triggered automatically when an
associated DML statement is executed.
• Associated with a particular table.
• Automatically executed when a particular event
occurs
• Insert
• Update
• Delete
• Others Triggers Timing
Triggers vs. Procedures • A triggers timing has to be specified first
• Procedures are explicitly executed by a user or • Before (most common)
application • Trigger should be fired before the operation
• Triggers are implicitly executed (fired) when the • i.e. before an insert
triggering event occurs • After
• Triggers should not be used as a lazy way to invoke a • Trigger should be fired after the operation
procedure as they are fired every time the event • i.e. after a delete is performed
occurs
.Trigger Events Database Events
• Three types of events are available • Server Errors
• DML events • Users Log On or Off
• DDL events
• Database Started or Stopped
• Database events
Database security
DML Events
Creating Users
• Changes to data in a table
• Insert The DBA creates users by using the CREATE USER
• Update statement.
• Delete • CREATE USER user
3. Availability
.Secrecy What is a Threat?
• It is protecting the database from unauthorized users. Threat: it can be defined as a hostile agent that,
• Ensures that users are allowed to do the things they are trying to either casually or by using:
do.
specialized technique
• For examples,
• The employees should not see the salaries of their modify
managers. delete the information managed by a DBMS
Integrity
Two Kinds of Threat
• Checking the database from modified by users.
1. Non-fraudulent Threat
• Ensures that what users are trying to do is correct. • Natural or accidental disasters.
• For examples, • Errors or bugs in hardware or software.
• An employee should be able to modify his or her own • Human errors.
information. 2. fraudulent Threat
Availability • Authorized users
• Those who abuse their privileges and
• Authorized users should be able to access data for Legal authority.
purposes as necessary • Hostile agents
• Those improper users (outsider or
• For examples, insiders).
• Payment orders regarding taxes should be made on time by • who attack the software and/or
hardware system, or read or write
the tax law.
.Database Protection Requirements
1. Protection from Improper Access
2. Protection from Inference
3. Integrity of the Database
4. User Authentication
5. Management and Protection of Sensitive Data
Type of Security Controls
1. Flow Control
• Flow controls regulate the distribution (flow) of information among accessible objects.
• A flow between object X and object Y occurs when a statement reads values from X and writes values into Y.
• Copying data from X to Y is the typical example of information flow.
2. Inference Control
Inference control aim at protecting data from indirect detection.
Information inference occurs when: a set X of data items to be read by a user can be used to get the set Y of data.
An inference channel is a channel where users can find an item X and then use X to get Y as
Y = f(X).
.Main Inference Channels
Indirect Access:
• Occurs when a user derives:
• unauthorized data (say Y)
• from an authorized source (say X).
Correlated Data:
• If visible data X is semantically connected to invisible data Y.
3. Access Control
• Access control in information system are responsible for ensuring that all direct accesses to the
system objects occur base on modes and rules fixed by protection policies.
• An access control system includes :
• subjects (users, processes).
• Who access objects (data, programs).
• Through operations (‘read’, ‘write’, ‘run’).
.
Good luck