我可以就如何更新视图提供建议吗?这是我创建的视图.. 但是由于存储的功能它不能更新,对吗?加入查询是否也不能更新?和 if 函数?请帮助我..对不起我的英语。
CREATE
ALGORITHM = UNDEFINED
DEFINER = `root`@`localhost`
SQL SECURITY DEFINER
VIEW `view_attendance_dgv` AS
select
`tbl_stockholders`.`user_id` AS `user_id`,
`tbl_images`.`image_template` AS `Image Template`,
finger_name(`tbl_fingerprints`.`finger`) AS `Enrolled Finger`,
`tbl_users`.`last_name` AS `Last Name`,
`tbl_users`.`first_name` AS `First Name`,
`tbl_users`.`middle_name` AS `Middle Name`,
if((`tbl_stockholders`.`attendance_status` = 0),
'Absent',
'Present') AS `Attendance Status`,
if((`tbl_stockholders`.`voting_status` = 0),
'Not Voted',
'Voted') AS `Voting Status`
from
((((`tbl_stockholders`
join `tbl_shares` ON ((`tbl_stockholders`.`user_id` = `tbl_shares`.`user_id`)))
join `tbl_users` ON ((`tbl_stockholders`.`user_id` = `tbl_users`.`user_id`)))
join `tbl_images` ON ((`tbl_stockholders`.`user_id` = `tbl_images`.`user_id`)))
join `tbl_fingerprints` ON ((`tbl_stockholders`.`user_id` = `tbl_fingerprints`.`user_id`)))
order by `tbl_stockholders`.`user_id`