[MDEV-10102] Disallow CREATE VIEW .. PROCEDURE ANALYSE() syntactically Created: 2016-05-23  Updated: 2016-05-25  Resolved: 2016-05-23

Status: Closed
Project: MariaDB Server
Component/s: Parser
Fix Version/s: 10.2.1

Type: Task Priority: Major
Reporter: Alexander Barkov Assignee: Alexander Barkov
Resolution: Fixed Votes: 0
Labels: None

Issue Links:
Blocks
blocks MDEV-8909 union parser cleanup Closed

 Description   

A query like this:

CREATE VIEW v1 AS SELECT 1 FROM t1 PROCEDURE ANALYSE();

is currently disallowed by this code:

view_select:
  ...
   lex->parsing_options.allows_select_procedure= FALSE;
   ;
 
...
 
procedure_clause:
  ...
  if (! lex->parsing_options.allows_select_procedure)
  {
    my_error(ER_VIEW_SELECT_CLAUSE, MYF(0), "PROCEDURE");
    MYSQL_YYABORT;
  }

It should be disallowed syntactically.


Generated at Thu Feb 08 07:39:41 UTC 2024 using Jira 8.20.16#820016-sha1:9d11dbea5f4be3d4cc21f03a88dd11d8c8687422.