Details
-
Type:
Bug
-
Status: Closed (View Workflow)
-
Priority:
Minor
-
Resolution: Fixed
-
Affects Version/s: 10.2.2
-
Fix Version/s: 10.2.3
-
Component/s: Optimizer - Window functions, Views
-
Labels:None
-
Environment:Windows
Description
In the MariaDB 10.2 beta, creating a view containing a simple window function seems to work, but attempting to use the view fails with
SQL Error (1356): View 'test.rowseq' references invalid table(s) or column(s) or function(s) or definer/invoker of view lack rights to use them
Here's a simple example
create or replace view rowseq as
select ROW_NUMBER() OVER (ORDER BY seq) ROWNUM, seq
from (select 1 as seq union all select 10 union all select 100 union all select 1000 )a;
select * from rowseq;
boom.