Check out example codes for "mysql views". It will help you in understanding the concepts better.

Code Example 1

views in mysql

Code Example 2

CREATE VIEW customerPayments
AS 
SELECT 
    customerName, 
    checkNumber, 
    paymentDate, 
    amount
FROM
    customers
INNER JOIN
    payments USING (customerNumber);

Learn ReactJs, React Native from akashmittal.com