Course Solutions Uncategorized (Solved) : Mysql Creating Views Check Option Possible Perform Referential Integrity Constraints Use V Q38012156 . . . .

(Solved) : Mysql Creating Views Check Option Possible Perform Referential Integrity Constraints Use V Q38012156 . . . .

 

(MYSQL)CREATING VIEWS WITH CHECK OPTION

It is possible to perform referential integrity constraintsthrough the use of a view so that database constraints can beenforced. The following view DISPLAYS employees who work in ThemePark FR1001 using the WITH CHECK OPTION clause. This clause ensuresthat INSERTs and UPDATEs cannot be performed on any rows that theview has not selected.

CREATE VIEW EMPFR AS

SELECT *

FROM    EMPLOYEE

WHERE PARK_CODE = ‘FR1001’

WITH CHECK OPTION;

So for example if employee ‘Emma Caulderdale’ was to leave thepark and move to park ‘UK3452’, we would want to update herinformation with the following query:

UPDATE EMPFR

SET PARK_CODE = ‘UK3452’

OR

PayPal Gateway not configured

OR

PayPal Gateway not configured

Leave a Reply

Your email address will not be published. Required fields are marked *

Related Post