Module Overview
This module focuses on working with views and stored functions in MySQL.
Learners will explore how to create, update, rename and remove database views, along with the fundamentals of stored functions.
These concepts help participants organise database information, simplify frequently used queries and develop reusable database logic.
Views and stored functions can support consistent data access, reporting and routine database operations.
What Will Be Covered
11.1 CREATE VIEW
Understanding the purpose of views in MySQL.
Creating views using the CREATE VIEW statement.
Defining views based on SELECT queries.
Selecting specific columns and records for a view.
Using views to simplify access to frequently required business information.
Creating reusable views for reporting and data presentation.
11.2 DROP VIEW
Understanding when a database view needs to be removed.
Using the DROP VIEW statement.
Identifying existing views before removing them.
Removing views that are no longer required.
Managing database objects and maintaining an organised database environment.
11.3 UPDATE VIEW
Understanding how views can be updated in MySQL.
Modifying data through updatable views.
Understanding the relationship between views and their underlying tables.
Identifying the conditions under which a view supports data updates.
Managing business records through suitable database views.
11.4 RENAME VIEW
Understanding the purpose of renaming database views.
Changing view names to improve identification.
Using the RENAME TABLE statement to rename a view in MySQL.
Managing view names as database requirements change.
Maintaining clear and consistent database object naming conventions.
11.5 Stored Functions
Understanding the purpose of stored functions in MySQL.
Exploring how stored functions work within a database.
Understanding function parameters and return values.
Creating reusable functions for database calculations and operations.
Using stored functions to simplify frequently performed database tasks.
Applying stored functions to support consistent business calculations and data processing.
Skills You Will Gain
Creating database views using SELECT queries.
Removing unnecessary views.
Understanding and updating data through updatable views.
Renaming database views.
Understanding the structure and purpose of stored functions.
Working with function parameters and return values.
Developing reusable database logic.
Organising database objects for reporting and data management.
Learning Outcomes
By the end of this module, learners will be able to:
Create database views to simplify access to frequently used business information and reporting datasets.
Manage and remove unnecessary views to maintain organised database environments.
Update records through suitable views while understanding their relationship with underlying tables.
Rename database views to maintain clear and consistent database object structures.
Develop stored functions for reusable business calculations and database operations.
Apply stored functions to standardise frequently performed data processing tasks.
Use views and stored functions to improve database organisation, query reuse and reporting efficiency.
Certification Alignment
This module develops MySQL database object management and stored function concepts that support the Oracle MySQL Database Administrator certification pathway. The topics help learners understand how views and reusable database logic can be used to manage and access information efficiently.
Continue to the Next Module
Continue to Module 12: Advanced MySQL Features to learn about transactions, indexes, date functions, ranking functions, window functions, aliases, wildcards, ENUM usage, triggers and SQL comments.
Still need help?
Contact us