Bug #9863 | Views:Even if updatable_views_with_limit is set, update to view does not work. | ||
---|---|---|---|
Submitted: | 13 Apr 2005 8:23 | Modified: | 17 Apr 2005 18:07 |
Reporter: | Disha | Email Updates: | |
Status: | Not a Bug | Impact on me: | |
Category: | MySQL Server | Severity: | S3 (Non-critical) |
Version: | 5.0.3 | OS: | Any (All) |
Assigned to: | CPU Architecture: | Any |
[13 Apr 2005 8:23]
Disha
[13 Apr 2005 21:54]
Jorge del Conde
Tested w/5.0.4 from bk
[17 Apr 2005 13:57]
Oleksandr Byelkin
MySQL do not support views with LIMIT clause for update, because MERGE algorithm can't be aplicable in this case in general. Here is example: create view v1 as select * from t1 limit 23; select * from v1,t1 where t1.a=v1.a limit 2; i.e. LIMIT of subquery should be applied first (there are mistake in our documentation that such operation lead to unclown results, we will fix it soon). Above operaion can be allowed in theory but it is feature request.
[17 Apr 2005 18:07]
Sergei Golubchik
Thank you for taking the time to write to us, but this is not a bug. Please double-check the documentation available at http://www.mysql.com/documentation/ and the instructions on how to report a bug at http://bugs.mysql.com/how-to-report.php Additional info: updatable_views_with_limit does not allow updates to views with limit. It only allows to update a view (that does not contain a primary key in the underlying table) if UPDATE statement itself contains a LIMIT clause, not if a view contains LIMIT clause. As written in the manual: `updatable_views_with_limit' This variable controls whether updates can be made using a view that does not contain a primary key in the underlying table, if the update contains a `LIMIT' clause.