)))
MYSQL_YYABORT;
(yyval.sp_assignment_lex_list)->push_back((yyvsp[0].assignment_lex), thd->mem_root);
}
#line 30477 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 395:
#line 3822 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.sp_assignment_lex_list)= (yyvsp[-2].sp_assignment_lex_list);
(yyval.sp_assignment_lex_list)->push_back((yyvsp[0].assignment_lex), thd->mem_root);
}
#line 30488 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 396:
#line 3829 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.sp_assignment_lex_list)= NULL; }
#line 30496 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 397:
#line 3830 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.sp_assignment_lex_list)= (yyvsp[-1].sp_assignment_lex_list); }
#line 30504 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 401:
#line 3841 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->sp_open_cursor(thd, &(yyvsp[-1].ident_sys), (yyvsp[0].sp_assignment_lex_list))))
MYSQL_YYABORT;
}
#line 30515 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 402:
#line 3849 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->sp_add_cfetch(thd, &(yyvsp[-1].ident_sys))))
MYSQL_YYABORT;
}
#line 30526 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 403:
#line 3854 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->sp_add_cfetch(thd, &(yyvsp[-1].ident_sys))))
MYSQL_YYABORT;
}
#line 30537 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 404:
#line 3859 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->sp_add_cfetch(thd, &(yyvsp[-1].ident_sys))))
MYSQL_YYABORT;
}
#line 30548 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 405:
#line 3866 "/home/buildbot/git/sql/sql_yacc.yy"
{ }
#line 30556 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 406:
#line 3868 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->sp_add_agg_cfetch()))
MYSQL_YYABORT;
}
#line 30567 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 407:
#line 3876 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
sp_head *sp= lex->sphead;
uint offset;
sp_instr_cclose *i;
if (unlikely(!lex->spcont->find_cursor(&(yyvsp[0].ident_sys), &offset, false)))
my_yyabort_error((ER_SP_CURSOR_MISMATCH, MYF(0), (yyvsp[0].ident_sys).str));
i= new (thd->mem_root)
sp_instr_cclose(sp->instructions(), lex->spcont, offset);
if (unlikely(i == NULL) ||
unlikely(sp->add_instr(i)))
MYSQL_YYABORT;
}
#line 30588 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 408:
#line 3894 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
sp_head *sp= lex->sphead;
sp_pcontext *spc= lex->spcont;
sp_variable *spv= likely(spc != NULL)
? spc->find_variable(&(yyvsp[0].ident_sys), false)
: NULL;
if (unlikely(!spv))
my_yyabort_error((ER_SP_UNDECLARED_VAR, MYF(0), (yyvsp[0].ident_sys).str));
/* An SP local variable */
sp_instr_cfetch *i= (sp_instr_cfetch *)sp->last_instruction();
i->add_to_varlist(spv);
}
#line 30610 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 409:
#line 3910 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
sp_head *sp= lex->sphead;
sp_pcontext *spc= lex->spcont;
sp_variable *spv= likely(spc != NULL)
? spc->find_variable(&(yyvsp[0].ident_sys), false)
: NULL;
if (unlikely(!spv))
my_yyabort_error((ER_SP_UNDECLARED_VAR, MYF(0), (yyvsp[0].ident_sys).str));
/* An SP local variable */
sp_instr_cfetch *i= (sp_instr_cfetch *)sp->last_instruction();
i->add_to_varlist(spv);
}
#line 30632 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 410:
#line 3929 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely((yyvsp[-1].expr_lex)->sp_if_expr(thd)))
MYSQL_YYABORT;
}
#line 30643 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 411:
#line 3934 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely((yyvsp[-3].expr_lex)->sp_if_after_statements(thd)))
MYSQL_YYABORT;
}
#line 30654 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 412:
#line 3939 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
lex->sphead->backpatch(lex->spcont->pop_label());
}
#line 30666 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 417:
#line 3955 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->maybe_start_compound_statement(thd)))
MYSQL_YYABORT;
/**
An example of the CASE statement in use is
CREATE PROCEDURE proc_19194_simple(i int)
BEGIN
DECLARE str CHAR(10);
CASE i
WHEN 1 THEN SET str="1";
WHEN 2 THEN SET str="2";
WHEN 3 THEN SET str="3";
ELSE SET str="unknown";
END CASE;
SELECT str;
END
The actions are used to generate the following code:
SHOW PROCEDURE CODE proc_19194_simple;
Pos Instruction
0 set str@1 NULL
1 set_case_expr (12) 0 i@0
2 jump_if_not 5(12) (case_expr@0 = 1)
3 set str@1 _latin1'1'
4 jump 12
5 jump_if_not 8(12) (case_expr@0 = 2)
6 set str@1 _latin1'2'
7 jump 12
8 jump_if_not 11(12) (case_expr@0 = 3)
9 set str@1 _latin1'3'
10 jump 12
11 set str@1 _latin1'unknown'
12 stmt 0 "SELECT str"
*/
Lex->sphead->new_cont_backpatch(NULL);
/*
BACKPATCH: Creating target label for the jump to after END CASE
(instruction 12 in the example)
*/
Lex->spcont->push_label(thd, &empty_clex_str, Lex->sphead->instructions());
}
#line 30722 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 418:
#line 4008 "/home/buildbot/git/sql/sql_yacc.yy"
{
/*
BACKPATCH: Resolving forward jump from
"case_stmt_action_then" to after END CASE
(jump from instruction 4 to 12, 7 to 12 ... in the example)
*/
Lex->sphead->backpatch(Lex->spcont->pop_label());
if ((yyvsp[-3].num))
Lex->spcont->pop_case_expr_id();
Lex->sphead->do_cont_backpatch();
}
#line 30742 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 419:
#line 4025 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely((yyvsp[0].expr_lex)->case_stmt_action_expr()))
MYSQL_YYABORT;
}
#line 30753 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 420:
#line 4030 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.num)= 1; }
#line 30761 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 421:
#line 4032 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.num)= 0; }
#line 30769 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 426:
#line 4047 "/home/buildbot/git/sql/sql_yacc.yy"
{
/* Simple case: = */
if (unlikely((yyvsp[0].expr_lex)->case_stmt_action_when(true)))
MYSQL_YYABORT;
}
#line 30781 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 427:
#line 4054 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->case_stmt_action_then()))
MYSQL_YYABORT;
}
#line 30792 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 428:
#line 4062 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely((yyvsp[0].expr_lex)->case_stmt_action_when(false)))
MYSQL_YYABORT;
}
#line 30803 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 429:
#line 4068 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->case_stmt_action_then()))
MYSQL_YYABORT;
}
#line 30814 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 430:
#line 4076 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
sp_head *sp= lex->sphead;
uint ip= sp->instructions();
sp_instr_error *i= new (thd->mem_root)
sp_instr_error(ip, lex->spcont, ER_SP_CASE_NOT_FOUND);
if (unlikely(i == NULL) ||
unlikely(sp->add_instr(i)))
MYSQL_YYABORT;
}
#line 30831 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 432:
#line 4090 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.lex_str)= null_clex_str; }
#line 30839 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 433:
#line 4091 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.lex_str)= (yyvsp[0].ident_sys); }
#line 30847 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 434:
#line 4096 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.num)= 1; }
#line 30855 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 435:
#line 4097 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.num)= -1; }
#line 30863 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 436:
#line 4102 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->sp_for_loop_declarations(thd, &(yyval.for_loop), &(yyvsp[-1].ident_sys), (yyvsp[0].for_loop_bounds))))
MYSQL_YYABORT;
}
#line 30874 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 437:
#line 4111 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.for_loop_bounds)= Lex_for_loop_bounds_intrange((yyvsp[-3].num), (yyvsp[-2].assignment_lex), (yyvsp[0].assignment_lex));
}
#line 30884 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 438:
#line 4115 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.for_loop_bounds).m_direction= (yyvsp[-1].num);
(yyval.for_loop_bounds).m_index= (yyvsp[0].assignment_lex);
(yyval.for_loop_bounds).m_target_bound= NULL;
(yyval.for_loop_bounds).m_implicit_cursor= false;
}
#line 30897 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 439:
#line 4122 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->sp_for_loop_implicit_cursor_statement(thd, &(yyval.for_loop_bounds),
(yyvsp[-1].sp_cursor_stmt))))
MYSQL_YYABORT;
}
#line 30909 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 440:
#line 4131 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
uint ip= lex->sphead->instructions();
sp_label *lab= lex->spcont->last_label(); /* Jumping back */
sp_instr_jump *i= new (thd->mem_root)
sp_instr_jump(ip, lex->spcont, lab->ip);
if (unlikely(i == NULL) ||
unlikely(lex->sphead->add_instr(i)))
MYSQL_YYABORT;
}
#line 30926 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 441:
#line 4145 "/home/buildbot/git/sql/sql_yacc.yy"
{
if ((yyvsp[-2].expr_lex)->sp_repeat_loop_finalize(thd))
MYSQL_YYABORT;
}
#line 30937 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 442:
#line 4153 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->sp_pop_loop_label(thd, &(yyvsp[0].lex_str))))
MYSQL_YYABORT;
}
#line 30948 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 443:
#line 4161 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->sp_push_loop_label(thd, &(yyvsp[-1].lex_str))))
MYSQL_YYABORT;
}
#line 30959 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 444:
#line 4166 "/home/buildbot/git/sql/sql_yacc.yy"
{ }
#line 30967 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 445:
#line 4168 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->sp_push_loop_label(thd, &(yyvsp[-1].lex_str))))
MYSQL_YYABORT;
}
#line 30978 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 446:
#line 4173 "/home/buildbot/git/sql/sql_yacc.yy"
{ }
#line 30986 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 447:
#line 4175 "/home/buildbot/git/sql/sql_yacc.yy"
{
// See "The FOR LOOP statement" comments in sql_lex.cc
Lex->sp_block_init(thd); // The outer DECLARE..BEGIN..END block
}
#line 30997 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 448:
#line 4180 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->sp_push_loop_label(thd, &(yyvsp[-3].lex_str)))) // The inner WHILE block
MYSQL_YYABORT;
if (unlikely(Lex->sp_for_loop_condition_test(thd, (yyvsp[0].for_loop))))
MYSQL_YYABORT;
}
#line 31010 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 449:
#line 4187 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->sp_for_loop_finalize(thd, (yyvsp[-2].for_loop))))
MYSQL_YYABORT;
}
#line 31021 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 450:
#line 4192 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->sp_for_loop_outer_block_finalize(thd, (yyvsp[-4].for_loop))))
MYSQL_YYABORT;
}
#line 31032 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 451:
#line 4197 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->sp_push_loop_label(thd, &(yyvsp[-1].lex_str))))
MYSQL_YYABORT;
}
#line 31043 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 452:
#line 4202 "/home/buildbot/git/sql/sql_yacc.yy"
{ }
#line 31051 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 453:
#line 4207 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->sp_push_loop_empty_label(thd)))
MYSQL_YYABORT;
}
#line 31062 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 454:
#line 4212 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->sp_pop_loop_empty_label(thd);
}
#line 31072 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 455:
#line 4216 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->sp_push_loop_empty_label(thd)))
MYSQL_YYABORT;
}
#line 31083 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 456:
#line 4221 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->sp_pop_loop_empty_label(thd);
}
#line 31093 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 457:
#line 4225 "/home/buildbot/git/sql/sql_yacc.yy"
{
// See "The FOR LOOP statement" comments in sql_lex.cc
if (unlikely(Lex->maybe_start_compound_statement(thd)))
MYSQL_YYABORT;
Lex->sp_block_init(thd); // The outer DECLARE..BEGIN..END block
}
#line 31106 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 458:
#line 4232 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->sp_push_loop_empty_label(thd))) // The inner WHILE block
MYSQL_YYABORT;
if (unlikely(Lex->sp_for_loop_condition_test(thd, (yyvsp[0].for_loop))))
MYSQL_YYABORT;
}
#line 31119 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 459:
#line 4239 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->sp_for_loop_finalize(thd, (yyvsp[-2].for_loop))))
MYSQL_YYABORT;
Lex->sp_pop_loop_empty_label(thd); // The inner WHILE block
if (unlikely(Lex->sp_for_loop_outer_block_finalize(thd, (yyvsp[-2].for_loop))))
MYSQL_YYABORT;
}
#line 31133 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 460:
#line 4247 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->sp_push_loop_empty_label(thd)))
MYSQL_YYABORT;
}
#line 31144 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 461:
#line 4252 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->sp_pop_loop_empty_label(thd);
}
#line 31154 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 462:
#line 4259 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->trg_chistics.action_time= TRG_ACTION_BEFORE; }
#line 31162 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 463:
#line 4261 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->trg_chistics.action_time= TRG_ACTION_AFTER; }
#line 31170 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 464:
#line 4266 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->trg_chistics.event= TRG_EVENT_INSERT; }
#line 31178 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 465:
#line 4268 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->trg_chistics.event= TRG_EVENT_UPDATE; }
#line 31186 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 466:
#line 4270 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->trg_chistics.event= TRG_EVENT_DELETE; }
#line 31194 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 470:
#line 4304 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 31202 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 471:
#line 4306 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
lex->alter_tablespace_info->logfile_group_name= (yyvsp[0].ident_sys).str;
}
#line 31213 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 472:
#line 4316 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->alter_tablespace_info->ts_alter_tablespace_type= ALTER_TABLESPACE_ADD_FILE;
}
#line 31223 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 473:
#line 4322 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->alter_tablespace_info->ts_alter_tablespace_type= ALTER_TABLESPACE_DROP_FILE;
}
#line 31233 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 478:
#line 4345 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 31241 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 525:
#line 4439 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
lex->alter_tablespace_info->data_file_name= (yyvsp[0].lex_str).str;
}
#line 31252 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 526:
#line 4447 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
lex->alter_tablespace_info->undo_file_name= (yyvsp[0].lex_str).str;
}
#line 31263 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 527:
#line 4455 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
lex->alter_tablespace_info->redo_file_name= (yyvsp[0].lex_str).str;
}
#line 31274 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 528:
#line 4463 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
lex->alter_tablespace_info= (new (thd->mem_root)
st_alter_tablespace());
if (unlikely(lex->alter_tablespace_info == NULL))
MYSQL_YYABORT;
lex->alter_tablespace_info->tablespace_name= (yyvsp[0].ident_sys).str;
lex->sql_command= SQLCOM_ALTER_TABLESPACE;
}
#line 31290 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 529:
#line 4476 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
lex->alter_tablespace_info= (new (thd->mem_root)
st_alter_tablespace());
if (unlikely(lex->alter_tablespace_info == NULL))
MYSQL_YYABORT;
lex->alter_tablespace_info->logfile_group_name= (yyvsp[0].ident_sys).str;
lex->sql_command= SQLCOM_ALTER_TABLESPACE;
}
#line 31306 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 530:
#line 4489 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
lex->alter_tablespace_info->ts_access_mode= TS_READ_ONLY;
}
#line 31317 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 531:
#line 4494 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
lex->alter_tablespace_info->ts_access_mode= TS_READ_WRITE;
}
#line 31328 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 532:
#line 4499 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
lex->alter_tablespace_info->ts_access_mode= TS_NOT_ACCESSIBLE;
}
#line 31339 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 533:
#line 4507 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
lex->alter_tablespace_info->initial_size= (yyvsp[0].ulonglong_number);
}
#line 31350 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 534:
#line 4515 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
lex->alter_tablespace_info->autoextend_size= (yyvsp[0].ulonglong_number);
}
#line 31361 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 535:
#line 4523 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
lex->alter_tablespace_info->max_size= (yyvsp[0].ulonglong_number);
}
#line 31372 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 536:
#line 4531 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
lex->alter_tablespace_info->extent_size= (yyvsp[0].ulonglong_number);
}
#line 31383 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 537:
#line 4539 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
lex->alter_tablespace_info->undo_buffer_size= (yyvsp[0].ulonglong_number);
}
#line 31394 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 538:
#line 4547 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
lex->alter_tablespace_info->redo_buffer_size= (yyvsp[0].ulonglong_number);
}
#line 31405 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 539:
#line 4555 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
if (unlikely(lex->alter_tablespace_info->nodegroup_id != UNDEF_NODEGROUP))
my_yyabort_error((ER_FILEGROUP_OPTION_ONLY_ONCE,MYF(0),"NODEGROUP"));
lex->alter_tablespace_info->nodegroup_id= (yyvsp[0].ulong_num);
}
#line 31418 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 540:
#line 4565 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
if (unlikely(lex->alter_tablespace_info->ts_comment != NULL))
my_yyabort_error((ER_FILEGROUP_OPTION_ONLY_ONCE,MYF(0),"COMMENT"));
lex->alter_tablespace_info->ts_comment= (yyvsp[0].lex_str).str;
}
#line 31431 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 541:
#line 4575 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
if (unlikely(lex->alter_tablespace_info->storage_engine != NULL))
my_yyabort_error((ER_FILEGROUP_OPTION_ONLY_ONCE, MYF(0),
"STORAGE ENGINE"));
lex->alter_tablespace_info->storage_engine= (yyvsp[0].db_type);
}
#line 31445 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 544:
#line 4591 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
lex->alter_tablespace_info->wait_until_completed= TRUE;
}
#line 31456 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 545:
#line 4596 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
if (unlikely(!(lex->alter_tablespace_info->wait_until_completed)))
my_yyabort_error((ER_FILEGROUP_OPTION_ONLY_ONCE,MYF(0),"NO_WAIT"));
lex->alter_tablespace_info->wait_until_completed= FALSE;
}
#line 31469 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 546:
#line 4605 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.ulonglong_number)= (yyvsp[0].ulonglong_number);}
#line 31477 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 547:
#line 4607 "/home/buildbot/git/sql/sql_yacc.yy"
{
if ((yyvsp[0].ident_sys).to_size_number(&(yyval.ulonglong_number)))
MYSQL_YYABORT;
}
#line 31488 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 548:
#line 4619 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->create_info.option_list= NULL; }
#line 31496 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 549:
#line 4620 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 31504 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 550:
#line 4621 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 31512 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 551:
#line 4623 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->create_info.add(DDL_options_st::OPT_LIKE);
TABLE_LIST *src_table= Lex->first_select_lex()->
add_table_to_list(thd, (yyvsp[0].table), NULL, 0, TL_READ, MDL_SHARED_READ);
if (unlikely(! src_table))
MYSQL_YYABORT;
/* CREATE TABLE ... LIKE is not allowed for views. */
src_table->required_type= TABLE_TYPE_NORMAL;
}
#line 31529 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 552:
#line 4636 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.table)= (yyvsp[0].table); }
#line 31537 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 553:
#line 4637 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.table)= (yyvsp[-1].table); }
#line 31545 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 554:
#line 4641 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 31553 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 556:
#line 4647 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (Lex->parsed_insert_select((yyvsp[0].select_lex_unit)->first_select()))
MYSQL_YYABORT;
}
#line 31564 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 557:
#line 4652 "/home/buildbot/git/sql/sql_yacc.yy"
{
SELECT_LEX *first_select= (yyvsp[-1].select_lex_unit)->first_select();
(yyvsp[-1].select_lex_unit)->set_with_clause((yyvsp[-2].with_clause));
(yyvsp[-2].with_clause)->attach_to(first_select);
if (Lex->parsed_insert_select(first_select))
MYSQL_YYABORT;
}
#line 31578 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 558:
#line 4663 "/home/buildbot/git/sql/sql_yacc.yy"
{
/*
Remove all tables used in PARTITION clause from the global table
list. Partitioning with subqueries is not allowed anyway.
*/
TABLE_LIST *last_non_sel_table= Lex->create_last_non_select_table;
last_non_sel_table->next_global= 0;
Lex->query_tables_last= &last_non_sel_table->next_global;
}
#line 31594 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 559:
#line 4699 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 31602 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 561:
#line 4705 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
lex->part_info= new (thd->mem_root) partition_info();
if (unlikely(!lex->part_info))
MYSQL_YYABORT;
if (lex->sql_command == SQLCOM_ALTER_TABLE)
{
lex->alter_info.partition_flags|= ALTER_PARTITION_INFO;
}
}
#line 31619 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 563:
#line 4720 "/home/buildbot/git/sql/sql_yacc.yy"
{
#ifdef WITH_PARTITION_STORAGE_ENGINE
LEX_CSTRING partition_name={STRING_WITH_LEN("partition")};
if (unlikely(!plugin_is_ready(&partition_name, MYSQL_STORAGE_ENGINE_PLUGIN)))
my_yyabort_error((ER_OPTION_PREVENTS_STATEMENT, MYF(0),
"--skip-partition"));
#else
my_yyabort_error((ER_FEATURE_DISABLED, MYF(0), "partitioning",
"--with-plugin-partition"));
#endif
}
#line 31637 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 564:
#line 4735 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(!Lex->part_info))
{
thd->parse_error(ER_PARTITION_ENTRY_ERROR);
MYSQL_YYABORT;
}
if (Lex->main_select_push())
MYSQL_YYABORT;
/*
We enter here when opening the frm file to translate
partition info string into part_info data structure.
*/
}
#line 31657 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 565:
#line 4749 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->pop_select(); //main select
}
#line 31667 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 566:
#line 4756 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->safe_to_cache_query= 1; }
#line 31675 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 568:
#line 4762 "/home/buildbot/git/sql/sql_yacc.yy"
{
partition_info *part_info= Lex->part_info;
part_info->list_of_part_fields= TRUE;
part_info->column_list= FALSE;
part_info->part_type= HASH_PARTITION;
}
#line 31688 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 569:
#line 4769 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->part_info->part_type= HASH_PARTITION; }
#line 31696 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 570:
#line 4770 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 31704 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 571:
#line 4772 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->part_info->part_type= RANGE_PARTITION; }
#line 31712 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 572:
#line 4774 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->part_info->part_type= RANGE_PARTITION; }
#line 31720 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 573:
#line 4776 "/home/buildbot/git/sql/sql_yacc.yy"
{
Select->parsing_place= IN_PART_FUNC;
}
#line 31730 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 574:
#line 4780 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->part_info->part_type= LIST_PARTITION;
Select->parsing_place= NO_MATTER;
}
#line 31741 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 575:
#line 4785 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->part_info->part_type= LIST_PARTITION; }
#line 31749 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 576:
#line 4787 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->part_info->vers_init_info(thd)))
MYSQL_YYABORT;
}
#line 31760 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 578:
#line 4795 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 31768 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 579:
#line 4797 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->part_info->linear_hash_ind= TRUE;}
#line 31776 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 580:
#line 4802 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->part_info->key_algorithm= partition_info::KEY_ALGORITHM_NONE;}
#line 31784 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 581:
#line 4804 "/home/buildbot/git/sql/sql_yacc.yy"
{
switch ((yyvsp[0].ulong_num)) {
case 1:
Lex->part_info->key_algorithm= partition_info::KEY_ALGORITHM_51;
break;
case 2:
Lex->part_info->key_algorithm= partition_info::KEY_ALGORITHM_55;
break;
default:
thd->parse_error();
MYSQL_YYABORT;
}
}
#line 31804 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 582:
#line 4820 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 31812 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 583:
#line 4821 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 31820 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 584:
#line 4825 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 31828 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 585:
#line 4826 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 31836 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 586:
#line 4831 "/home/buildbot/git/sql/sql_yacc.yy"
{
partition_info *part_info= Lex->part_info;
part_info->num_columns++;
if (unlikely(part_info->part_field_list.push_back((yyvsp[0].ident_sys).str,
thd->mem_root)))
MYSQL_YYABORT;
if (unlikely(part_info->num_columns > MAX_REF_PARTS))
my_yyabort_error((ER_TOO_MANY_PARTITION_FUNC_FIELDS_ERROR, MYF(0),
"list of partition fields"));
}
#line 31853 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 587:
#line 4845 "/home/buildbot/git/sql/sql_yacc.yy"
{
partition_info *part_info= Lex->part_info;
part_info->column_list= TRUE;
part_info->list_of_part_fields= TRUE;
}
#line 31865 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 588:
#line 4855 "/home/buildbot/git/sql/sql_yacc.yy"
{
partition_info *part_info= Lex->part_info;
if (unlikely(part_info->set_part_expr(thd, (yyvsp[-1].item), FALSE)))
MYSQL_YYABORT;
part_info->num_columns= 1;
part_info->column_list= FALSE;
}
#line 31879 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 589:
#line 4866 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->part_info->set_part_expr(thd, (yyvsp[-1].item), TRUE)))
MYSQL_YYABORT;
}
#line 31890 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 590:
#line 4874 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 31898 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 591:
#line 4876 "/home/buildbot/git/sql/sql_yacc.yy"
{
uint num_parts= (yyvsp[0].ulong_num);
partition_info *part_info= Lex->part_info;
if (unlikely(num_parts == 0))
my_yyabort_error((ER_NO_PARTS_ERROR, MYF(0), "partitions"));
part_info->num_parts= num_parts;
part_info->use_default_num_partitions= FALSE;
}
#line 31914 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 592:
#line 4888 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 31922 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 593:
#line 4890 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->part_info->subpart_type= HASH_PARTITION; }
#line 31930 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 594:
#line 4891 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 31938 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 595:
#line 4894 "/home/buildbot/git/sql/sql_yacc.yy"
{
partition_info *part_info= Lex->part_info;
part_info->subpart_type= HASH_PARTITION;
part_info->list_of_subpart_fields= TRUE;
}
#line 31950 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 596:
#line 4899 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 31958 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 597:
#line 4903 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 31966 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 598:
#line 4904 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 31974 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 599:
#line 4909 "/home/buildbot/git/sql/sql_yacc.yy"
{
partition_info *part_info= Lex->part_info;
if (unlikely(part_info->subpart_field_list.push_back((yyvsp[0].ident_sys).str,
thd->mem_root)))
MYSQL_YYABORT;
if (unlikely(part_info->subpart_field_list.elements > MAX_REF_PARTS))
my_yyabort_error((ER_TOO_MANY_PARTITION_FUNC_FIELDS_ERROR, MYF(0),
"list of subpartition fields"));
}
#line 31991 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 600:
#line 4923 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(!Lex->safe_to_cache_query))
{
thd->parse_error(ER_WRONG_EXPR_IN_PARTITION_FUNC_ERROR);
MYSQL_YYABORT;
}
(yyval.item)=(yyvsp[0].item);
}
#line 32006 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 601:
#line 4934 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 32014 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 602:
#line 4936 "/home/buildbot/git/sql/sql_yacc.yy"
{
uint num_parts= (yyvsp[0].ulong_num);
LEX *lex= Lex;
if (unlikely(num_parts == 0))
my_yyabort_error((ER_NO_PARTS_ERROR, MYF(0), "subpartitions"));
lex->part_info->num_subparts= num_parts;
lex->part_info->use_default_num_subpartitions= FALSE;
}
#line 32029 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 603:
#line 4948 "/home/buildbot/git/sql/sql_yacc.yy"
{
partition_info *part_info= Lex->part_info;
if (unlikely(part_info->part_type == RANGE_PARTITION))
my_yyabort_error((ER_PARTITIONS_MUST_BE_DEFINED_ERROR, MYF(0),
"RANGE"));
if (unlikely(part_info->part_type == LIST_PARTITION))
my_yyabort_error((ER_PARTITIONS_MUST_BE_DEFINED_ERROR, MYF(0),
"LIST"));
}
#line 32045 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 604:
#line 4958 "/home/buildbot/git/sql/sql_yacc.yy"
{
partition_info *part_info= Lex->part_info;
uint count_curr_parts= part_info->partitions.elements;
if (part_info->num_parts != 0)
{
if (unlikely(part_info->num_parts !=
count_curr_parts))
{
thd->parse_error(ER_PARTITION_WRONG_NO_PART_ERROR);
MYSQL_YYABORT;
}
}
else if (count_curr_parts > 0)
{
part_info->num_parts= count_curr_parts;
}
part_info->count_curr_subparts= 0;
}
#line 32070 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 605:
#line 4979 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 32078 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 606:
#line 4980 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 32086 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 607:
#line 4985 "/home/buildbot/git/sql/sql_yacc.yy"
{
partition_info *part_info= Lex->part_info;
partition_element *p_elem= new (thd->mem_root) partition_element();
if (unlikely(!p_elem) ||
unlikely(part_info->partitions.push_back(p_elem, thd->mem_root)))
MYSQL_YYABORT;
p_elem->part_state= PART_NORMAL;
p_elem->id= part_info->partitions.elements - 1;
part_info->curr_part_elem= p_elem;
part_info->current_partition= p_elem;
part_info->use_default_partitions= FALSE;
part_info->use_default_num_partitions= FALSE;
}
#line 32108 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 608:
#line 5004 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 32116 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 609:
#line 5009 "/home/buildbot/git/sql/sql_yacc.yy"
{
partition_info *part_info= Lex->part_info;
partition_element *p_elem= part_info->curr_part_elem;
if (unlikely(check_ident_length(&(yyvsp[0].ident_sys))))
MYSQL_YYABORT;
p_elem->partition_name= (yyvsp[0].ident_sys).str;
}
#line 32130 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 610:
#line 5020 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
partition_info *part_info= lex->part_info;
if (! lex->is_partition_management())
{
if (unlikely(part_info->error_if_requires_values()))
MYSQL_YYABORT;
if (unlikely(part_info->part_type == VERSIONING_PARTITION))
my_yyabort_error((ER_VERS_WRONG_PARTS, MYF(0),
lex->create_last_non_select_table->
table_name.str));
}
else
part_info->part_type= HASH_PARTITION;
}
#line 32152 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 611:
#line 5036 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
partition_info *part_info= lex->part_info;
if (! lex->is_partition_management())
{
if (unlikely(part_info->part_type != RANGE_PARTITION))
my_yyabort_error((ER_PARTITION_WRONG_VALUES_ERROR, MYF(0),
"RANGE", "LESS THAN"));
}
else
part_info->part_type= RANGE_PARTITION;
}
#line 32171 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 612:
#line 5048 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 32179 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 613:
#line 5050 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
partition_info *part_info= lex->part_info;
if (! lex->is_partition_management())
{
if (unlikely(part_info->part_type != LIST_PARTITION))
my_yyabort_error((ER_PARTITION_WRONG_VALUES_ERROR, MYF(0),
"LIST", "IN"));
}
else
part_info->part_type= LIST_PARTITION;
}
#line 32198 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 614:
#line 5062 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 32206 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 615:
#line 5064 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (Lex->part_values_current(thd))
MYSQL_YYABORT;
}
#line 32217 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 616:
#line 5069 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (Lex->part_values_history(thd))
MYSQL_YYABORT;
}
#line 32228 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 617:
#line 5074 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
partition_info *part_info= lex->part_info;
if (! lex->is_partition_management())
{
if (unlikely(part_info->part_type != LIST_PARTITION))
my_yyabort_error((ER_PARTITION_WRONG_VALUES_ERROR, MYF(0),
"LIST", "DEFAULT"));
}
else
part_info->part_type= LIST_PARTITION;
if (unlikely(part_info->init_column_part(thd)))
MYSQL_YYABORT;
if (unlikely(part_info->add_max_value(thd)))
MYSQL_YYABORT;
}
#line 32251 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 618:
#line 5094 "/home/buildbot/git/sql/sql_yacc.yy"
{
partition_info *part_info= Lex->part_info;
if (unlikely(part_info->num_columns &&
part_info->num_columns != 1U))
{
part_info->print_debug("Kilroy II", NULL);
thd->parse_error(ER_PARTITION_COLUMN_LIST_ERROR);
MYSQL_YYABORT;
}
else
part_info->num_columns= 1U;
if (unlikely(part_info->init_column_part(thd)))
MYSQL_YYABORT;
if (unlikely(part_info->add_max_value(thd)))
MYSQL_YYABORT;
}
#line 32275 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 619:
#line 5111 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 32283 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 620:
#line 5116 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
partition_info *part_info= lex->part_info;
part_info->print_debug("part_values_in: part_value_item", NULL);
if (part_info->num_columns != 1U)
{
if (unlikely(!lex->is_partition_management() ||
part_info->num_columns == 0 ||
part_info->num_columns > MAX_REF_PARTS))
{
part_info->print_debug("Kilroy III", NULL);
thd->parse_error(ER_PARTITION_COLUMN_LIST_ERROR);
MYSQL_YYABORT;
}
/*
Reorganize the current large array into a list of small
arrays with one entry in each array. This can happen
in the first partition of an ALTER TABLE statement where
we ADD or REORGANIZE partitions. Also can only happen
for LIST partitions.
*/
if (unlikely(part_info->reorganize_into_single_field_col_val(thd)))
MYSQL_YYABORT;
}
}
#line 32316 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 621:
#line 5143 "/home/buildbot/git/sql/sql_yacc.yy"
{
partition_info *part_info= Lex->part_info;
if (unlikely(part_info->num_columns < 2U))
{
thd->parse_error(ER_ROW_SINGLE_PARTITION_FIELD_ERROR);
MYSQL_YYABORT;
}
}
#line 32331 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 622:
#line 5154 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 32339 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 623:
#line 5155 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 32347 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 624:
#line 5160 "/home/buildbot/git/sql/sql_yacc.yy"
{
partition_info *part_info= Lex->part_info;
part_info->print_debug("( part_value_item", NULL);
/* Initialisation code needed for each list of value expressions */
if (unlikely(!(part_info->part_type == LIST_PARTITION &&
part_info->num_columns == 1U) &&
part_info->init_column_part(thd)))
MYSQL_YYABORT;
}
#line 32363 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 625:
#line 5169 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 32371 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 626:
#line 5171 "/home/buildbot/git/sql/sql_yacc.yy"
{
partition_info *part_info= Lex->part_info;
part_info->print_debug(") part_value_item", NULL);
if (part_info->num_columns == 0)
part_info->num_columns= part_info->curr_list_object;
if (unlikely(part_info->num_columns != part_info->curr_list_object))
{
/*
All value items lists must be of equal length, in some cases
which is covered by the above if-statement we don't know yet
how many columns is in the partition so the assignment above
ensures that we only report errors when we know we have an
error.
*/
part_info->print_debug("Kilroy I", NULL);
thd->parse_error(ER_PARTITION_COLUMN_LIST_ERROR);
MYSQL_YYABORT;
}
part_info->curr_list_object= 0;
}
#line 32398 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 627:
#line 5194 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 32406 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 628:
#line 5195 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 32414 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 629:
#line 5200 "/home/buildbot/git/sql/sql_yacc.yy"
{
partition_info *part_info= Lex->part_info;
if (unlikely(part_info->part_type == LIST_PARTITION))
{
thd->parse_error(ER_MAXVALUE_IN_VALUES_IN);
MYSQL_YYABORT;
}
if (unlikely(part_info->add_max_value(thd)))
MYSQL_YYABORT;
}
#line 32431 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 630:
#line 5211 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
partition_info *part_info= lex->part_info;
Item *part_expr= (yyvsp[0].item);
if (unlikely(!lex->safe_to_cache_query))
{
thd->parse_error(ER_WRONG_EXPR_IN_PARTITION_FUNC_ERROR);
MYSQL_YYABORT;
}
if (unlikely(part_info->add_column_list_value(thd, part_expr)))
MYSQL_YYABORT;
}
#line 32451 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 631:
#line 5229 "/home/buildbot/git/sql/sql_yacc.yy"
{
partition_info *part_info= Lex->part_info;
if (unlikely(part_info->num_subparts != 0 &&
!part_info->use_default_subpartitions))
{
/*
We come here when we have defined subpartitions on the first
partition but not on all the subsequent partitions.
*/
thd->parse_error(ER_PARTITION_WRONG_NO_SUBPART_ERROR);
MYSQL_YYABORT;
}
}
#line 32471 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 632:
#line 5243 "/home/buildbot/git/sql/sql_yacc.yy"
{
partition_info *part_info= Lex->part_info;
if (part_info->num_subparts != 0)
{
if (unlikely(part_info->num_subparts !=
part_info->count_curr_subparts))
{
thd->parse_error(ER_PARTITION_WRONG_NO_SUBPART_ERROR);
MYSQL_YYABORT;
}
}
else if (part_info->count_curr_subparts > 0)
{
if (unlikely(part_info->partitions.elements > 1))
{
thd->parse_error(ER_PARTITION_WRONG_NO_SUBPART_ERROR);
MYSQL_YYABORT;
}
part_info->num_subparts= part_info->count_curr_subparts;
}
part_info->count_curr_subparts= 0;
}
#line 32500 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 633:
#line 5268 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 32508 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 634:
#line 5269 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 32516 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 635:
#line 5274 "/home/buildbot/git/sql/sql_yacc.yy"
{
partition_info *part_info= Lex->part_info;
partition_element *curr_part= part_info->current_partition;
partition_element *sub_p_elem= new (thd->mem_root)
partition_element(curr_part);
if (unlikely(part_info->use_default_subpartitions &&
part_info->partitions.elements >= 2))
{
/*
create table t1 (a int)
partition by list (a) subpartition by hash (a)
(partition p0 values in (1),
partition p1 values in (2) subpartition sp11);
causes use to arrive since we are on the second
partition, but still use_default_subpartitions
is set. When we come here we're processing at least
the second partition (the current partition processed
have already been put into the partitions list.
*/
thd->parse_error(ER_PARTITION_WRONG_NO_SUBPART_ERROR);
MYSQL_YYABORT;
}
if (unlikely(!sub_p_elem) ||
unlikely(curr_part->subpartitions.push_back(sub_p_elem, thd->mem_root)))
MYSQL_YYABORT;
sub_p_elem->id= curr_part->subpartitions.elements - 1;
part_info->curr_part_elem= sub_p_elem;
part_info->use_default_subpartitions= FALSE;
part_info->use_default_num_subpartitions= FALSE;
part_info->count_curr_subparts++;
}
#line 32555 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 636:
#line 5306 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 32563 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 637:
#line 5311 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(check_ident_length(&(yyvsp[0].lex_str))))
MYSQL_YYABORT;
Lex->part_info->curr_part_elem->partition_name= (yyvsp[0].lex_str).str;
}
#line 32575 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 638:
#line 5319 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 32583 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 639:
#line 5320 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 32591 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 640:
#line 5324 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 32599 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 641:
#line 5325 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 32607 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 642:
#line 5330 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->part_info->curr_part_elem->tablespace_name= (yyvsp[0].lex_str).str; }
#line 32615 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 643:
#line 5332 "/home/buildbot/git/sql/sql_yacc.yy"
{
partition_info *part_info= Lex->part_info;
part_info->curr_part_elem->engine_type= (yyvsp[0].db_type);
part_info->default_engine_type= (yyvsp[0].db_type);
}
#line 32627 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 644:
#line 5338 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
lex->part_info->curr_part_elem->connect_string.str= (yyvsp[0].lex_str).str;
lex->part_info->curr_part_elem->connect_string.length= (yyvsp[0].lex_str).length;
}
#line 32639 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 645:
#line 5344 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->part_info->curr_part_elem->nodegroup_id= (uint16) (yyvsp[0].ulong_num); }
#line 32647 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 646:
#line 5346 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->part_info->curr_part_elem->part_max_rows= (ha_rows) (yyvsp[0].ulonglong_number); }
#line 32655 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 647:
#line 5348 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->part_info->curr_part_elem->part_min_rows= (ha_rows) (yyvsp[0].ulonglong_number); }
#line 32663 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 648:
#line 5350 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->part_info->curr_part_elem->data_file_name= (yyvsp[0].lex_str).str; }
#line 32671 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 649:
#line 5352 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->part_info->curr_part_elem->index_file_name= (yyvsp[0].lex_str).str; }
#line 32679 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 650:
#line 5354 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->part_info->curr_part_elem->part_comment= (yyvsp[0].lex_str).str; }
#line 32687 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 651:
#line 5358 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 32695 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 652:
#line 5360 "/home/buildbot/git/sql/sql_yacc.yy"
{
partition_info *part_info= Lex->part_info;
const char *table_name= Lex->create_last_non_select_table->table_name.str;
if (unlikely(part_info->vers_set_interval(thd, (yyvsp[-2].item), (yyvsp[-1].interval), (yyvsp[0].item), table_name)))
MYSQL_YYABORT;
}
#line 32708 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 653:
#line 5367 "/home/buildbot/git/sql/sql_yacc.yy"
{
partition_info *part_info= Lex->part_info;
if (unlikely(part_info->vers_set_limit((yyvsp[0].ulonglong_number))))
{
my_error(ER_PART_WRONG_VALUE, MYF(0),
Lex->create_last_non_select_table->table_name.str,
"LIMIT");
MYSQL_YYABORT;
}
}
#line 32725 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 654:
#line 5382 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= NULL;
}
#line 32735 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 655:
#line 5386 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= (yyvsp[0].item);
}
#line 32745 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 656:
#line 5396 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 32753 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 657:
#line 5397 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 32761 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 658:
#line 5401 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 32769 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 659:
#line 5402 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 32777 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 660:
#line 5406 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 32785 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 661:
#line 5407 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 32793 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 662:
#line 5411 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 32801 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 663:
#line 5412 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 32809 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 664:
#line 5414 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->create_info.schema_comment= thd->make_clex_string((yyvsp[0].lex_str));
Lex->create_info.used_fields|= HA_CREATE_USED_COMMENT;
}
#line 32820 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 665:
#line 5422 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->check_exists= FALSE;
}
#line 32830 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 666:
#line 5426 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->check_exists= TRUE;
}
#line 32840 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 667:
#line 5433 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.object_ddl_options).init();
}
#line 32850 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 668:
#line 5437 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.object_ddl_options).set(DDL_options_st::OPT_IF_NOT_EXISTS);
}
#line 32860 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 669:
#line 5444 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.object_ddl_options).init();
}
#line 32870 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 670:
#line 5448 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.object_ddl_options).set(DDL_options_st::OPT_OR_REPLACE);
}
#line 32880 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 678:
#line 5471 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
if (!lex->m_sql_cmd)
{
DBUG_ASSERT(lex->sql_command == SQLCOM_ALTER_TABLE);
if (!(lex->m_sql_cmd= new (thd->mem_root) Sql_cmd_alter_table()))
MYSQL_YYABORT;
}
Storage_engine_name *opt=
lex->m_sql_cmd->option_storage_engine_name();
DBUG_ASSERT(opt); // Expect a proper Sql_cmd
*opt= Storage_engine_name((yyvsp[0].lex_str));
lex->create_info.used_fields|= HA_CREATE_USED_ENGINE;
}
#line 32901 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 679:
#line 5486 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->create_info.max_rows= (yyvsp[0].ulonglong_number);
Lex->create_info.used_fields|= HA_CREATE_USED_MAX_ROWS;
}
#line 32912 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 680:
#line 5491 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->create_info.min_rows= (yyvsp[0].ulonglong_number);
Lex->create_info.used_fields|= HA_CREATE_USED_MIN_ROWS;
}
#line 32923 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 681:
#line 5496 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->create_info.avg_row_length=(yyvsp[0].ulong_num);
Lex->create_info.used_fields|= HA_CREATE_USED_AVG_ROW_LENGTH;
}
#line 32934 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 682:
#line 5501 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->create_info.password=(yyvsp[0].lex_str).str;
Lex->create_info.used_fields|= HA_CREATE_USED_PASSWORD;
}
#line 32945 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 683:
#line 5506 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->create_info.comment=(yyvsp[0].lex_str);
Lex->create_info.used_fields|= HA_CREATE_USED_COMMENT;
}
#line 32956 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 684:
#line 5511 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->create_info.auto_increment_value=(yyvsp[0].ulonglong_number);
Lex->create_info.used_fields|= HA_CREATE_USED_AUTO;
}
#line 32967 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 685:
#line 5516 "/home/buildbot/git/sql/sql_yacc.yy"
{
switch((yyvsp[0].ulong_num)) {
case 0:
Lex->create_info.table_options|= HA_OPTION_NO_PACK_KEYS;
break;
case 1:
Lex->create_info.table_options|= HA_OPTION_PACK_KEYS;
break;
default:
thd->parse_error();
MYSQL_YYABORT;
}
Lex->create_info.used_fields|= HA_CREATE_USED_PACK_KEYS;
}
#line 32988 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 686:
#line 5531 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->create_info.table_options&=
~(HA_OPTION_PACK_KEYS | HA_OPTION_NO_PACK_KEYS);
Lex->create_info.used_fields|= HA_CREATE_USED_PACK_KEYS;
}
#line 33000 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 687:
#line 5537 "/home/buildbot/git/sql/sql_yacc.yy"
{
switch((yyvsp[0].ulong_num)) {
case 0:
Lex->create_info.stats_auto_recalc= HA_STATS_AUTO_RECALC_OFF;
break;
case 1:
Lex->create_info.stats_auto_recalc= HA_STATS_AUTO_RECALC_ON;
break;
default:
thd->parse_error();
MYSQL_YYABORT;
}
Lex->create_info.used_fields|= HA_CREATE_USED_STATS_AUTO_RECALC;
}
#line 33021 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 688:
#line 5552 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->create_info.stats_auto_recalc= HA_STATS_AUTO_RECALC_DEFAULT;
Lex->create_info.used_fields|= HA_CREATE_USED_STATS_AUTO_RECALC;
}
#line 33032 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 689:
#line 5557 "/home/buildbot/git/sql/sql_yacc.yy"
{
switch((yyvsp[0].ulong_num)) {
case 0:
Lex->create_info.table_options|= HA_OPTION_NO_STATS_PERSISTENT;
break;
case 1:
Lex->create_info.table_options|= HA_OPTION_STATS_PERSISTENT;
break;
default:
thd->parse_error();
MYSQL_YYABORT;
}
Lex->create_info.used_fields|= HA_CREATE_USED_STATS_PERSISTENT;
}
#line 33053 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 690:
#line 5572 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->create_info.table_options&=
~(HA_OPTION_STATS_PERSISTENT | HA_OPTION_NO_STATS_PERSISTENT);
Lex->create_info.used_fields|= HA_CREATE_USED_STATS_PERSISTENT;
}
#line 33065 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 691:
#line 5578 "/home/buildbot/git/sql/sql_yacc.yy"
{
/* From user point of view STATS_SAMPLE_PAGES can be specified as
STATS_SAMPLE_PAGES=N (where 0 0xffff))
{
thd->parse_error();
MYSQL_YYABORT;
}
Lex->create_info.stats_sample_pages=(yyvsp[0].ulong_num);
Lex->create_info.used_fields|= HA_CREATE_USED_STATS_SAMPLE_PAGES;
}
#line 33089 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 692:
#line 5596 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->create_info.stats_sample_pages=0;
Lex->create_info.used_fields|= HA_CREATE_USED_STATS_SAMPLE_PAGES;
}
#line 33100 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 693:
#line 5601 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->create_info.table_options|= (yyvsp[0].ulong_num) ? HA_OPTION_CHECKSUM : HA_OPTION_NO_CHECKSUM;
Lex->create_info.used_fields|= HA_CREATE_USED_CHECKSUM;
}
#line 33111 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 694:
#line 5606 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->create_info.table_options|= (yyvsp[0].ulong_num) ? HA_OPTION_CHECKSUM : HA_OPTION_NO_CHECKSUM;
Lex->create_info.used_fields|= HA_CREATE_USED_CHECKSUM;
}
#line 33122 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 695:
#line 5611 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->create_info.used_fields|= HA_CREATE_USED_PAGE_CHECKSUM;
Lex->create_info.page_checksum= (yyvsp[0].choice);
}
#line 33133 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 696:
#line 5616 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->create_info.table_options|= (yyvsp[0].ulong_num) ? HA_OPTION_DELAY_KEY_WRITE : HA_OPTION_NO_DELAY_KEY_WRITE;
Lex->create_info.used_fields|= HA_CREATE_USED_DELAY_KEY_WRITE;
}
#line 33144 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 697:
#line 5621 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->create_info.row_type= (yyvsp[0].row_type);
Lex->create_info.used_fields|= HA_CREATE_USED_ROW_FORMAT;
}
#line 33155 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 698:
#line 5626 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->first_select_lex()->table_list.save_and_clear(&Lex->save_list);
}
#line 33165 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 699:
#line 5630 "/home/buildbot/git/sql/sql_yacc.yy"
{
/*
Move the union list to the merge_list and exclude its tables
from the global list.
*/
LEX *lex=Lex;
lex->create_info.merge_list= lex->first_select_lex()->table_list.first;
lex->first_select_lex()->table_list= lex->save_list;
/*
When excluding union list from the global list we assume that
elements of the former immediately follow elements which represent
table being created/altered and parent tables.
*/
TABLE_LIST *last_non_sel_table= lex->create_last_non_select_table;
DBUG_ASSERT(last_non_sel_table->next_global ==
lex->create_info.merge_list);
last_non_sel_table->next_global= 0;
Lex->query_tables_last= &last_non_sel_table->next_global;
lex->create_info.used_fields|= HA_CREATE_USED_UNION;
}
#line 33193 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 702:
#line 5654 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->create_info.merge_insert_method= (yyvsp[0].ulong_num);
Lex->create_info.used_fields|= HA_CREATE_USED_INSERT_METHOD;
}
#line 33204 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 703:
#line 5659 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->create_info.data_file_name= (yyvsp[0].lex_str).str;
Lex->create_info.used_fields|= HA_CREATE_USED_DATADIR;
}
#line 33215 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 704:
#line 5664 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->create_info.index_file_name= (yyvsp[0].lex_str).str;
Lex->create_info.used_fields|= HA_CREATE_USED_INDEXDIR;
}
#line 33226 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 705:
#line 5669 "/home/buildbot/git/sql/sql_yacc.yy"
{Lex->create_info.tablespace= (yyvsp[0].ident_sys).str;}
#line 33234 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 706:
#line 5671 "/home/buildbot/git/sql/sql_yacc.yy"
{Lex->create_info.storage_media= HA_SM_DISK;}
#line 33242 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 707:
#line 5673 "/home/buildbot/git/sql/sql_yacc.yy"
{Lex->create_info.storage_media= HA_SM_MEMORY;}
#line 33250 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 708:
#line 5675 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->create_info.connect_string.str= (yyvsp[0].lex_str).str;
Lex->create_info.connect_string.length= (yyvsp[0].lex_str).length;
Lex->create_info.used_fields|= HA_CREATE_USED_CONNECTION;
}
#line 33262 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 709:
#line 5681 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->create_info.used_fields|= HA_CREATE_USED_KEY_BLOCK_SIZE;
Lex->create_info.key_block_size= (yyvsp[0].ulong_num);
}
#line 33273 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 710:
#line 5686 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->create_info.used_fields|= HA_CREATE_USED_TRANSACTIONAL;
Lex->create_info.transactional= (yyvsp[0].choice);
}
#line 33284 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 711:
#line 5691 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely((yyvsp[0].lex_str).length > ENGINE_OPTION_MAX_LENGTH))
my_yyabort_error((ER_VALUE_TOO_LONG, MYF(0), (yyvsp[-2].ident_sys).str));
(void) new (thd->mem_root)
engine_option_value((yyvsp[-2].ident_sys), (yyvsp[0].lex_str), true,
&Lex->create_info.option_list,
&Lex->option_list_last);
}
#line 33299 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 712:
#line 5700 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely((yyvsp[0].ident_sys).length > ENGINE_OPTION_MAX_LENGTH))
my_yyabort_error((ER_VALUE_TOO_LONG, MYF(0), (yyvsp[-2].ident_sys).str));
(void) new (thd->mem_root)
engine_option_value((yyvsp[-2].ident_sys), (yyvsp[0].ident_sys), false,
&Lex->create_info.option_list,
&Lex->option_list_last);
}
#line 33314 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 713:
#line 5709 "/home/buildbot/git/sql/sql_yacc.yy"
{
(void) new (thd->mem_root)
engine_option_value((yyvsp[-2].ident_sys), (yyvsp[0].ulonglong_number), &Lex->create_info.option_list,
&Lex->option_list_last, thd->mem_root);
}
#line 33326 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 714:
#line 5715 "/home/buildbot/git/sql/sql_yacc.yy"
{
(void) new (thd->mem_root)
engine_option_value((yyvsp[-2].ident_sys), &Lex->create_info.option_list,
&Lex->option_list_last);
}
#line 33338 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 715:
#line 5721 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->create_info.used_fields|= HA_CREATE_USED_SEQUENCE;
Lex->create_info.sequence= ((yyvsp[0].choice) == HA_CHOICE_YES);
}
#line 33349 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 719:
#line 5735 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->create_info.options & HA_LEX_CREATE_TMP_TABLE))
{
if (DBUG_EVALUATE_IF("sysvers_force", 0, 1))
{
my_error(ER_VERS_NOT_SUPPORTED, MYF(0), "CREATE TEMPORARY TABLE");
MYSQL_YYABORT;
}
}
else
{
Lex->alter_info.flags|= ALTER_ADD_SYSTEM_VERSIONING;
Lex->create_info.options|= HA_VERSIONED_TABLE;
}
}
#line 33371 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 720:
#line 5754 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->create_info.add_table_option_default_charset((yyvsp[0].charset))))
MYSQL_YYABORT;
}
#line 33382 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 721:
#line 5762 "/home/buildbot/git/sql/sql_yacc.yy"
{
HA_CREATE_INFO *cinfo= &Lex->create_info;
if (unlikely((cinfo->used_fields & HA_CREATE_USED_DEFAULT_CHARSET) &&
cinfo->default_table_charset && (yyvsp[0].charset) &&
!((yyvsp[0].charset)= merge_charset_and_collation(cinfo->default_table_charset,
(yyvsp[0].charset)))))
MYSQL_YYABORT;
Lex->create_info.default_table_charset= (yyvsp[0].charset);
Lex->create_info.used_fields|= HA_CREATE_USED_DEFAULT_CHARSET;
}
#line 33400 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 722:
#line 5777 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (Storage_engine_name((yyvsp[0].lex_str)).
resolve_storage_engine_with_error(thd, &(yyval.db_type),
thd->lex->create_info.tmp_table()))
MYSQL_YYABORT;
}
#line 33413 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 723:
#line 5787 "/home/buildbot/git/sql/sql_yacc.yy"
{
plugin_ref plugin;
if (likely((plugin= ha_resolve_by_name(thd, &(yyvsp[0].lex_str), false))))
(yyval.db_type)= plugin_hton(plugin);
else
my_yyabort_error((ER_UNKNOWN_STORAGE_ENGINE, MYF(0), (yyvsp[0].lex_str).str));
}
#line 33427 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 724:
#line 5797 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.row_type)= ROW_TYPE_DEFAULT; }
#line 33435 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 725:
#line 5798 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.row_type)= ROW_TYPE_FIXED; }
#line 33443 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 726:
#line 5799 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.row_type)= ROW_TYPE_DYNAMIC; }
#line 33451 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 727:
#line 5800 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.row_type)= ROW_TYPE_COMPRESSED; }
#line 33459 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 728:
#line 5801 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.row_type)= ROW_TYPE_REDUNDANT; }
#line 33467 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 729:
#line 5802 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.row_type)= ROW_TYPE_COMPACT; }
#line 33475 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 730:
#line 5803 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.row_type)= ROW_TYPE_PAGE; }
#line 33483 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 731:
#line 5807 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.ulong_num)= MERGE_INSERT_DISABLED; }
#line 33491 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 732:
#line 5808 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.ulong_num)= MERGE_INSERT_TO_FIRST; }
#line 33499 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 733:
#line 5809 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.ulong_num)= MERGE_INSERT_TO_LAST; }
#line 33507 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 734:
#line 5813 "/home/buildbot/git/sql/sql_yacc.yy"
{(yyval.num) = (int) STRING_RESULT; }
#line 33515 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 735:
#line 5814 "/home/buildbot/git/sql/sql_yacc.yy"
{(yyval.num) = (int) REAL_RESULT; }
#line 33523 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 736:
#line 5815 "/home/buildbot/git/sql/sql_yacc.yy"
{(yyval.num) = (int) DECIMAL_RESULT; }
#line 33531 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 737:
#line 5816 "/home/buildbot/git/sql/sql_yacc.yy"
{(yyval.num) = (int) INT_RESULT; }
#line 33539 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 738:
#line 5822 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->create_last_non_select_table= Lex->last_table();
}
#line 33549 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 739:
#line 5829 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->create_last_non_select_table= Lex->last_table();
}
#line 33559 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 742:
#line 5840 "/home/buildbot/git/sql/sql_yacc.yy"
{ }
#line 33567 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 746:
#line 5844 "/home/buildbot/git/sql/sql_yacc.yy"
{ }
#line 33575 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 747:
#line 5849 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.create_field)= (yyvsp[0].create_field); }
#line 33583 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 748:
#line 5851 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->add_column_foreign_key(&((yyvsp[-2].create_field)->field_name), &(yyvsp[-1].lex_str),
(yyvsp[0].table), DDL_options())))
MYSQL_YYABORT;
(yyval.create_field)= (yyvsp[-2].create_field);
}
#line 33596 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 749:
#line 5861 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->option_list= NULL;
if (unlikely(Lex->add_key(Key::MULTIPLE, &(yyvsp[-1].lex_str), (yyvsp[0].key_alg), (yyvsp[-2].object_ddl_options))))
MYSQL_YYABORT;
}
#line 33608 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 750:
#line 5866 "/home/buildbot/git/sql/sql_yacc.yy"
{ }
#line 33616 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 751:
#line 5868 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->option_list= NULL;
if (unlikely(Lex->add_key(Key::MULTIPLE, &(yyvsp[-2].ident_sys), (yyvsp[0].key_alg), (yyvsp[-3].object_ddl_options))))
MYSQL_YYABORT;
}
#line 33628 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 752:
#line 5873 "/home/buildbot/git/sql/sql_yacc.yy"
{ }
#line 33636 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 753:
#line 5875 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->option_list= NULL;
if (unlikely(Lex->add_key((yyvsp[-3].key_type), &(yyvsp[0].lex_str), HA_KEY_ALG_UNDEF, (yyvsp[-1].object_ddl_options))))
MYSQL_YYABORT;
}
#line 33648 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 754:
#line 5880 "/home/buildbot/git/sql/sql_yacc.yy"
{ }
#line 33656 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 755:
#line 5882 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->option_list= NULL;
if (unlikely(Lex->add_key((yyvsp[-3].key_type), &(yyvsp[0].lex_str), HA_KEY_ALG_UNDEF, (yyvsp[-1].object_ddl_options))))
MYSQL_YYABORT;
}
#line 33668 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 756:
#line 5887 "/home/buildbot/git/sql/sql_yacc.yy"
{ }
#line 33676 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 757:
#line 5891 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->option_list= NULL;
if (unlikely(Lex->add_key((yyvsp[-3].key_type), (yyvsp[-1].lex_str).str ? &(yyvsp[-1].lex_str) : &(yyvsp[-4].lex_str), (yyvsp[0].key_alg), (yyvsp[-2].object_ddl_options))))
MYSQL_YYABORT;
}
#line 33688 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 758:
#line 5896 "/home/buildbot/git/sql/sql_yacc.yy"
{ }
#line 33696 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 759:
#line 5899 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->option_list= NULL;
if (unlikely(Lex->add_key((yyvsp[-4].key_type), (yyvsp[-2].ident_sys).str ? &(yyvsp[-2].ident_sys) : &(yyvsp[-5].lex_str), (yyvsp[0].key_alg), (yyvsp[-3].object_ddl_options))))
MYSQL_YYABORT;
}
#line 33708 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 760:
#line 5904 "/home/buildbot/git/sql/sql_yacc.yy"
{ }
#line 33716 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 761:
#line 5906 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->check_add_key((yyvsp[-1].object_ddl_options))) ||
unlikely(!(Lex->last_key= (new (thd->mem_root)
Key(Key::MULTIPLE,
(yyvsp[-4].lex_str).str ? &(yyvsp[-4].lex_str) : &(yyvsp[0].lex_str),
HA_KEY_ALG_UNDEF, true, (yyvsp[-1].object_ddl_options))))))
MYSQL_YYABORT;
Lex->option_list= NULL;
}
#line 33732 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 762:
#line 5916 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->add_table_foreign_key((yyvsp[-5].lex_str).str ? &(yyvsp[-5].lex_str) : &(yyvsp[-9].lex_str),
(yyvsp[-9].lex_str).str ? &(yyvsp[-9].lex_str) : &(yyvsp[-5].lex_str), (yyvsp[0].table), (yyvsp[-6].object_ddl_options))))
MYSQL_YYABORT;
}
#line 33744 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 763:
#line 5925 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->add_constraint((yyvsp[-1].lex_str), (yyvsp[0].virtual_column), FALSE);
}
#line 33754 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 764:
#line 5933 "/home/buildbot/git/sql/sql_yacc.yy"
{
Vers_parse_info &info= Lex->vers_get_info();
info.set_period((yyvsp[-3].ident_sys), (yyvsp[-1].ident_sys));
}
#line 33765 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 765:
#line 5941 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (Lex->add_period((yyvsp[-5].ident_sys), (yyvsp[-3].ident_sys), (yyvsp[-1].ident_sys)))
MYSQL_YYABORT;
}
#line 33776 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 766:
#line 5948 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.virtual_column)= (Virtual_column_info*) 0; }
#line 33784 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 767:
#line 5949 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.virtual_column)= (yyvsp[0].virtual_column);}
#line 33792 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 768:
#line 5954 "/home/buildbot/git/sql/sql_yacc.yy"
{
Virtual_column_info *v= add_virtual_expression(thd, (yyvsp[-1].item));
if (unlikely(!v))
MYSQL_YYABORT;
(yyval.virtual_column)= v;
}
#line 33805 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 769:
#line 5963 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 33813 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 770:
#line 5964 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 33821 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 771:
#line 5968 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.lex_str)= null_clex_str; }
#line 33829 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 772:
#line 5969 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.lex_str)= (yyvsp[0].lex_str); }
#line 33837 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 773:
#line 5973 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.lex_str)=(yyvsp[0].lex_str); }
#line 33845 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 774:
#line 5978 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex=Lex;
Create_field *f= new (thd->mem_root) Create_field();
if (unlikely(check_string_char_length(&(yyvsp[0].lex_str), 0, NAME_CHAR_LEN,
system_charset_info, 1)))
my_yyabort_error((ER_TOO_LONG_IDENT, MYF(0), (yyvsp[0].lex_str).str));
if (unlikely(!f))
MYSQL_YYABORT;
lex->init_last_field(f, &(yyvsp[0].lex_str), NULL);
(yyval.create_field)= f;
lex->parsing_options.lookup_keywords_after_qualifier= true;
}
#line 33867 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 775:
#line 5994 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex=Lex;
lex->parsing_options.lookup_keywords_after_qualifier= false;
(yyval.create_field)= (yyvsp[-2].create_field);
(yyval.create_field)->check_constraint= (yyvsp[0].virtual_column);
if (unlikely((yyval.create_field)->check(thd)))
MYSQL_YYABORT;
lex->alter_info.create_list.push_back((yyval.create_field), thd->mem_root);
(yyval.create_field)->create_if_not_exists= Lex->check_exists;
if ((yyval.create_field)->flags & PRI_KEY_FLAG)
lex->add_key_to_list(&(yyvsp[-3].lex_str), Key::PRIMARY, lex->check_exists);
else if ((yyval.create_field)->flags & UNIQUE_KEY_FLAG)
lex->add_key_to_list(&(yyvsp[-3].lex_str), Key::UNIQUE, lex->check_exists);
}
#line 33892 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 776:
#line 6016 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->last_field->set_attributes(thd, (yyvsp[0].Lex_field_type), Lex->charset,
COLUMN_DEFINITION_TABLE_FIELD);
}
#line 33903 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 778:
#line 6022 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->last_field->set_handler(&type_handler_ulonglong);
Lex->last_field->flags|= AUTO_INCREMENT_FLAG | NOT_NULL_FLAG
| UNSIGNED_FLAG | UNIQUE_KEY_FLAG;
}
#line 33915 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 780:
#line 6031 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 33923 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 781:
#line 6032 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 33931 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 782:
#line 6036 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 33939 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 784:
#line 6041 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 33947 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 785:
#line 6042 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 33955 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 786:
#line 6046 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 33963 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 788:
#line 6051 "/home/buildbot/git/sql/sql_yacc.yy"
{ }
#line 33971 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 792:
#line 6056 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->last_field->vcol_info= (yyvsp[0].virtual_column);
Lex->last_field->flags&= ~NOT_NULL_FLAG; // undo automatic NOT NULL for timestamps
}
#line 33982 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 794:
#line 6062 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (Lex->last_field_generated_always_as_row_start())
MYSQL_YYABORT;
}
#line 33993 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 795:
#line 6067 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (Lex->last_field_generated_always_as_row_end())
MYSQL_YYABORT;
}
#line 34004 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 796:
#line 6074 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 34012 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 797:
#line 6075 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 34020 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 798:
#line 6080 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->last_field->vcol_info->set_stored_in_db_flag(FALSE);
}
#line 34030 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 799:
#line 6084 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->last_field->vcol_info->set_stored_in_db_flag(FALSE);
}
#line 34040 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 800:
#line 6088 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->last_field->vcol_info->set_stored_in_db_flag(TRUE);
}
#line 34050 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 801:
#line 6092 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->last_field->vcol_info->set_stored_in_db_flag(TRUE);
}
#line 34060 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 802:
#line 6098 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 34068 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 803:
#line 6099 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 34076 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 804:
#line 6103 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 34084 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 806:
#line 6109 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex=Lex;
lex->last_field->flags|= UNIQUE_KEY_FLAG;
lex->alter_info.flags|= ALTER_ADD_INDEX;
}
#line 34096 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 807:
#line 6115 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex=Lex;
lex->last_field->flags|= UNIQUE_KEY_FLAG;
lex->alter_info.flags|= ALTER_ADD_INDEX;
}
#line 34108 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 808:
#line 6120 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->last_field->comment= (yyvsp[0].lex_str); }
#line 34116 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 809:
#line 6122 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->last_field->invisible= INVISIBLE_USER;
}
#line 34126 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 810:
#line 6129 "/home/buildbot/git/sql/sql_yacc.yy"
{
/*
"PARSE_VCOL_EXPR" can only be used by the SQL server
when reading a '*.frm' file.
Prevent the end user from invoking this command.
*/
MYSQL_YYABORT_UNLESS(Lex->parse_vcol_expr);
if (Lex->main_select_push())
MYSQL_YYABORT;
}
#line 34143 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 811:
#line 6140 "/home/buildbot/git/sql/sql_yacc.yy"
{
Virtual_column_info *v= add_virtual_expression(thd, (yyvsp[0].item));
if (unlikely(!v))
MYSQL_YYABORT;
Lex->last_field->vcol_info= v;
Lex->pop_select(); //main select
}
#line 34157 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 813:
#line 6152 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyvsp[0].item_list)->push_front((yyvsp[-2].item), thd->mem_root);
(yyval.item)= new (thd->mem_root) Item_row(thd, *(yyvsp[0].item_list));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 34170 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 814:
#line 6162 "/home/buildbot/git/sql/sql_yacc.yy"
{
Virtual_column_info *v=
add_virtual_expression(thd, (yyvsp[-1].item));
if (unlikely(!v))
MYSQL_YYABORT;
(yyval.virtual_column)= v;
}
#line 34184 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 815:
#line 6170 "/home/buildbot/git/sql/sql_yacc.yy"
{
Item *item;
if (!(item= new (thd->mem_root) Item_singlerow_subselect(thd, (yyvsp[0].select_lex))))
MYSQL_YYABORT;
Virtual_column_info *v= add_virtual_expression(thd, item);
if (unlikely(!v))
MYSQL_YYABORT;
(yyval.virtual_column)= v;
}
#line 34200 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 819:
#line 6186 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(!((yyval.virtual_column)= add_virtual_expression(thd, (yyvsp[0].item)))))
MYSQL_YYABORT;
}
#line 34211 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 820:
#line 6193 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->map_data_type(Lex_ident_sys(), &((yyval.Lex_field_type)= (yyvsp[0].Lex_field_type)));
}
#line 34221 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 821:
#line 6200 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->map_data_type(Lex_ident_sys(), &((yyval.Lex_field_type)= (yyvsp[0].Lex_field_type)));
}
#line 34231 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 822:
#line 6204 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (Lex->map_data_type((yyvsp[-2].ident_sys), &((yyval.Lex_field_type)= (yyvsp[0].Lex_field_type))))
MYSQL_YYABORT;
}
#line 34242 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 828:
#line 6217 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (Lex->set_field_type_udt(&(yyval.Lex_field_type), (yyvsp[-2].ident_sys), (yyvsp[-1].Lex_length_and_dec)))
MYSQL_YYABORT;
}
#line 34253 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 829:
#line 6222 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (Lex->set_field_type_udt(&(yyval.Lex_field_type), (yyvsp[-2].kwd), (yyvsp[-1].Lex_length_and_dec)))
MYSQL_YYABORT;
}
#line 34264 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 830:
#line 6227 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (Lex->set_field_type_udt(&(yyval.Lex_field_type), (yyvsp[-2].kwd), (yyvsp[-1].Lex_length_and_dec)))
MYSQL_YYABORT;
}
#line 34275 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 831:
#line 6235 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.Lex_field_type).set_handler_length_flags((yyvsp[-2].type_handler), (yyvsp[-1].const_simple_string), (uint32) (yyvsp[0].ulong_num));
}
#line 34285 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 832:
#line 6238 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.Lex_field_type).set((yyvsp[-2].type_handler), (yyvsp[-1].Lex_length_and_dec)); }
#line 34293 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 833:
#line 6240 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.Lex_field_type).set(&type_handler_float, (yyvsp[-1].Lex_length_and_dec));
if ((yyvsp[-1].Lex_length_and_dec).length() && !(yyvsp[-1].Lex_length_and_dec).dec())
{
int err;
ulonglong tmp_length= my_strtoll10((yyvsp[-1].Lex_length_and_dec).length(), NULL, &err);
if (unlikely(err || tmp_length > PRECISION_FOR_DOUBLE))
my_yyabort_error((ER_WRONG_FIELD_SPEC, MYF(0),
Lex->last_field->field_name.str));
if (tmp_length > PRECISION_FOR_FLOAT)
(yyval.Lex_field_type).set(&type_handler_double);
else
(yyval.Lex_field_type).set(&type_handler_float);
}
}
#line 34315 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 834:
#line 6256 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.Lex_field_type).set(&type_handler_bit, (yyvsp[0].const_simple_string));
}
#line 34325 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 835:
#line 6260 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.Lex_field_type).set(&type_handler_stiny, "1");
}
#line 34335 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 836:
#line 6264 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.Lex_field_type).set(&type_handler_stiny, "1");
}
#line 34345 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 837:
#line 6268 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.Lex_field_type).set(&type_handler_newdecimal, (yyvsp[-1].Lex_length_and_dec));}
#line 34353 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 838:
#line 6270 "/home/buildbot/git/sql/sql_yacc.yy"
{
if ((yyvsp[-1].Lex_length_and_dec).length() != 0)
(yyval.Lex_field_type).set(&type_handler_newdecimal, (yyvsp[-1].Lex_length_and_dec));
else
(yyval.Lex_field_type).set(&type_handler_double);
}
#line 34366 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 839:
#line 6277 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.Lex_field_type).set(&type_handler_newdecimal, (yyvsp[-1].Lex_length_and_dec));}
#line 34374 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 840:
#line 6279 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.Lex_field_type).set(&type_handler_newdecimal, (yyvsp[-1].Lex_length_and_dec));}
#line 34382 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 845:
#line 6292 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.Lex_field_type).set(&type_handler_string, (yyvsp[-1].const_simple_string));
}
#line 34392 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 846:
#line 6296 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.Lex_field_type).set(&type_handler_string, (yyvsp[-1].const_simple_string));
bincmp_collation(national_charset_info, (yyvsp[0].num));
}
#line 34403 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 847:
#line 6301 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->charset=&my_charset_bin;
(yyval.Lex_field_type).set(&type_handler_string, (yyvsp[0].const_simple_string));
}
#line 34414 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 848:
#line 6306 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.Lex_field_type).set(&type_handler_varchar, (yyvsp[-1].const_simple_string));
}
#line 34424 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 849:
#line 6310 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.Lex_field_type).set(&type_handler_varchar, (yyvsp[-1].const_simple_string));
}
#line 34434 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 850:
#line 6314 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.Lex_field_type).set(&type_handler_varchar, (yyvsp[-2].const_simple_string));
bincmp_collation(national_charset_info, (yyvsp[0].num));
}
#line 34445 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 851:
#line 6319 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->charset=&my_charset_bin;
(yyval.Lex_field_type).set(&type_handler_varchar, (yyvsp[-1].const_simple_string));
}
#line 34456 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 852:
#line 6324 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->charset= &my_charset_bin;
(yyval.Lex_field_type).set(&type_handler_varchar, (yyvsp[-1].const_simple_string));
}
#line 34467 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 853:
#line 6332 "/home/buildbot/git/sql/sql_yacc.yy"
{
if ((yyvsp[-1].const_simple_string))
{
errno= 0;
ulong length= strtoul((yyvsp[-1].const_simple_string), NULL, 10);
if (errno == 0 && length <= MAX_FIELD_BLOBLENGTH && length != 4)
{
char buff[sizeof("YEAR()") + MY_INT64_NUM_DECIMAL_DIGITS + 1];
my_snprintf(buff, sizeof(buff), "YEAR(%lu)", length);
push_warning_printf(thd, Sql_condition::WARN_LEVEL_NOTE,
ER_WARN_DEPRECATED_SYNTAX,
ER_THD(thd, ER_WARN_DEPRECATED_SYNTAX),
buff, "YEAR(4)");
}
}
(yyval.Lex_field_type).set(&type_handler_year, (yyvsp[-1].const_simple_string));
}
#line 34491 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 854:
#line 6349 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.Lex_field_type).set(&type_handler_newdate); }
#line 34499 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 855:
#line 6351 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.Lex_field_type).set(opt_mysql56_temporal_format ?
static_cast(&type_handler_time2) :
static_cast(&type_handler_time),
(yyvsp[0].const_simple_string));
}
#line 34512 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 856:
#line 6358 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.Lex_field_type).set(opt_mysql56_temporal_format ?
static_cast(&type_handler_timestamp2):
static_cast(&type_handler_timestamp),
(yyvsp[0].const_simple_string));
}
#line 34525 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 857:
#line 6365 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.Lex_field_type).set(thd->type_handler_for_datetime(), (yyvsp[0].const_simple_string));
}
#line 34535 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 858:
#line 6373 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->charset=&my_charset_bin;
(yyval.Lex_field_type).set(&type_handler_tiny_blob);
}
#line 34546 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 859:
#line 6378 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->charset=&my_charset_bin;
(yyval.Lex_field_type).set(&type_handler_blob, (yyvsp[-1].const_simple_string));
}
#line 34557 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 860:
#line 6383 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->charset=&my_charset_bin;
(yyval.Lex_field_type).set(&type_handler_blob, (yyvsp[-1].const_simple_string));
}
#line 34568 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 861:
#line 6388 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->charset=&my_charset_bin;
(yyval.Lex_field_type).set(&type_handler_long_blob);
}
#line 34579 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 862:
#line 6393 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->charset=&my_charset_bin;
(yyval.Lex_field_type).set(&type_handler_medium_blob);
}
#line 34590 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 863:
#line 6398 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->charset=&my_charset_bin;
(yyval.Lex_field_type).set(&type_handler_long_blob);
}
#line 34601 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 864:
#line 6403 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->charset=&my_charset_bin;
(yyval.Lex_field_type).set(&type_handler_medium_blob);
}
#line 34612 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 865:
#line 6408 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.Lex_field_type).set(&type_handler_medium_blob); }
#line 34620 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 866:
#line 6410 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.Lex_field_type).set(&type_handler_tiny_blob); }
#line 34628 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 867:
#line 6412 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.Lex_field_type).set(&type_handler_blob, (yyvsp[-1].const_simple_string)); }
#line 34636 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 868:
#line 6414 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.Lex_field_type).set(&type_handler_medium_blob); }
#line 34644 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 869:
#line 6416 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.Lex_field_type).set(&type_handler_long_blob); }
#line 34652 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 870:
#line 6418 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.Lex_field_type).set(&type_handler_long_blob); }
#line 34660 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 871:
#line 6420 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.Lex_field_type).set(&type_handler_medium_blob); }
#line 34668 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 872:
#line 6422 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->charset= &my_charset_utf8mb4_bin;
(yyval.Lex_field_type).set(&type_handler_json_longtext);
}
#line 34679 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 873:
#line 6430 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.Lex_field_type).set(&type_handler_enum); }
#line 34687 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 874:
#line 6432 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.Lex_field_type).set(&type_handler_set); }
#line 34695 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 875:
#line 6436 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 34703 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 876:
#line 6440 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 34711 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 877:
#line 6441 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 34719 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 878:
#line 6445 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 34727 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 879:
#line 6446 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 34735 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 880:
#line 6450 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 34743 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 881:
#line 6451 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 34751 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 882:
#line 6452 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 34759 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 883:
#line 6453 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 34767 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 884:
#line 6454 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 34775 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 885:
#line 6458 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.type_handler)= &type_handler_slong; }
#line 34783 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 886:
#line 6459 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.type_handler)= &type_handler_stiny; }
#line 34791 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 887:
#line 6460 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.type_handler)= &type_handler_sshort; }
#line 34799 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 888:
#line 6461 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.type_handler)= &type_handler_sint24; }
#line 34807 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 889:
#line 6462 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.type_handler)= &type_handler_slonglong; }
#line 34815 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 890:
#line 6467 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.type_handler)= thd->variables.sql_mode & MODE_REAL_AS_FLOAT ?
static_cast(&type_handler_float) :
static_cast(&type_handler_double);
}
#line 34827 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 891:
#line 6472 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.type_handler)= &type_handler_double; }
#line 34835 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 892:
#line 6473 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.type_handler)= &type_handler_double; }
#line 34843 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 893:
#line 6478 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->last_field->srid= 0; }
#line 34851 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 894:
#line 6481 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->last_field->srid=atoi((yyvsp[0].lex_str).str);
}
#line 34861 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 895:
#line 6487 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.Lex_length_and_dec).set(0, 0); }
#line 34869 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 896:
#line 6488 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.Lex_length_and_dec).set((yyvsp[0].const_simple_string), 0); }
#line 34877 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 897:
#line 6489 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.Lex_length_and_dec)= (yyvsp[0].Lex_length_and_dec); }
#line 34885 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 898:
#line 6493 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.Lex_length_and_dec).set((yyvsp[-3].lex_str).str, (yyvsp[-1].lex_str).str); }
#line 34893 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 899:
#line 6497 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.ulong_num)= 0; }
#line 34901 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 900:
#line 6498 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.ulong_num)= 0; }
#line 34909 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 901:
#line 6499 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.ulong_num)= UNSIGNED_FLAG; }
#line 34917 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 902:
#line 6500 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.ulong_num)= UNSIGNED_FLAG | ZEROFILL_FLAG; }
#line 34925 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 903:
#line 6501 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.ulong_num)= UNSIGNED_FLAG | ZEROFILL_FLAG; }
#line 34933 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 904:
#line 6502 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.ulong_num)= UNSIGNED_FLAG | ZEROFILL_FLAG; }
#line 34941 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 905:
#line 6506 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->last_field->flags|= ((yyval.ulong_num)= (yyvsp[0].ulong_num)); }
#line 34949 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 906:
#line 6510 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.const_simple_string)= (yyvsp[-1].lex_str).str; }
#line 34957 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 907:
#line 6511 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.const_simple_string)= (yyvsp[-1].lex_str).str; }
#line 34965 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 908:
#line 6512 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.const_simple_string)= (yyvsp[-1].lex_str).str; }
#line 34973 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 909:
#line 6513 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.const_simple_string)= (yyvsp[-1].lex_str).str; }
#line 34981 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 910:
#line 6517 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.const_simple_string)= (char*) 0; /* use default length */ }
#line 34989 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 911:
#line 6518 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.const_simple_string)= (yyvsp[0].const_simple_string); }
#line 34997 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 912:
#line 6522 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.Lex_length_and_dec).set(0, 0); }
#line 35005 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 913:
#line 6523 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.Lex_length_and_dec)= (yyvsp[0].Lex_length_and_dec); }
#line 35013 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 914:
#line 6528 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 35021 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 916:
#line 6533 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->last_field->flags&= ~ NOT_NULL_FLAG; }
#line 35029 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 917:
#line 6534 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->last_field->default_value= (yyvsp[0].virtual_column); }
#line 35037 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 918:
#line 6536 "/home/buildbot/git/sql/sql_yacc.yy"
{
Item *item= new (thd->mem_root) Item_func_now_local(thd, (yyvsp[0].num));
if (unlikely(item == NULL))
MYSQL_YYABORT;
Lex->last_field->on_update= item;
}
#line 35050 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 919:
#line 6542 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->last_field->flags|= AUTO_INCREMENT_FLAG | NOT_NULL_FLAG; }
#line 35058 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 920:
#line 6544 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex=Lex;
lex->last_field->flags|= AUTO_INCREMENT_FLAG | NOT_NULL_FLAG | UNIQUE_KEY_FLAG;
lex->alter_info.flags|= ALTER_ADD_INDEX;
}
#line 35070 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 921:
#line 6550 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->charset && !my_charset_same(Lex->charset,(yyvsp[0].charset))))
my_yyabort_error((ER_COLLATION_CHARSET_MISMATCH, MYF(0),
(yyvsp[0].charset)->name,Lex->charset->csname));
Lex->last_field->charset= (yyvsp[0].charset);
}
#line 35083 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 923:
#line 6560 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.const_simple_string)= NULL; }
#line 35091 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 924:
#line 6561 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.const_simple_string)= (yyvsp[0].ident_sys).str; }
#line 35099 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 925:
#line 6565 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 35107 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 926:
#line 6566 "/home/buildbot/git/sql/sql_yacc.yy"
{ }
#line 35115 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 927:
#line 6570 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 35123 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 928:
#line 6571 "/home/buildbot/git/sql/sql_yacc.yy"
{ }
#line 35131 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 929:
#line 6576 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->last_field->set_compressed((yyvsp[0].const_simple_string))))
MYSQL_YYABORT;
}
#line 35142 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 930:
#line 6584 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->last_field->set_compressed_deprecated(thd, (yyvsp[0].const_simple_string))))
MYSQL_YYABORT;
}
#line 35153 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 931:
#line 6592 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->last_field->
set_compressed_deprecated_column_attribute(thd, (yyvsp[-1].kwd).pos(), (yyvsp[0].const_simple_string))))
MYSQL_YYABORT;
}
#line 35165 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 932:
#line 6601 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->last_field->flags|= NOT_NULL_FLAG;
}
#line 35175 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 933:
#line 6605 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex=Lex;
lex->last_field->flags|= PRI_KEY_FLAG | NOT_NULL_FLAG;
lex->alter_info.flags|= ALTER_ADD_INDEX;
}
#line 35187 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 936:
#line 6616 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely((yyvsp[0].lex_str).length > ENGINE_OPTION_MAX_LENGTH))
my_yyabort_error((ER_VALUE_TOO_LONG, MYF(0), (yyvsp[-2].ident_sys).str));
(void) new (thd->mem_root)
engine_option_value((yyvsp[-2].ident_sys), (yyvsp[0].lex_str), true,
&Lex->last_field->option_list,
&Lex->option_list_last);
}
#line 35202 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 937:
#line 6625 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely((yyvsp[0].ident_sys).length > ENGINE_OPTION_MAX_LENGTH))
my_yyabort_error((ER_VALUE_TOO_LONG, MYF(0), (yyvsp[-2].ident_sys).str));
(void) new (thd->mem_root)
engine_option_value((yyvsp[-2].ident_sys), (yyvsp[0].ident_sys), false,
&Lex->last_field->option_list,
&Lex->option_list_last);
}
#line 35217 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 938:
#line 6634 "/home/buildbot/git/sql/sql_yacc.yy"
{
(void) new (thd->mem_root)
engine_option_value((yyvsp[-2].ident_sys), (yyvsp[0].ulonglong_number), &Lex->last_field->option_list,
&Lex->option_list_last, thd->mem_root);
}
#line 35229 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 939:
#line 6640 "/home/buildbot/git/sql/sql_yacc.yy"
{
(void) new (thd->mem_root)
engine_option_value((yyvsp[-2].ident_sys), &Lex->last_field->option_list,
&Lex->option_list_last);
}
#line 35241 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 940:
#line 6646 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->last_field->versioning= (yyvsp[-1].vers_column_versioning);
Lex->create_info.options|= HA_VERSIONED_TABLE;
if (Lex->alter_info.flags & ALTER_DROP_SYSTEM_VERSIONING)
{
my_yyabort_error((ER_VERS_NOT_VERSIONED, MYF(0),
Lex->create_last_non_select_table->table_name.str));
}
}
#line 35257 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 941:
#line 6659 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->alter_info.flags|= ALTER_COLUMN_UNVERSIONED;
Lex->create_info.vers_info.versioned_fields= true;
(yyval.vers_column_versioning)= Column_definition::WITH_VERSIONING;
}
#line 35269 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 942:
#line 6665 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->alter_info.flags|= ALTER_COLUMN_UNVERSIONED;
Lex->create_info.vers_info.unversioned_fields= true;
(yyval.vers_column_versioning)= Column_definition::WITHOUT_VERSIONING;
}
#line 35281 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 943:
#line 6674 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.kwd)= (yyvsp[-1].kwd); }
#line 35289 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 944:
#line 6675 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.kwd)= (yyvsp[0].kwd); }
#line 35297 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 945:
#line 6680 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(!((yyval.charset)=get_charset_by_csname((yyvsp[0].lex_str).str,MY_CS_PRIMARY,MYF(0)))))
my_yyabort_error((ER_UNKNOWN_CHARACTER_SET, MYF(0), (yyvsp[0].lex_str).str));
}
#line 35308 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 946:
#line 6684 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.charset)= &my_charset_bin; }
#line 35316 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 947:
#line 6688 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.charset)=(yyvsp[0].charset); }
#line 35324 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 948:
#line 6689 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.charset)=NULL; }
#line 35332 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 949:
#line 6693 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.charset)= NULL; }
#line 35340 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 950:
#line 6694 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.charset)= (yyvsp[0].charset); }
#line 35348 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 951:
#line 6699 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(!((yyval.charset)=get_charset_by_csname((yyvsp[0].lex_str).str,
MY_CS_PRIMARY,MYF(0))) &&
!((yyval.charset)=get_old_charset_by_name((yyvsp[0].lex_str).str))))
my_yyabort_error((ER_UNKNOWN_CHARACTER_SET, MYF(0), (yyvsp[0].lex_str).str));
}
#line 35361 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 952:
#line 6705 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.charset)= &my_charset_bin; }
#line 35369 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 953:
#line 6709 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.charset)=(yyvsp[0].charset); }
#line 35377 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 954:
#line 6710 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.charset)=NULL; }
#line 35385 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 955:
#line 6715 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(!((yyval.charset)= mysqld_collation_get_by_name((yyvsp[0].lex_str).str))))
MYSQL_YYABORT;
}
#line 35396 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 956:
#line 6722 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.charset)=NULL; }
#line 35404 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 957:
#line 6723 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.charset)=(yyvsp[0].charset); }
#line 35412 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 958:
#line 6727 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.charset)=(yyvsp[0].charset); }
#line 35420 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 959:
#line 6728 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.charset)=NULL; }
#line 35428 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 960:
#line 6732 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 35436 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 961:
#line 6733 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 35444 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 962:
#line 6737 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.charset)= (yyvsp[0].charset); }
#line 35452 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 963:
#line 6738 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.charset)= &my_charset_latin1; }
#line 35460 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 964:
#line 6740 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(!((yyval.charset)= get_charset_by_csname("ucs2", MY_CS_PRIMARY,MYF(0)))))
my_yyabort_error((ER_UNKNOWN_CHARACTER_SET, MYF(0), "ucs2"));
}
#line 35471 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 965:
#line 6747 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->charset= (yyvsp[0].charset);
}
#line 35481 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 966:
#line 6753 "/home/buildbot/git/sql/sql_yacc.yy"
{ bincmp_collation(NULL, false); }
#line 35489 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 967:
#line 6754 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 35497 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 968:
#line 6758 "/home/buildbot/git/sql/sql_yacc.yy"
{ bincmp_collation(&my_charset_bin, false); }
#line 35505 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 969:
#line 6759 "/home/buildbot/git/sql/sql_yacc.yy"
{ bincmp_collation((yyvsp[-1].charset), (yyvsp[0].num)); }
#line 35513 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 970:
#line 6760 "/home/buildbot/git/sql/sql_yacc.yy"
{ bincmp_collation(NULL, true); }
#line 35521 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 971:
#line 6761 "/home/buildbot/git/sql/sql_yacc.yy"
{ bincmp_collation((yyvsp[0].charset), true); }
#line 35529 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 972:
#line 6763 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (!my_charset_same(Lex->charset, (yyvsp[-1].charset)))
my_yyabort_error((ER_COLLATION_CHARSET_MISMATCH, MYF(0),
Lex->charset->name, (yyvsp[-1].charset)->csname));
}
#line 35541 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 973:
#line 6768 "/home/buildbot/git/sql/sql_yacc.yy"
{ }
#line 35549 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 974:
#line 6772 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.num)= false; }
#line 35557 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 975:
#line 6773 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.num)= true; }
#line 35565 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 976:
#line 6778 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely((yyvsp[0].ulong_num) == 0))
{
thd->parse_error();
MYSQL_YYABORT;
}
}
#line 35579 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 977:
#line 6786 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.ulong_num)= (yyvsp[-2].ulong_num); }
#line 35587 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 978:
#line 6790 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.ulong_num)= 0; }
#line 35595 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 979:
#line 6791 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.ulong_num)= 1 << MY_STRXFRM_DESC_SHIFT; }
#line 35603 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 980:
#line 6795 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.ulong_num)= 1 << MY_STRXFRM_REVERSE_SHIFT; }
#line 35611 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 981:
#line 6798 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.ulong_num)= 0; }
#line 35619 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 982:
#line 6799 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.ulong_num)= (yyvsp[0].ulong_num); }
#line 35627 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 983:
#line 6800 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.ulong_num)= (yyvsp[-1].ulong_num) | (yyvsp[0].ulong_num); }
#line 35635 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 984:
#line 6801 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.ulong_num)= (yyvsp[0].ulong_num) ; }
#line 35643 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 985:
#line 6806 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.ulong_num)= (yyvsp[0].ulong_num) < 1 ? 1 : ((yyvsp[0].ulong_num) > MY_STRXFRM_NLEVELS ? MY_STRXFRM_NLEVELS : (yyvsp[0].ulong_num));
(yyval.ulong_num)--;
}
#line 35654 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 986:
#line 6814 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.ulong_num)= (1 | (yyvsp[0].ulong_num)) << (yyvsp[-1].ulong_num);
}
#line 35664 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 987:
#line 6820 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.ulong_num)= (yyvsp[0].ulong_num); }
#line 35672 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 988:
#line 6821 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.ulong_num)|= (yyvsp[0].ulong_num); }
#line 35680 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 989:
#line 6826 "/home/buildbot/git/sql/sql_yacc.yy"
{
uint start= (yyvsp[-2].ulong_num);
uint end= (yyvsp[0].ulong_num);
for ((yyval.ulong_num)= 0; start <= end; start++)
(yyval.ulong_num)|= (1 << start);
}
#line 35693 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 990:
#line 6835 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.ulong_num)= (yyvsp[0].ulong_num); }
#line 35701 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 991:
#line 6836 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.ulong_num)= (yyvsp[0].ulong_num); }
#line 35709 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 992:
#line 6840 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.ulong_num)= 0; }
#line 35717 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 993:
#line 6841 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.ulong_num)= (yyvsp[0].ulong_num); }
#line 35725 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 996:
#line 6855 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.table)=(yyvsp[-3].table);
}
#line 35735 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 997:
#line 6862 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->ref_list.empty(); }
#line 35743 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 999:
#line 6868 "/home/buildbot/git/sql/sql_yacc.yy"
{
Key_part_spec *key= new (thd->mem_root) Key_part_spec(&(yyvsp[0].ident_sys), 0);
if (unlikely(key == NULL))
MYSQL_YYABORT;
Lex->ref_list.push_back(key, thd->mem_root);
}
#line 35756 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1000:
#line 6875 "/home/buildbot/git/sql/sql_yacc.yy"
{
Key_part_spec *key= new (thd->mem_root) Key_part_spec(&(yyvsp[0].ident_sys), 0);
if (unlikely(key == NULL))
MYSQL_YYABORT;
LEX *lex= Lex;
lex->ref_list.empty();
lex->ref_list.push_back(key, thd->mem_root);
}
#line 35771 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1001:
#line 6887 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->fk_match_option= Foreign_key::FK_MATCH_UNDEF; }
#line 35779 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1002:
#line 6889 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->fk_match_option= Foreign_key::FK_MATCH_FULL; }
#line 35787 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1003:
#line 6891 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->fk_match_option= Foreign_key::FK_MATCH_PARTIAL; }
#line 35795 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1004:
#line 6893 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->fk_match_option= Foreign_key::FK_MATCH_SIMPLE; }
#line 35803 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1005:
#line 6898 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
lex->fk_update_opt= FK_OPTION_UNDEF;
lex->fk_delete_opt= FK_OPTION_UNDEF;
}
#line 35815 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1006:
#line 6904 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
lex->fk_update_opt= (yyvsp[0].m_fk_option);
lex->fk_delete_opt= FK_OPTION_UNDEF;
}
#line 35827 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1007:
#line 6910 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
lex->fk_update_opt= FK_OPTION_UNDEF;
lex->fk_delete_opt= (yyvsp[0].m_fk_option);
}
#line 35839 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1008:
#line 6917 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
lex->fk_update_opt= (yyvsp[-3].m_fk_option);
lex->fk_delete_opt= (yyvsp[0].m_fk_option);
}
#line 35851 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1009:
#line 6924 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
lex->fk_update_opt= (yyvsp[0].m_fk_option);
lex->fk_delete_opt= (yyvsp[-3].m_fk_option);
}
#line 35863 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1010:
#line 6932 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.m_fk_option)= FK_OPTION_RESTRICT; }
#line 35871 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1011:
#line 6933 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.m_fk_option)= FK_OPTION_CASCADE; }
#line 35879 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1012:
#line 6934 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.m_fk_option)= FK_OPTION_SET_NULL; }
#line 35887 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1013:
#line 6935 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.m_fk_option)= FK_OPTION_NO_ACTION; }
#line 35895 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1014:
#line 6936 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.m_fk_option)= FK_OPTION_SET_DEFAULT; }
#line 35903 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1015:
#line 6940 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.key_type)= Key::PRIMARY; }
#line 35911 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1016:
#line 6941 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.key_type)= Key::UNIQUE; }
#line 35919 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1017:
#line 6945 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 35927 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1018:
#line 6946 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 35935 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1019:
#line 6950 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 35943 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1021:
#line 6955 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 35951 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1022:
#line 6956 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 35959 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1023:
#line 6957 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 35967 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1024:
#line 6961 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.key_type)= Key::FULLTEXT;}
#line 35975 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1025:
#line 6966 "/home/buildbot/git/sql/sql_yacc.yy"
{
#ifdef HAVE_SPATIAL
(yyval.key_type)= Key::SPATIAL;
#else
my_yyabort_error((ER_FEATURE_DISABLED, MYF(0), sym_group_geom.name,
sym_group_geom.needed_define));
#endif
}
#line 35990 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1026:
#line 6977 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 35998 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1027:
#line 6978 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->last_key->option_list= Lex->option_list; }
#line 36006 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1028:
#line 6982 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 36014 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1029:
#line 6983 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->last_key->option_list= Lex->option_list; }
#line 36022 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1030:
#line 6987 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 36030 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1031:
#line 6988 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->last_key->option_list= Lex->option_list; }
#line 36038 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1038:
#line 7007 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.key_alg)= HA_KEY_ALG_UNDEF; }
#line 36046 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1039:
#line 7008 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.key_alg)= (yyvsp[0].key_alg); }
#line 36054 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1040:
#line 7013 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.key_alg)= HA_KEY_ALG_UNDEF; }
#line 36062 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1041:
#line 7014 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.key_alg)= (yyvsp[0].key_alg); }
#line 36070 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1042:
#line 7015 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.key_alg)= (yyvsp[0].key_alg); }
#line 36078 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1043:
#line 7020 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->last_key->key_create_info.algorithm= (yyvsp[0].key_alg); }
#line 36086 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1044:
#line 7022 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->last_key->key_create_info.algorithm= (yyvsp[0].key_alg); }
#line 36094 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1045:
#line 7027 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->last_key->key_create_info.block_size= (yyvsp[0].ulong_num);
Lex->last_key->key_create_info.flags|= HA_USES_BLOCK_SIZE;
}
#line 36105 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1046:
#line 7032 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->last_key->key_create_info.comment= (yyvsp[0].lex_str); }
#line 36113 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1047:
#line 7034 "/home/buildbot/git/sql/sql_yacc.yy"
{
/* This is mainly for MySQL 8.0 compatiblity */
}
#line 36123 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1048:
#line 7038 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely((yyvsp[0].lex_str).length > ENGINE_OPTION_MAX_LENGTH))
my_yyabort_error((ER_VALUE_TOO_LONG, MYF(0), (yyvsp[-2].ident_sys).str));
(void) new (thd->mem_root)
engine_option_value((yyvsp[-2].ident_sys), (yyvsp[0].lex_str), true, &Lex->option_list,
&Lex->option_list_last);
}
#line 36137 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1049:
#line 7046 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely((yyvsp[0].ident_sys).length > ENGINE_OPTION_MAX_LENGTH))
my_yyabort_error((ER_VALUE_TOO_LONG, MYF(0), (yyvsp[-2].ident_sys).str));
(void) new (thd->mem_root)
engine_option_value((yyvsp[-2].ident_sys), (yyvsp[0].ident_sys), false, &Lex->option_list,
&Lex->option_list_last);
}
#line 36151 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1050:
#line 7054 "/home/buildbot/git/sql/sql_yacc.yy"
{
(void) new (thd->mem_root)
engine_option_value((yyvsp[-2].ident_sys), (yyvsp[0].ulonglong_number), &Lex->option_list,
&Lex->option_list_last, thd->mem_root);
}
#line 36163 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1051:
#line 7060 "/home/buildbot/git/sql/sql_yacc.yy"
{
(void) new (thd->mem_root)
engine_option_value((yyvsp[-2].ident_sys), &Lex->option_list,
&Lex->option_list_last);
}
#line 36175 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1056:
#line 7079 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (likely(plugin_is_ready(&(yyvsp[0].ident_sys), MYSQL_FTPARSER_PLUGIN)))
Lex->last_key->key_create_info.parser_name= (yyvsp[0].ident_sys);
else
my_yyabort_error((ER_FUNCTION_NOT_DEFINED, MYF(0), (yyvsp[0].ident_sys).str));
}
#line 36188 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1057:
#line 7088 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.key_alg)= HA_KEY_ALG_BTREE; }
#line 36196 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1058:
#line 7089 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.key_alg)= HA_KEY_ALG_RTREE; }
#line 36204 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1059:
#line 7090 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.key_alg)= HA_KEY_ALG_HASH; }
#line 36212 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1060:
#line 7095 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->last_key->columns.push_back((yyvsp[-1].key_part), thd->mem_root);
}
#line 36222 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1061:
#line 7099 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->last_key->columns.push_back((yyvsp[-1].key_part), thd->mem_root);
}
#line 36232 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1062:
#line 7105 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 36240 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1063:
#line 7107 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->last_key->without_overlaps= true;
Lex->last_key->period= (yyvsp[-2].ident_sys);
}
#line 36251 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1064:
#line 7115 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.key_part)= new (thd->mem_root) Key_part_spec(&(yyvsp[0].ident_sys), 0);
if (unlikely((yyval.key_part) == NULL))
MYSQL_YYABORT;
}
#line 36263 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1065:
#line 7121 "/home/buildbot/git/sql/sql_yacc.yy"
{
int key_part_len= atoi((yyvsp[-1].lex_str).str);
if (unlikely(!key_part_len))
my_yyabort_error((ER_KEY_PART_0, MYF(0), (yyvsp[-3].ident_sys).str));
(yyval.key_part)= new (thd->mem_root) Key_part_spec(&(yyvsp[-3].ident_sys), (uint) key_part_len);
if (unlikely((yyval.key_part) == NULL))
MYSQL_YYABORT;
}
#line 36278 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1066:
#line 7132 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.lex_str)= null_clex_str; }
#line 36286 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1067:
#line 7133 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.lex_str)= (yyvsp[0].lex_str); }
#line 36294 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1068:
#line 7138 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->last_field->interval_list.push_back((yyvsp[0].string), thd->mem_root); }
#line 36302 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1069:
#line 7140 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->last_field->interval_list.push_back((yyvsp[0].string), thd->mem_root); }
#line 36310 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1070:
#line 7149 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->name= null_clex_str;
Lex->table_type= TABLE_TYPE_UNKNOWN;
Lex->sql_command= SQLCOM_ALTER_TABLE;
Lex->duplicates= DUP_ERROR;
Lex->first_select_lex()->order_list.empty();
Lex->create_info.init();
Lex->create_info.row_type= ROW_TYPE_NOT_USED;
Lex->alter_info.reset();
Lex->no_write_to_binlog= 0;
Lex->create_info.storage_media= HA_SM_DEFAULT;
if (Lex->main_select_push())
MYSQL_YYABORT;
DBUG_ASSERT(!Lex->m_sql_cmd);
}
#line 36332 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1071:
#line 7165 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->create_info.set((yyvsp[-2].object_ddl_options));
if (!Lex->first_select_lex()->
add_table_to_list(thd, (yyvsp[-1].table), NULL, TL_OPTION_UPDATING,
TL_READ_NO_INSERT, MDL_SHARED_UPGRADABLE))
MYSQL_YYABORT;
Lex->first_select_lex()->db=
(Lex->first_select_lex()->table_list.first)->db;
Lex->create_last_non_select_table= Lex->last_table();
Lex->mark_first_table_as_inserting();
}
#line 36350 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1072:
#line 7177 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (likely(!Lex->m_sql_cmd))
{
/* Create a generic ALTER TABLE statment. */
Lex->m_sql_cmd= new (thd->mem_root) Sql_cmd_alter_table();
if (unlikely(Lex->m_sql_cmd == NULL))
MYSQL_YYABORT;
}
Lex->pop_select(); //main select
}
#line 36367 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1073:
#line 7188 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->create_info.default_table_charset= NULL;
Lex->create_info.schema_comment= NULL;
Lex->create_info.used_fields= 0;
if (Lex->main_select_push(true))
MYSQL_YYABORT;
}
#line 36381 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1074:
#line 7196 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex=Lex;
lex->sql_command=SQLCOM_ALTER_DB;
lex->name= (yyvsp[-2].ident_sys);
if (lex->name.str == NULL &&
unlikely(lex->copy_db_to(&lex->name)))
MYSQL_YYABORT;
Lex->pop_select(); //main select
}
#line 36397 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1075:
#line 7206 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->create_info.default_table_charset= NULL;
Lex->create_info.used_fields= 0;
Lex->create_info.schema_comment= thd->make_clex_string((yyvsp[0].lex_str));
Lex->create_info.used_fields|= HA_CREATE_USED_COMMENT;
}
#line 36410 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1076:
#line 7213 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex=Lex;
lex->sql_command=SQLCOM_ALTER_DB;
lex->name= Lex_ident_sys();
if (lex->name.str == NULL &&
unlikely(lex->copy_db_to(&lex->name)))
MYSQL_YYABORT;
}
#line 36425 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1077:
#line 7222 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
if (unlikely(lex->sphead))
my_yyabort_error((ER_SP_NO_DROP_SP, MYF(0), "DATABASE"));
lex->sql_command= SQLCOM_ALTER_DB_UPGRADE;
lex->name= (yyvsp[-4].ident_sys);
}
#line 36439 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1078:
#line 7230 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (Lex->stmt_alter_procedure_start((yyvsp[0].spname)))
MYSQL_YYABORT;
}
#line 36450 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1079:
#line 7235 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 36458 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1080:
#line 7237 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (Lex->stmt_alter_function_start((yyvsp[0].spname)))
MYSQL_YYABORT;
}
#line 36469 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1081:
#line 7242 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 36477 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1082:
#line 7244 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (Lex->main_select_push())
MYSQL_YYABORT;
if (Lex->add_alter_view(thd, (yyvsp[-4].num), (yyvsp[-2].view_suid), (yyvsp[0].table)))
MYSQL_YYABORT;
}
#line 36490 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1083:
#line 7250 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 36498 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1084:
#line 7257 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (Lex->main_select_push())
MYSQL_YYABORT;
if (Lex->add_alter_view(thd, VIEW_ALGORITHM_INHERIT, (yyvsp[-2].view_suid), (yyvsp[0].table)))
MYSQL_YYABORT;
}
#line 36511 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1085:
#line 7263 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 36519 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1086:
#line 7265 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (Lex->main_select_push())
MYSQL_YYABORT;
/*
It is safe to use Lex->spname because
ALTER EVENT xxx RENATE TO yyy DO ALTER EVENT RENAME TO
is not allowed. Lex->spname is used in the case of RENAME TO
If it had to be supported spname had to be added to
Event_parse_data.
*/
if (unlikely(!(Lex->event_parse_data= Event_parse_data::new_instance(thd))))
MYSQL_YYABORT;
Lex->event_parse_data->identifier= (yyvsp[0].spname);
Lex->sql_command= SQLCOM_ALTER_EVENT;
Lex->stmt_definition_begin= (yyvsp[-2].simple_string);
}
#line 36544 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1087:
#line 7288 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(!((yyvsp[-4].num) || (yyvsp[-3].num) || (yyvsp[-2].num) || (yyvsp[-1].num) || (yyvsp[0].num))))
{
thd->parse_error();
MYSQL_YYABORT;
}
/*
sql_command is set here because some rules in ev_sql_stmt
can overwrite it
*/
Lex->sql_command= SQLCOM_ALTER_EVENT;
Lex->stmt_definition_end= (char*)YYLIP->get_cpp_ptr();
Lex->pop_select(); //main select
}
#line 36566 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1088:
#line 7304 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
lex->alter_tablespace_info->ts_cmd_type= ALTER_TABLESPACE;
}
#line 36577 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1089:
#line 7309 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
lex->alter_tablespace_info->ts_cmd_type= ALTER_LOGFILE_GROUP;
}
#line 36588 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1090:
#line 7314 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
lex->alter_tablespace_info->ts_cmd_type= CHANGE_FILE_TABLESPACE;
}
#line 36599 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1091:
#line 7319 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
lex->alter_tablespace_info->ts_cmd_type= ALTER_ACCESS_MODE_TABLESPACE;
}
#line 36610 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1092:
#line 7324 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
lex->sql_command= SQLCOM_ALTER_SERVER;
lex->server_options.reset((yyvsp[0].lex_str));
}
#line 36622 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1093:
#line 7328 "/home/buildbot/git/sql/sql_yacc.yy"
{ }
#line 36630 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1094:
#line 7332 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->create_info.set((yyvsp[-5].object_ddl_options));
Lex->sql_command= SQLCOM_ALTER_USER;
}
#line 36641 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1095:
#line 7337 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
lex->name= null_clex_str;
lex->table_type= TABLE_TYPE_UNKNOWN;
lex->sql_command= SQLCOM_ALTER_SEQUENCE;
lex->create_info.init();
lex->no_write_to_binlog= 0;
DBUG_ASSERT(!lex->m_sql_cmd);
if (Lex->main_select_push())
MYSQL_YYABORT;
}
#line 36659 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1096:
#line 7349 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
if (!(lex->create_info.seq_create_info= new (thd->mem_root)
sequence_definition()) ||
!lex->first_select_lex()->
add_table_to_list(thd, (yyvsp[0].table), NULL, TL_OPTION_SEQUENCE,
TL_WRITE, MDL_EXCLUSIVE))
MYSQL_YYABORT;
}
#line 36675 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1097:
#line 7359 "/home/buildbot/git/sql/sql_yacc.yy"
{
/* Create a generic ALTER SEQUENCE statment. */
Lex->m_sql_cmd= new (thd->mem_root) Sql_cmd_alter_sequence((yyvsp[-4].object_ddl_options));
if (unlikely(Lex->m_sql_cmd == NULL))
MYSQL_YYABORT;
}
#line 36688 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1098:
#line 7364 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 36696 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1099:
#line 7369 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->account_options.account_locked= ACCOUNTLOCK_LOCKED;
}
#line 36706 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1100:
#line 7373 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->account_options.account_locked= ACCOUNTLOCK_UNLOCKED;
}
#line 36716 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1101:
#line 7380 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->account_options.password_expire= PASSWORD_EXPIRE_NOW;
}
#line 36726 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1102:
#line 7384 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->account_options.password_expire= PASSWORD_EXPIRE_NEVER;
}
#line 36736 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1103:
#line 7388 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->account_options.password_expire= PASSWORD_EXPIRE_DEFAULT;
}
#line 36746 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1104:
#line 7392 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->account_options.password_expire= PASSWORD_EXPIRE_INTERVAL;
if (!(Lex->account_options.num_expiration_days= atoi((yyvsp[-1].lex_str).str)))
my_yyabort_error((ER_WRONG_VALUE, MYF(0), "DAY", (yyvsp[-1].lex_str).str));
}
#line 36758 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1110:
#line 7408 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.num)= 0;}
#line 36766 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1111:
#line 7409 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.num)= 1; }
#line 36774 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1112:
#line 7410 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.num)= 1; }
#line 36782 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1113:
#line 7411 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.num)= 1; }
#line 36790 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1114:
#line 7415 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.num)= 0;}
#line 36798 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1115:
#line 7417 "/home/buildbot/git/sql/sql_yacc.yy"
{
/*
Use lex's spname to hold the new name.
The original name is in the Event_parse_data object
*/
Lex->spname= (yyvsp[0].spname);
(yyval.num)= 1;
}
#line 36813 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1116:
#line 7428 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.num)= 0;}
#line 36821 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1117:
#line 7429 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.num)= 1; }
#line 36829 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1118:
#line 7434 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.ident_sys)= Lex_ident_sys(); }
#line 36837 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1121:
#line 7441 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->m_sql_cmd= new (thd->mem_root)
Sql_cmd_discard_import_tablespace(
Sql_cmd_discard_import_tablespace::DISCARD_TABLESPACE);
if (unlikely(Lex->m_sql_cmd == NULL))
MYSQL_YYABORT;
}
#line 36851 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1122:
#line 7449 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->m_sql_cmd= new (thd->mem_root)
Sql_cmd_discard_import_tablespace(
Sql_cmd_discard_import_tablespace::IMPORT_TABLESPACE);
if (unlikely(Lex->m_sql_cmd == NULL))
MYSQL_YYABORT;
}
#line 36865 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1128:
#line 7471 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->alter_info.partition_flags|= ALTER_PARTITION_DROP;
DBUG_ASSERT(!Lex->if_exists());
Lex->create_info.add((yyvsp[-1].object_ddl_options));
}
#line 36877 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1129:
#line 7478 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
lex->alter_info.partition_flags|= ALTER_PARTITION_REBUILD;
lex->no_write_to_binlog= (yyvsp[-1].num);
}
#line 36889 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1130:
#line 7485 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= thd->lex;
lex->no_write_to_binlog= (yyvsp[-1].num);
lex->check_opt.init();
DBUG_ASSERT(!lex->m_sql_cmd);
lex->m_sql_cmd= new (thd->mem_root)
Sql_cmd_alter_table_optimize_partition();
if (unlikely(lex->m_sql_cmd == NULL))
MYSQL_YYABORT;
}
#line 36906 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1132:
#line 7498 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= thd->lex;
lex->no_write_to_binlog= (yyvsp[-1].num);
lex->check_opt.init();
DBUG_ASSERT(!lex->m_sql_cmd);
lex->m_sql_cmd= new (thd->mem_root)
Sql_cmd_alter_table_analyze_partition();
if (unlikely(lex->m_sql_cmd == NULL))
MYSQL_YYABORT;
}
#line 36923 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1133:
#line 7509 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= thd->lex;
lex->check_opt.init();
DBUG_ASSERT(!lex->m_sql_cmd);
lex->m_sql_cmd= new (thd->mem_root)
Sql_cmd_alter_table_check_partition();
if (unlikely(lex->m_sql_cmd == NULL))
MYSQL_YYABORT;
}
#line 36939 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1135:
#line 7521 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= thd->lex;
lex->no_write_to_binlog= (yyvsp[-1].num);
lex->check_opt.init();
DBUG_ASSERT(!lex->m_sql_cmd);
lex->m_sql_cmd= new (thd->mem_root)
Sql_cmd_alter_table_repair_partition();
if (unlikely(lex->m_sql_cmd == NULL))
MYSQL_YYABORT;
}
#line 36956 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1137:
#line 7533 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
lex->alter_info.partition_flags|= ALTER_PARTITION_COALESCE;
lex->no_write_to_binlog= (yyvsp[-1].num);
lex->alter_info.num_parts= (yyvsp[0].ulong_num);
}
#line 36969 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1138:
#line 7540 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= thd->lex;
lex->check_opt.init();
DBUG_ASSERT(!lex->m_sql_cmd);
lex->m_sql_cmd= new (thd->mem_root)
Sql_cmd_alter_table_truncate_partition();
if (unlikely(lex->m_sql_cmd == NULL))
MYSQL_YYABORT;
}
#line 36985 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1140:
#line 7552 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (Lex->stmt_alter_table_exchange_partition((yyvsp[-1].table)))
MYSQL_YYABORT;
}
#line 36996 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1141:
#line 7560 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->alter_info.partition_flags|= ALTER_PARTITION_REMOVE;
}
#line 37006 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1142:
#line 7567 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->alter_info.partition_flags|= ALTER_PARTITION_ALL;
}
#line 37016 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1144:
#line 7576 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
lex->part_info= new (thd->mem_root) partition_info();
if (unlikely(!lex->part_info))
MYSQL_YYABORT;
lex->alter_info.partition_flags|= ALTER_PARTITION_ADD;
DBUG_ASSERT(!Lex->create_info.if_not_exists());
lex->create_info.set((yyvsp[-1].object_ddl_options));
lex->no_write_to_binlog= (yyvsp[0].num);
}
#line 37034 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1145:
#line 7588 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 37042 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1147:
#line 7594 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
lex->part_info->num_parts= lex->part_info->partitions.elements;
}
#line 37053 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1148:
#line 7599 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->part_info->num_parts= (yyvsp[0].ulong_num);
}
#line 37063 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1149:
#line 7606 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
lex->part_info= new (thd->mem_root) partition_info();
if (unlikely(!lex->part_info))
MYSQL_YYABORT;
lex->no_write_to_binlog= (yyvsp[0].num);
}
#line 37078 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1151:
#line 7619 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->alter_info.partition_flags|= ALTER_PARTITION_TABLE_REORG;
}
#line 37088 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1152:
#line 7623 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->alter_info.partition_flags|= ALTER_PARTITION_REORGANIZE;
}
#line 37098 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1153:
#line 7627 "/home/buildbot/git/sql/sql_yacc.yy"
{
partition_info *part_info= Lex->part_info;
part_info->num_parts= part_info->partitions.elements;
}
#line 37109 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1154:
#line 7634 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 37117 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1155:
#line 7635 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 37125 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1156:
#line 7640 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->alter_info.partition_names.push_back((yyvsp[0].ident_sys).str,
thd->mem_root)))
MYSQL_YYABORT;
}
#line 37137 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1160:
#line 7662 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex=Lex;
lex->create_last_non_select_table= lex->last_table();
lex->alter_info.flags|= ALTER_PARSER_ADD_COLUMN;
(yyvsp[-1].create_field)->after= (yyvsp[0].lex_str);
}
#line 37150 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1161:
#line 7669 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->create_last_non_select_table= Lex->last_table();
Lex->alter_info.flags|= ALTER_ADD_INDEX;
}
#line 37161 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1162:
#line 7674 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->alter_info.flags|= ALTER_ADD_PERIOD;
}
#line 37171 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1163:
#line 7679 "/home/buildbot/git/sql/sql_yacc.yy"
{
Table_period_info &period= Lex->create_info.period_info;
period.create_if_not_exists= Lex->check_exists;
Lex->alter_info.flags|= ALTER_ADD_CHECK_CONSTRAINT;
}
#line 37183 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1164:
#line 7685 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex=Lex;
lex->alter_info.flags|= ALTER_PARSER_ADD_COLUMN;
if (!lex->alter_info.key_list.is_empty())
lex->alter_info.flags|= ALTER_ADD_INDEX;
}
#line 37196 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1165:
#line 7692 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->alter_info.flags|= ALTER_ADD_CHECK_CONSTRAINT;
}
#line 37206 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1166:
#line 7696 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->alter_info.flags|= ALTER_ADD_CHECK_CONSTRAINT;
Lex->add_constraint((yyvsp[-1].lex_str), (yyvsp[0].virtual_column), TRUE);
}
#line 37217 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1167:
#line 7702 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->alter_info.flags|= ALTER_CHANGE_COLUMN | ALTER_RENAME_COLUMN;
Lex->create_last_non_select_table= Lex->last_table();
(yyvsp[-1].create_field)->change= (yyvsp[-2].lex_str);
(yyvsp[-1].create_field)->after= (yyvsp[0].lex_str);
}
#line 37230 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1168:
#line 7710 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->alter_info.flags|= ALTER_CHANGE_COLUMN;
Lex->create_last_non_select_table= Lex->last_table();
(yyvsp[-1].create_field)->change= (yyvsp[-1].create_field)->field_name;
(yyvsp[-1].create_field)->after= (yyvsp[0].lex_str);
}
#line 37243 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1169:
#line 7717 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex=Lex;
Alter_drop *ad= (new (thd->mem_root)
Alter_drop(Alter_drop::COLUMN, (yyvsp[-1].lex_str).str, (yyvsp[-2].num)));
if (unlikely(ad == NULL))
MYSQL_YYABORT;
lex->alter_info.drop_list.push_back(ad, thd->mem_root);
lex->alter_info.flags|= ALTER_PARSER_DROP_COLUMN;
}
#line 37259 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1170:
#line 7727 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex=Lex;
Alter_drop *ad= (new (thd->mem_root)
Alter_drop(Alter_drop::CHECK_CONSTRAINT,
(yyvsp[0].lex_str).str, (yyvsp[-1].num)));
if (unlikely(ad == NULL))
MYSQL_YYABORT;
lex->alter_info.drop_list.push_back(ad, thd->mem_root);
lex->alter_info.flags|= ALTER_DROP_CHECK_CONSTRAINT;
}
#line 37276 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1171:
#line 7738 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex=Lex;
Alter_drop *ad= (new (thd->mem_root)
Alter_drop(Alter_drop::FOREIGN_KEY, (yyvsp[0].lex_str).str, (yyvsp[-1].num)));
if (unlikely(ad == NULL))
MYSQL_YYABORT;
lex->alter_info.drop_list.push_back(ad, thd->mem_root);
lex->alter_info.flags|= ALTER_DROP_FOREIGN_KEY;
}
#line 37292 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1172:
#line 7748 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex=Lex;
Alter_drop *ad= (new (thd->mem_root)
Alter_drop(Alter_drop::KEY, primary_key_name,
FALSE));
if (unlikely(ad == NULL))
MYSQL_YYABORT;
lex->alter_info.drop_list.push_back(ad, thd->mem_root);
lex->alter_info.flags|= ALTER_DROP_INDEX;
}
#line 37309 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1173:
#line 7759 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex=Lex;
Alter_drop *ad= (new (thd->mem_root)
Alter_drop(Alter_drop::KEY, (yyvsp[0].lex_str).str, (yyvsp[-1].num)));
if (unlikely(ad == NULL))
MYSQL_YYABORT;
lex->alter_info.drop_list.push_back(ad, thd->mem_root);
lex->alter_info.flags|= ALTER_DROP_INDEX;
}
#line 37325 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1174:
#line 7769 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex=Lex;
lex->alter_info.keys_onoff= Alter_info::DISABLE;
lex->alter_info.flags|= ALTER_KEYS_ONOFF;
}
#line 37337 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1175:
#line 7775 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex=Lex;
lex->alter_info.keys_onoff= Alter_info::ENABLE;
lex->alter_info.flags|= ALTER_KEYS_ONOFF;
}
#line 37349 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1176:
#line 7781 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (check_expression((yyvsp[0].virtual_column), &(yyvsp[-3].lex_str), VCOL_DEFAULT))
MYSQL_YYABORT;
if (unlikely(Lex->add_alter_list((yyvsp[-3].lex_str), (yyvsp[0].virtual_column), (yyvsp[-4].num))))
MYSQL_YYABORT;
}
#line 37362 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1177:
#line 7788 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->add_alter_list((yyvsp[-2].lex_str), (Virtual_column_info*) 0, (yyvsp[-3].num))))
MYSQL_YYABORT;
}
#line 37373 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1178:
#line 7793 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex=Lex;
lex->first_select_lex()->db= (yyvsp[0].table)->db;
if (lex->first_select_lex()->db.str == NULL &&
lex->copy_db_to(&lex->first_select_lex()->db))
MYSQL_YYABORT;
if (unlikely(check_table_name((yyvsp[0].table)->table.str,(yyvsp[0].table)->table.length,
FALSE)) ||
((yyvsp[0].table)->db.str && unlikely(check_db_name((LEX_STRING*) &(yyvsp[0].table)->db))))
my_yyabort_error((ER_WRONG_TABLE_NAME, MYF(0), (yyvsp[0].table)->table.str));
lex->name= (yyvsp[0].table)->table;
lex->alter_info.flags|= ALTER_RENAME;
}
#line 37393 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1179:
#line 7807 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->add_alter_list((yyvsp[-2].ident_sys), (yyvsp[0].ident_sys), (yyvsp[-3].num))))
MYSQL_YYABORT;
}
#line 37404 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1180:
#line 7812 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex=Lex;
Alter_rename_key *ak= new (thd->mem_root)
Alter_rename_key((yyvsp[-2].lex_str), (yyvsp[0].lex_str), (yyvsp[-3].num));
if (ak == NULL)
MYSQL_YYABORT;
lex->alter_info.alter_rename_key_list.push_back(ak);
lex->alter_info.flags|= ALTER_RENAME_INDEX;
}
#line 37420 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1181:
#line 7822 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (!(yyvsp[-1].charset))
{
(yyvsp[-1].charset)= thd->variables.collation_database;
}
(yyvsp[0].charset)= (yyvsp[0].charset) ? (yyvsp[0].charset) : (yyvsp[-1].charset);
if (unlikely(!my_charset_same((yyvsp[-1].charset),(yyvsp[0].charset))))
my_yyabort_error((ER_COLLATION_CHARSET_MISMATCH, MYF(0),
(yyvsp[0].charset)->name, (yyvsp[-1].charset)->csname));
if (unlikely(Lex->create_info.add_alter_list_item_convert_to_charset((yyvsp[0].charset))))
MYSQL_YYABORT;
Lex->alter_info.flags|= ALTER_CONVERT_TO;
}
#line 37440 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1182:
#line 7836 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex=Lex;
lex->alter_info.flags|= ALTER_OPTIONS;
}
#line 37451 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1183:
#line 7841 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->alter_info.flags|= ALTER_RECREATE;
}
#line 37461 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1184:
#line 7845 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex=Lex;
lex->alter_info.flags|= ALTER_ORDER;
}
#line 37472 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1187:
#line 7852 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->alter_info.flags|= ALTER_ADD_SYSTEM_VERSIONING;
Lex->create_info.options|= HA_VERSIONED_TABLE;
}
#line 37483 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1188:
#line 7857 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->alter_info.flags|= ALTER_DROP_SYSTEM_VERSIONING;
Lex->create_info.options&= ~HA_VERSIONED_TABLE;
}
#line 37494 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1189:
#line 7862 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->alter_info.flags|= ALTER_DROP_PERIOD;
}
#line 37504 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1190:
#line 7866 "/home/buildbot/git/sql/sql_yacc.yy"
{
Alter_drop *ad= new Alter_drop(Alter_drop::PERIOD, (yyvsp[0].ident_sys).str, (yyvsp[-2].num));
if (unlikely(ad == NULL))
MYSQL_YYABORT;
Lex->alter_info.drop_list.push_back(ad, thd->mem_root);
Lex->alter_info.flags|= ALTER_DROP_CHECK_CONSTRAINT;
}
#line 37518 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1196:
#line 7885 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->alter_info.set_requested_algorithm(
Alter_info::ALTER_TABLE_ALGORITHM_DEFAULT);
}
#line 37529 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1197:
#line 7890 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->alter_info.set_requested_algorithm(&(yyvsp[0].ident_sys))))
my_yyabort_error((ER_UNKNOWN_ALTER_ALGORITHM, MYF(0), (yyvsp[0].ident_sys).str));
}
#line 37540 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1198:
#line 7898 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->alter_info.requested_lock=
Alter_info::ALTER_TABLE_LOCK_DEFAULT;
}
#line 37551 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1199:
#line 7903 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->alter_info.set_requested_lock(&(yyvsp[0].ident_sys))))
my_yyabort_error((ER_UNKNOWN_ALTER_LOCK, MYF(0), (yyvsp[0].ident_sys).str));
}
#line 37562 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1200:
#line 7910 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 37570 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1201:
#line 7911 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 37578 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1202:
#line 7915 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->ignore= 0;}
#line 37586 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1203:
#line 7916 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->ignore= 1;}
#line 37594 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1204:
#line 7920 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->ignore= 0;}
#line 37602 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1210:
#line 7934 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->ignore= 1;}
#line 37610 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1211:
#line 7936 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->alter_info.requested_lock=
Alter_info::ALTER_TABLE_LOCK_NONE;
}
#line 37621 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1212:
#line 7943 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->drop_mode= DROP_DEFAULT; }
#line 37629 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1213:
#line 7944 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->drop_mode= DROP_RESTRICT; }
#line 37637 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1214:
#line 7945 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->drop_mode= DROP_CASCADE; }
#line 37645 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1215:
#line 7949 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.lex_str)= null_clex_str; }
#line 37653 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1216:
#line 7951 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.lex_str)= (yyvsp[0].ident_sys);
Lex->alter_info.flags |= ALTER_COLUMN_ORDER;
}
#line 37664 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1217:
#line 7956 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.lex_str).str= first_keyword;
(yyval.lex_str).length= 5; /* Length of "first" */
Lex->alter_info.flags |= ALTER_COLUMN_ORDER;
}
#line 37676 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1218:
#line 7964 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 37684 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1219:
#line 7965 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 37692 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1220:
#line 7966 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 37700 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1221:
#line 7967 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 37708 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1222:
#line 7972 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex=Lex;
lex->sql_command = SQLCOM_SLAVE_START;
lex->type = 0;
/* If you change this code don't forget to update SLAVE START too */
}
#line 37721 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1223:
#line 7979 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 37729 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1224:
#line 7981 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex=Lex;
lex->sql_command = SQLCOM_SLAVE_ALL_START;
lex->type = 0;
/* If you change this code don't forget to update STOP SLAVE too */
}
#line 37742 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1225:
#line 7987 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 37750 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1226:
#line 7989 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex=Lex;
lex->sql_command = SQLCOM_SLAVE_STOP;
lex->type = 0;
/* If you change this code don't forget to update SLAVE STOP too */
}
#line 37763 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1227:
#line 7996 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex=Lex;
lex->sql_command = SQLCOM_SLAVE_ALL_STOP;
lex->type = 0;
/* If you change this code don't forget to update SLAVE STOP too */
}
#line 37776 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1228:
#line 8006 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
lex->sql_command= SQLCOM_BEGIN;
/* READ ONLY and READ WRITE are mutually exclusive. */
if (unlikely(((yyvsp[0].num) & MYSQL_START_TRANS_OPT_READ_WRITE) &&
((yyvsp[0].num) & MYSQL_START_TRANS_OPT_READ_ONLY)))
{
thd->parse_error();
MYSQL_YYABORT;
}
lex->start_transaction_opt= (yyvsp[0].num);
}
#line 37795 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1229:
#line 8022 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.num)= 0;
}
#line 37805 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1230:
#line 8026 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.num)= (yyvsp[0].num);
}
#line 37815 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1231:
#line 8033 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.num)= (yyvsp[0].num);
}
#line 37825 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1232:
#line 8037 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.num)= (yyvsp[-2].num) | (yyvsp[0].num);
}
#line 37835 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1233:
#line 8044 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.num)= MYSQL_START_TRANS_OPT_WITH_CONS_SNAPSHOT;
}
#line 37845 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1234:
#line 8048 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.num)= MYSQL_START_TRANS_OPT_READ_ONLY;
}
#line 37855 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1235:
#line 8052 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.num)= MYSQL_START_TRANS_OPT_READ_WRITE;
}
#line 37865 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1236:
#line 8058 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->slave_thd_opt= 0; }
#line 37873 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1237:
#line 8060 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 37881 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1240:
#line 8069 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 37889 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1241:
#line 8070 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->slave_thd_opt|=SLAVE_SQL; }
#line 37897 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1242:
#line 8071 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->slave_thd_opt|=SLAVE_IO; }
#line 37905 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1243:
#line 8075 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 37913 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1244:
#line 8077 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex=Lex;
if (unlikely(((lex->mi.log_file_name || lex->mi.pos) &&
(lex->mi.relay_log_name || lex->mi.relay_log_pos)) ||
!((lex->mi.log_file_name && lex->mi.pos) ||
(lex->mi.relay_log_name && lex->mi.relay_log_pos))))
my_yyabort_error((ER_BAD_SLAVE_UNTIL_COND, MYF(0)));
}
#line 37928 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1245:
#line 8086 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->mi.gtid_pos_str = (yyvsp[0].lex_str);
}
#line 37938 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1248:
#line 8098 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex=Lex;
lex->sql_command = SQLCOM_CHECKSUM;
/* Will be overridden during execution. */
YYPS->m_lock_type= TL_UNLOCK;
}
#line 37951 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1249:
#line 8105 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 37959 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1250:
#line 8109 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->check_opt.flags= 0; }
#line 37967 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1251:
#line 8110 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->check_opt.flags= T_QUICK; }
#line 37975 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1252:
#line 8111 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->check_opt.flags= T_EXTEND; }
#line 37983 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1254:
#line 8117 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->table_type= TABLE_TYPE_VIEW; }
#line 37991 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1256:
#line 8123 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex=Lex;
lex->sql_command = SQLCOM_REPAIR;
lex->no_write_to_binlog= (yyvsp[0].num);
lex->check_opt.init();
lex->alter_info.reset();
/* Will be overridden during execution. */
YYPS->m_lock_type= TL_UNLOCK;
}
#line 38007 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1257:
#line 8133 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX* lex= thd->lex;
DBUG_ASSERT(!lex->m_sql_cmd);
lex->m_sql_cmd= new (thd->mem_root) Sql_cmd_repair_table();
if (unlikely(lex->m_sql_cmd == NULL))
MYSQL_YYABORT;
}
#line 38021 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1258:
#line 8143 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->check_opt.flags = T_MEDIUM; }
#line 38029 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1259:
#line 8144 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 38037 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1260:
#line 8148 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 38045 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1261:
#line 8149 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 38053 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1262:
#line 8153 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->check_opt.flags|= T_QUICK; }
#line 38061 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1263:
#line 8154 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->check_opt.flags|= T_EXTEND; }
#line 38069 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1264:
#line 8155 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->check_opt.sql_flags|= TT_USEFRM; }
#line 38077 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1265:
#line 8159 "/home/buildbot/git/sql/sql_yacc.yy"
{ }
#line 38085 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1266:
#line 8160 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->check_opt.sql_flags|= TT_FROM_MYSQL; }
#line 38093 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1267:
#line 8165 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex=Lex;
lex->sql_command = SQLCOM_ANALYZE;
lex->no_write_to_binlog= (yyvsp[-1].num);
lex->check_opt.init();
lex->alter_info.reset();
/* Will be overridden during execution. */
YYPS->m_lock_type= TL_UNLOCK;
}
#line 38109 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1268:
#line 8175 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX* lex= thd->lex;
DBUG_ASSERT(!lex->m_sql_cmd);
lex->m_sql_cmd= new (thd->mem_root) Sql_cmd_analyze_table();
if (unlikely(lex->m_sql_cmd == NULL))
MYSQL_YYABORT;
}
#line 38123 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1272:
#line 8195 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 38131 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1273:
#line 8197 "/home/buildbot/git/sql/sql_yacc.yy"
{
thd->lex->with_persistent_for_clause= TRUE;
}
#line 38141 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1274:
#line 8204 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 38149 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1275:
#line 8206 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 38157 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1276:
#line 8210 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 38165 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1277:
#line 8212 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX* lex= thd->lex;
lex->column_list= new (thd->mem_root) List;
if (unlikely(lex->column_list == NULL))
MYSQL_YYABORT;
}
#line 38178 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1278:
#line 8220 "/home/buildbot/git/sql/sql_yacc.yy"
{ }
#line 38186 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1279:
#line 8224 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 38194 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1280:
#line 8226 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX* lex= thd->lex;
lex->index_list= new (thd->mem_root) List;
if (unlikely(lex->index_list == NULL))
MYSQL_YYABORT;
}
#line 38207 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1281:
#line 8234 "/home/buildbot/git/sql/sql_yacc.yy"
{ }
#line 38215 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1282:
#line 8239 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 38223 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1283:
#line 8241 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->column_list->push_back((LEX_STRING*)
thd->memdup(&(yyvsp[0].ident_sys), sizeof(LEX_STRING)), thd->mem_root);
}
#line 38234 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1284:
#line 8246 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->column_list->push_back((LEX_STRING*)
thd->memdup(&(yyvsp[0].ident_sys), sizeof(LEX_STRING)), thd->mem_root);
}
#line 38245 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1285:
#line 8254 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 38253 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1288:
#line 8261 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->index_list->push_back((LEX_STRING*)
thd->memdup(&(yyvsp[0].ident_sys), sizeof(LEX_STRING)),
thd->mem_root);
}
#line 38265 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1289:
#line 8268 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX_STRING str= {(char*) "PRIMARY", 7};
Lex->index_list->push_back((LEX_STRING*)
thd->memdup(&str, sizeof(LEX_STRING)),
thd->mem_root);
}
#line 38278 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1290:
#line 8278 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->sql_command = SQLCOM_BINLOG_BASE64_EVENT;
Lex->comment= (yyvsp[0].lex_str);
Lex->ident.str= NULL;
Lex->ident.length= 0;
}
#line 38291 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1291:
#line 8286 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->sql_command = SQLCOM_BINLOG_BASE64_EVENT;
Lex->comment= (yyvsp[-3].lex_str);
Lex->ident= (yyvsp[0].lex_str);
}
#line 38303 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1293:
#line 8296 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->table_type= TABLE_TYPE_VIEW; }
#line 38311 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1295:
#line 8301 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex=Lex;
lex->sql_command = SQLCOM_CHECK;
lex->check_opt.init();
lex->alter_info.reset();
/* Will be overridden during execution. */
YYPS->m_lock_type= TL_UNLOCK;
}
#line 38327 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1296:
#line 8311 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX* lex= thd->lex;
if (unlikely(lex->sphead))
my_yyabort_error((ER_SP_BADSTATEMENT, MYF(0), "CHECK"));
DBUG_ASSERT(!lex->m_sql_cmd);
lex->m_sql_cmd= new (thd->mem_root) Sql_cmd_check_table();
if (unlikely(lex->m_sql_cmd == NULL))
MYSQL_YYABORT;
}
#line 38343 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1297:
#line 8323 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->check_opt.flags = T_MEDIUM; }
#line 38351 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1298:
#line 8324 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 38359 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1299:
#line 8328 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 38367 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1300:
#line 8329 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 38375 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1301:
#line 8333 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->check_opt.flags|= T_QUICK; }
#line 38383 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1302:
#line 8334 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->check_opt.flags|= T_FAST; }
#line 38391 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1303:
#line 8335 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->check_opt.flags|= T_MEDIUM; }
#line 38399 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1304:
#line 8336 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->check_opt.flags|= T_EXTEND; }
#line 38407 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1305:
#line 8337 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->check_opt.flags|= T_CHECK_ONLY_CHANGED; }
#line 38415 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1306:
#line 8338 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->check_opt.sql_flags|= TT_FOR_UPGRADE; }
#line 38423 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1307:
#line 8342 "/home/buildbot/git/sql/sql_yacc.yy"
{ }
#line 38431 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1308:
#line 8343 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->check_opt.sql_flags|= TT_FOR_UPGRADE; }
#line 38439 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1309:
#line 8348 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex=Lex;
lex->sql_command = SQLCOM_OPTIMIZE;
lex->no_write_to_binlog= (yyvsp[-1].num);
lex->check_opt.init();
lex->alter_info.reset();
/* Will be overridden during execution. */
YYPS->m_lock_type= TL_UNLOCK;
}
#line 38455 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1310:
#line 8358 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX* lex= thd->lex;
DBUG_ASSERT(!lex->m_sql_cmd);
lex->m_sql_cmd= new (thd->mem_root) Sql_cmd_optimize_table();
if (unlikely(lex->m_sql_cmd == NULL))
MYSQL_YYABORT;
}
#line 38469 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1311:
#line 8368 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.num)= 0; }
#line 38477 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1312:
#line 8369 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.num)= 1; }
#line 38485 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1313:
#line 8370 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.num)= 1; }
#line 38493 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1314:
#line 8375 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->sql_command= SQLCOM_RENAME_TABLE;
Lex->create_info.set((yyvsp[0].object_ddl_options));
if (Lex->main_select_push())
MYSQL_YYABORT;
}
#line 38506 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1315:
#line 8382 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->pop_select(); //main select
}
#line 38516 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1316:
#line 8386 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->sql_command = SQLCOM_RENAME_USER;
}
#line 38526 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1317:
#line 8393 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->users_list.push_back((yyvsp[-2].lex_user), thd->mem_root) ||
Lex->users_list.push_back((yyvsp[0].lex_user), thd->mem_root)))
MYSQL_YYABORT;
}
#line 38538 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1318:
#line 8399 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->users_list.push_back((yyvsp[-2].lex_user), thd->mem_root) ||
Lex->users_list.push_back((yyvsp[0].lex_user), thd->mem_root)))
MYSQL_YYABORT;
}
#line 38550 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1321:
#line 8413 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex=Lex;
SELECT_LEX *sl= lex->current_select;
if (unlikely(!sl->add_table_to_list(thd, (yyvsp[-3].table),NULL,
TL_OPTION_UPDATING,
TL_IGNORE, MDL_EXCLUSIVE)) ||
unlikely(!sl->add_table_to_list(thd, (yyvsp[0].table), NULL,
TL_OPTION_UPDATING,
TL_IGNORE, MDL_EXCLUSIVE)))
MYSQL_YYABORT;
}
#line 38568 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1322:
#line 8428 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->alter_info.reset();
}
#line 38578 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1323:
#line 8432 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex=Lex;
lex->sql_command= SQLCOM_ASSIGN_TO_KEYCACHE;
lex->ident= (yyvsp[0].lex_str);
}
#line 38590 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1328:
#line 8451 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(!Select->add_table_to_list(thd, (yyvsp[-1].table), NULL, 0, TL_READ,
MDL_SHARED_READ,
Select->
pop_index_hints())))
MYSQL_YYABORT;
}
#line 38604 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1329:
#line 8462 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(!Select->add_table_to_list(thd, (yyvsp[-2].table), NULL, 0, TL_READ,
MDL_SHARED_READ,
Select->
pop_index_hints())))
MYSQL_YYABORT;
}
#line 38618 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1330:
#line 8472 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.lex_str)= (yyvsp[0].ident_sys); }
#line 38626 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1331:
#line 8473 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.lex_str) = default_key_cache_base; }
#line 38634 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1332:
#line 8478 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex=Lex;
lex->sql_command=SQLCOM_PRELOAD_KEYS;
lex->alter_info.reset();
if (lex->main_select_push())
MYSQL_YYABORT;
}
#line 38648 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1333:
#line 8486 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->pop_select(); //main select
}
#line 38658 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1338:
#line 8503 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(!Select->add_table_to_list(thd, (yyvsp[-2].table), NULL, (yyvsp[0].num), TL_READ,
MDL_SHARED_READ,
Select->
pop_index_hints())))
MYSQL_YYABORT;
}
#line 38672 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1339:
#line 8514 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(!Select->add_table_to_list(thd, (yyvsp[-3].table), NULL, (yyvsp[0].num), TL_READ,
MDL_SHARED_READ,
Select->
pop_index_hints())))
MYSQL_YYABORT;
}
#line 38686 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1340:
#line 8525 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->alter_info.partition_flags|= ALTER_PARTITION_ADMIN;
}
#line 38696 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1342:
#line 8532 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->first_select_lex()->alloc_index_hints(thd);
Select->set_index_hint_type(INDEX_HINT_USE,
INDEX_HINT_MASK_ALL);
}
#line 38708 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1344:
#line 8541 "/home/buildbot/git/sql/sql_yacc.yy"
{ }
#line 38716 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1346:
#line 8547 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.num)= 0; }
#line 38724 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1347:
#line 8548 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.num)= TL_OPTION_IGNORE_LEAVES; }
#line 38732 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1348:
#line 8558 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (Lex->push_select((yyvsp[0].select_lex_unit)->fake_select_lex ?
(yyvsp[0].select_lex_unit)->fake_select_lex :
(yyvsp[0].select_lex_unit)->first_select()))
MYSQL_YYABORT;
}
#line 38745 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1349:
#line 8565 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->pop_select();
(yyvsp[-2].select_lex_unit)->set_with_clause(NULL);
if (Lex->select_finalize((yyvsp[-2].select_lex_unit), (yyvsp[0].select_lock)))
MYSQL_YYABORT;
}
#line 38758 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1350:
#line 8572 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (Lex->push_select((yyvsp[0].select_lex_unit)->fake_select_lex ?
(yyvsp[0].select_lex_unit)->fake_select_lex :
(yyvsp[0].select_lex_unit)->first_select()))
MYSQL_YYABORT;
}
#line 38771 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1351:
#line 8579 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->pop_select();
(yyvsp[-2].select_lex_unit)->set_with_clause((yyvsp[-3].with_clause));
(yyvsp[-3].with_clause)->attach_to((yyvsp[-2].select_lex_unit)->first_select());
if (Lex->select_finalize((yyvsp[-2].select_lex_unit), (yyvsp[0].select_lock)))
MYSQL_YYABORT;
}
#line 38785 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1352:
#line 8590 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (Lex->push_select((yyvsp[0].select_lex)))
MYSQL_YYABORT;
}
#line 38796 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1353:
#line 8595 "/home/buildbot/git/sql/sql_yacc.yy"
{
SELECT_LEX_UNIT *unit;
if (!(unit = Lex->create_unit((yyvsp[-2].select_lex))))
MYSQL_YYABORT;
if ((yyvsp[0].order_limit_lock))
unit= Lex->add_tail_to_query_expression_body(unit, (yyvsp[0].order_limit_lock));
if (Lex->select_finalize(unit))
MYSQL_YYABORT;
}
#line 38812 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1354:
#line 8606 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (Lex->push_select((yyvsp[0].select_lex)))
MYSQL_YYABORT;
}
#line 38823 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1355:
#line 8611 "/home/buildbot/git/sql/sql_yacc.yy"
{
SELECT_LEX_UNIT *unit;
if (!(unit = Lex->create_unit((yyvsp[-2].select_lex))))
MYSQL_YYABORT;
if ((yyvsp[0].order_limit_lock))
unit= Lex->add_tail_to_query_expression_body(unit, (yyvsp[0].order_limit_lock));
unit->set_with_clause((yyvsp[-3].with_clause));
(yyvsp[-3].with_clause)->attach_to((yyvsp[-2].select_lex));
if (Lex->select_finalize(unit))
MYSQL_YYABORT;
}
#line 38841 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1356:
#line 8625 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.select_lex)= (yyvsp[0].select_lex); }
#line 38849 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1357:
#line 8626 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.select_lex)= (yyvsp[0].select_lex); }
#line 38857 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1358:
#line 8631 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (Lex->parsed_TVC_start())
MYSQL_YYABORT;
}
#line 38868 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1359:
#line 8636 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (!((yyval.select_lex)= Lex->parsed_TVC_end()))
MYSQL_YYABORT;
}
#line 38879 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1360:
#line 8644 "/home/buildbot/git/sql/sql_yacc.yy"
{
SELECT_LEX *sel;
LEX *lex= Lex;
if (!(sel= lex->alloc_select(TRUE)) || lex->push_select(sel))
MYSQL_YYABORT;
sel->init_select();
sel->braces= FALSE;
}
#line 38894 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1361:
#line 8653 "/home/buildbot/git/sql/sql_yacc.yy"
{
Select->parsing_place= SELECT_LIST;
}
#line 38904 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1362:
#line 8657 "/home/buildbot/git/sql/sql_yacc.yy"
{
Select->parsing_place= NO_MATTER;
}
#line 38914 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1363:
#line 8669 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.select_lex)= Lex->pop_select();
}
#line 38924 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1364:
#line 8682 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.select_lex)= Lex->pop_select();
}
#line 38934 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1365:
#line 8740 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyvsp[0].select_lex_unit)->set_with_clause(NULL);
(yyval.select_lex_unit)= (yyvsp[0].select_lex_unit);
}
#line 38945 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1366:
#line 8746 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyvsp[0].select_lex_unit)->set_with_clause((yyvsp[-1].with_clause));
(yyvsp[-1].with_clause)->attach_to((yyvsp[0].select_lex_unit)->first_select());
(yyval.select_lex_unit)= (yyvsp[0].select_lex_unit);
}
#line 38957 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1367:
#line 8759 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.select_lex_unit)= (yyvsp[0].select_lex_unit); }
#line 38965 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1368:
#line 8760 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.select_lex_unit)= (yyvsp[0].select_lex_unit); }
#line 38973 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1369:
#line 8775 "/home/buildbot/git/sql/sql_yacc.yy"
{
if ((yyvsp[0].select_lex_unit)->first_select()->next_select())
{
if (Lex->parsed_multi_operand_query_expression_body((yyvsp[0].select_lex_unit)))
MYSQL_YYABORT;
}
}
#line 38987 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1370:
#line 8783 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (!(yyvsp[0].order_limit_lock))
(yyval.select_lex_unit)= (yyvsp[-2].select_lex_unit);
else
(yyval.select_lex_unit)= Lex->add_tail_to_query_expression_body((yyvsp[-2].select_lex_unit), (yyvsp[0].order_limit_lock));
}
#line 39000 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1371:
#line 8790 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->push_select(!(yyvsp[0].select_lex_unit)->first_select()->next_select() ?
(yyvsp[0].select_lex_unit)->first_select() : (yyvsp[0].select_lex_unit)->fake_select_lex);
}
#line 39011 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1372:
#line 8795 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (!((yyval.select_lex_unit)= Lex->add_tail_to_query_expression_body_ext_parens((yyvsp[-2].select_lex_unit), (yyvsp[0].order_limit_lock))))
MYSQL_YYABORT;
}
#line 39022 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1373:
#line 8803 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.select_lex_unit)= (yyvsp[-1].select_lex_unit); }
#line 39030 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1374:
#line 8805 "/home/buildbot/git/sql/sql_yacc.yy"
{
SELECT_LEX *sel= (yyvsp[-1].select_lex_unit)->first_select()->next_select() ?
(yyvsp[-1].select_lex_unit)->fake_select_lex : (yyvsp[-1].select_lex_unit)->first_select();
sel->braces= true;
(yyval.select_lex_unit)= (yyvsp[-1].select_lex_unit);
}
#line 39043 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1375:
#line 8820 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->push_select((yyvsp[0].select_lex));
if (!((yyval.select_lex_unit)= Lex->create_unit((yyvsp[0].select_lex))))
MYSQL_YYABORT;
}
#line 39055 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1376:
#line 8827 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (!(yyvsp[-1].select_lex_unit)->first_select()->next_select())
{
Lex->pop_select();
}
}
#line 39068 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1377:
#line 8834 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (!((yyval.select_lex_unit)= Lex->add_primary_to_query_expression_body((yyvsp[-3].select_lex_unit), (yyvsp[0].select_lex),
(yyvsp[-2].unit_operation).unit_type,
(yyvsp[-2].unit_operation).distinct)))
MYSQL_YYABORT;
}
#line 39081 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1378:
#line 8843 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (!((yyval.select_lex_unit)= Lex->add_primary_to_query_expression_body_ext_parens(
(yyvsp[-2].select_lex_unit), (yyvsp[0].select_lex),
(yyvsp[-1].unit_operation).unit_type,
(yyvsp[-1].unit_operation).distinct)))
MYSQL_YYABORT;
}
#line 39095 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1379:
#line 8859 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.select_lex)= (yyvsp[0].select_lex); }
#line 39103 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1380:
#line 8861 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.select_lex)= (yyvsp[0].select_lex_unit)->first_select(); }
#line 39111 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1381:
#line 8870 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.select_lex)= (yyvsp[0].select_lex);}
#line 39119 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1382:
#line 8875 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (!((yyval.select_lex)= Lex->parsed_subselect((yyvsp[0].select_lex_unit))))
YYABORT;
}
#line 39130 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1383:
#line 8916 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (!(yyvsp[0].select_lex_unit)->fake_select_lex)
(yyvsp[0].select_lex_unit)->first_select()->braces= false;
else
(yyvsp[0].select_lex_unit)->fake_select_lex->braces= false;
if (!((yyval.select_lex)= Lex->parsed_subselect((yyvsp[0].select_lex_unit))))
YYABORT;
}
#line 39145 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1384:
#line 8925 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyvsp[-1].select_lex_unit)->set_with_clause((yyvsp[-2].with_clause));
(yyvsp[-2].with_clause)->attach_to((yyvsp[-1].select_lex_unit)->first_select());
if (!((yyval.select_lex)= Lex->parsed_subselect((yyvsp[-1].select_lex_unit))))
YYABORT;
}
#line 39158 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1388:
#line 8944 "/home/buildbot/git/sql/sql_yacc.yy"
{
Select->context.table_list=
Select->context.first_name_resolution_table=
Select->table_list.first;
}
#line 39170 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1391:
#line 8959 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely((Select->options & SELECT_DISTINCT) &&
(Select->options & SELECT_ALL)))
my_yyabort_error((ER_WRONG_USAGE, MYF(0), "ALL", "DISTINCT"));
}
#line 39182 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1392:
#line 8968 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.vers_range_unit)= VERS_TIMESTAMP;
}
#line 39192 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1393:
#line 8972 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.vers_range_unit)= VERS_TRX_ID;
}
#line 39202 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1394:
#line 8976 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.vers_range_unit)= VERS_TIMESTAMP;
}
#line 39212 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1395:
#line 8983 "/home/buildbot/git/sql/sql_yacc.yy"
{
Item *item;
if (!(item= type_handler_datetime.create_literal_item(thd,
(yyvsp[0].lex_string_with_metadata).str, (yyvsp[0].lex_string_with_metadata).length,
YYCSCL, true)))
MYSQL_YYABORT;
(yyval.vers_history_point)= Vers_history_point(VERS_TIMESTAMP, item);
}
#line 39227 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1396:
#line 8992 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.vers_history_point)= Vers_history_point(VERS_TIMESTAMP, (yyvsp[0].item));
}
#line 39237 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1397:
#line 8996 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.vers_history_point)= Vers_history_point((yyvsp[-1].vers_range_unit), (yyvsp[0].item));
}
#line 39247 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1398:
#line 9004 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(0 == strcasecmp((yyvsp[-4].ident_sys).str, "SYSTEM_TIME")))
{
thd->parse_error(ER_SYNTAX_ERROR, (yyvsp[-5].simple_string));
MYSQL_YYABORT;
}
Lex->period_conditions.init(SYSTEM_TIME_FROM_TO,
Vers_history_point(VERS_TIMESTAMP, (yyvsp[-2].item)),
Vers_history_point(VERS_TIMESTAMP, (yyvsp[0].item)),
(yyvsp[-4].ident_sys));
}
#line 39265 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1399:
#line 9019 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.num)= false;
}
#line 39275 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1400:
#line 9023 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.num)= true;
}
#line 39285 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1401:
#line 9030 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.num)= false;
}
#line 39295 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1402:
#line 9034 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.num)= true;
}
#line 39305 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1403:
#line 9041 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->vers_conditions.init(SYSTEM_TIME_AS_OF, (yyvsp[0].vers_history_point));
}
#line 39315 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1404:
#line 9045 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->vers_conditions.init(SYSTEM_TIME_ALL);
}
#line 39325 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1405:
#line 9049 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->vers_conditions.init(SYSTEM_TIME_FROM_TO, (yyvsp[-2].vers_history_point), (yyvsp[0].vers_history_point));
}
#line 39335 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1406:
#line 9053 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->vers_conditions.init(SYSTEM_TIME_BETWEEN, (yyvsp[-2].vers_history_point), (yyvsp[0].vers_history_point));
}
#line 39345 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1410:
#line 9066 "/home/buildbot/git/sql/sql_yacc.yy"
{
/*
Allow this flag once per query.
*/
if (Select->options & OPTION_NO_QUERY_CACHE)
my_yyabort_error((ER_DUP_ARGUMENT, MYF(0), "SQL_NO_CACHE"));
Select->options|= OPTION_NO_QUERY_CACHE;
}
#line 39360 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1411:
#line 9075 "/home/buildbot/git/sql/sql_yacc.yy"
{
/*
Allow this flag once per query.
*/
if (Select->options & OPTION_TO_QUERY_CACHE)
my_yyabort_error((ER_DUP_ARGUMENT, MYF(0), "SQL_CACHE"));
Select->options|= OPTION_TO_QUERY_CACHE;
}
#line 39375 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1412:
#line 9088 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.select_lock)= (yyvsp[0].select_lock);
(yyval.select_lock).defined_lock= TRUE;
(yyval.select_lock).update_lock= TRUE;
}
#line 39387 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1413:
#line 9094 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.select_lock)= (yyvsp[0].select_lock);
(yyval.select_lock).defined_lock= TRUE;
(yyval.select_lock).update_lock= FALSE;
}
#line 39399 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1414:
#line 9104 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.select_lock).empty();
}
#line 39409 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1415:
#line 9108 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.select_lock)= (yyvsp[0].select_lock);
}
#line 39419 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1416:
#line 9116 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.select_lock).empty();
}
#line 39429 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1417:
#line 9120 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.select_lock).defined_timeout= TRUE;
(yyval.select_lock).timeout= (yyvsp[0].ulong_num);
}
#line 39440 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1418:
#line 9125 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.select_lock).defined_timeout= TRUE;
(yyval.select_lock).timeout= 0;
}
#line 39451 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1421:
#line 9135 "/home/buildbot/git/sql/sql_yacc.yy"
{
Item *item= new (thd->mem_root)
Item_field(thd, &thd->lex->current_select->context,
star_clex_str);
if (unlikely(item == NULL))
MYSQL_YYABORT;
if (unlikely(add_item_to_list(thd, item)))
MYSQL_YYABORT;
(thd->lex->current_select->with_wild)++;
}
#line 39468 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1422:
#line 9149 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(add_item_to_list(thd, (yyvsp[-1].item))))
MYSQL_YYABORT;
}
#line 39479 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1423:
#line 9154 "/home/buildbot/git/sql/sql_yacc.yy"
{
DBUG_ASSERT((yyvsp[-3].simple_string) < (yyvsp[-1].simple_string));
if (unlikely(add_item_to_list(thd, (yyvsp[-2].item))))
MYSQL_YYABORT;
if ((yyvsp[0].lex_str).str)
{
if (unlikely(Lex->sql_command == SQLCOM_CREATE_VIEW &&
check_column_name((yyvsp[0].lex_str).str)))
my_yyabort_error((ER_WRONG_COLUMN_NAME, MYF(0), (yyvsp[0].lex_str).str));
(yyvsp[-2].item)->common_flags&= ~IS_AUTO_GENERATED_NAME;
(yyvsp[-2].item)->set_name(thd, (yyvsp[0].lex_str));
}
else if (!(yyvsp[-2].item)->name.str || (yyvsp[-2].item)->name.str == item_empty_name)
{
(yyvsp[-2].item)->set_name(thd, (yyvsp[-3].simple_string), (uint) ((yyvsp[-1].simple_string) - (yyvsp[-3].simple_string)), thd->charset());
}
}
#line 39504 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1424:
#line 9175 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.simple_string)= (char*) YYLIP->get_tok_start();
}
#line 39514 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1425:
#line 9181 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.simple_string)= (char*) YYLIP->get_cpp_tok_start();
}
#line 39524 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1426:
#line 9187 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.simple_string)= (char*) YYLIP->get_cpp_tok_end_rtrim();
}
#line 39534 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1427:
#line 9193 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.lex_str)=null_clex_str;}
#line 39542 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1428:
#line 9194 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.lex_str)=(yyvsp[0].ident_sys); }
#line 39550 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1429:
#line 9195 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.lex_str)=(yyvsp[0].lex_str); }
#line 39558 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1430:
#line 9196 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.lex_str)=(yyvsp[0].ident_sys); }
#line 39566 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1431:
#line 9197 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.lex_str)=(yyvsp[0].lex_str); }
#line 39574 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1432:
#line 9201 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.num)= NOT_FIXED_DEC; }
#line 39582 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1433:
#line 9202 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.num)= NOT_FIXED_DEC; }
#line 39590 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1434:
#line 9203 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.num)= (yyvsp[-1].ulong_num); }
#line 39598 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1435:
#line 9207 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.num)= 0; }
#line 39606 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1436:
#line 9208 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.num)= 0; }
#line 39614 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1437:
#line 9209 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.num)= (yyvsp[-1].ulong_num); }
#line 39622 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1438:
#line 9213 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 39630 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1439:
#line 9214 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 39638 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1440:
#line 9220 "/home/buildbot/git/sql/sql_yacc.yy"
{
/*
Design notes:
Do not use a manually maintained stack like thd->lex->xxx_list,
but use the internal bison stack ($$, $1 and $3) instead.
Using the bison stack is:
- more robust to changes in the grammar,
- guaranteed to be in sync with the parser state,
- better for performances (no memory allocation).
*/
Item_cond_or *item1;
Item_cond_or *item3;
if (is_cond_or((yyvsp[-2].item)))
{
item1= (Item_cond_or*) (yyvsp[-2].item);
if (is_cond_or((yyvsp[0].item)))
{
item3= (Item_cond_or*) (yyvsp[0].item);
/*
(X1 OR X2) OR (Y1 OR Y2) ==> OR (X1, X2, Y1, Y2)
*/
item3->add_at_head(item1->argument_list());
(yyval.item) = (yyvsp[0].item);
}
else
{
/*
(X1 OR X2) OR Y ==> OR (X1, X2, Y)
*/
item1->add((yyvsp[0].item), thd->mem_root);
(yyval.item) = (yyvsp[-2].item);
}
}
else if (is_cond_or((yyvsp[0].item)))
{
item3= (Item_cond_or*) (yyvsp[0].item);
/*
X OR (Y1 OR Y2) ==> OR (X, Y1, Y2)
*/
item3->add_at_head((yyvsp[-2].item), thd->mem_root);
(yyval.item) = (yyvsp[0].item);
}
else
{
/* X OR Y */
(yyval.item)= new (thd->mem_root) Item_cond_or(thd, (yyvsp[-2].item), (yyvsp[0].item));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
}
#line 39695 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1441:
#line 9271 "/home/buildbot/git/sql/sql_yacc.yy"
{
/* XOR is a proprietary extension */
(yyval.item)= new (thd->mem_root) Item_func_xor(thd, (yyvsp[-2].item), (yyvsp[0].item));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 39708 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1442:
#line 9278 "/home/buildbot/git/sql/sql_yacc.yy"
{
/* See comments in rule expr: expr or expr */
Item_cond_and *item1;
Item_cond_and *item3;
if (is_cond_and((yyvsp[-2].item)))
{
item1= (Item_cond_and*) (yyvsp[-2].item);
if (is_cond_and((yyvsp[0].item)))
{
item3= (Item_cond_and*) (yyvsp[0].item);
/*
(X1 AND X2) AND (Y1 AND Y2) ==> AND (X1, X2, Y1, Y2)
*/
item3->add_at_head(item1->argument_list());
(yyval.item) = (yyvsp[0].item);
}
else
{
/*
(X1 AND X2) AND Y ==> AND (X1, X2, Y)
*/
item1->add((yyvsp[0].item), thd->mem_root);
(yyval.item) = (yyvsp[-2].item);
}
}
else if (is_cond_and((yyvsp[0].item)))
{
item3= (Item_cond_and*) (yyvsp[0].item);
/*
X AND (Y1 AND Y2) ==> AND (X, Y1, Y2)
*/
item3->add_at_head((yyvsp[-2].item), thd->mem_root);
(yyval.item) = (yyvsp[0].item);
}
else
{
/* X AND Y */
(yyval.item)= new (thd->mem_root) Item_cond_and(thd, (yyvsp[-2].item), (yyvsp[0].item));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
}
#line 39757 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1443:
#line 9321 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= negate_expression(thd, (yyvsp[0].item));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 39769 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1444:
#line 9327 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_func_istrue(thd, (yyvsp[-2].item));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 39781 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1445:
#line 9333 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_func_isnottrue(thd, (yyvsp[-3].item));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 39793 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1446:
#line 9339 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_func_isfalse(thd, (yyvsp[-2].item));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 39805 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1447:
#line 9345 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_func_isnotfalse(thd, (yyvsp[-3].item));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 39817 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1448:
#line 9351 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_func_isnull(thd, (yyvsp[-2].item));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 39829 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1449:
#line 9357 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_func_isnotnull(thd, (yyvsp[-3].item));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 39841 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1450:
#line 9363 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_func_isnull(thd, (yyvsp[-2].item));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 39853 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1451:
#line 9369 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_func_isnotnull(thd, (yyvsp[-3].item));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 39865 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1452:
#line 9375 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_func_equal(thd, (yyvsp[-2].item), (yyvsp[0].item));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 39877 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1453:
#line 9381 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= (*(yyvsp[-1].boolfunc2creator))(0)->create(thd, (yyvsp[-2].item), (yyvsp[0].item));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 39889 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1454:
#line 9387 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= all_any_subquery_creator(thd, (yyvsp[-5].item), (yyvsp[-4].boolfunc2creator), (yyvsp[-3].num), (yyvsp[-1].select_lex));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 39901 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1456:
#line 9397 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_in_subselect(thd, (yyvsp[-2].item), (yyvsp[0].select_lex));
if (unlikely(!(yyval.item)))
MYSQL_YYABORT;
}
#line 39913 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1457:
#line 9403 "/home/buildbot/git/sql/sql_yacc.yy"
{
Item *item= new (thd->mem_root) Item_in_subselect(thd, (yyvsp[-3].item), (yyvsp[0].select_lex));
if (unlikely(!item))
MYSQL_YYABORT;
(yyval.item)= negate_expression(thd, item);
if (unlikely(!(yyval.item)))
MYSQL_YYABORT;
}
#line 39928 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1458:
#line 9412 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= handle_sql2003_note184_exception(thd, (yyvsp[-4].item), true, (yyvsp[-1].item));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 39940 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1459:
#line 9418 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyvsp[-1].item_list)->push_front((yyvsp[-3].item), thd->mem_root);
(yyvsp[-1].item_list)->push_front((yyvsp[-6].item), thd->mem_root);
(yyval.item)= new (thd->mem_root) Item_func_in(thd, *(yyvsp[-1].item_list));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 39954 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1460:
#line 9426 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= handle_sql2003_note184_exception(thd, (yyvsp[-5].item), false, (yyvsp[-1].item));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 39966 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1461:
#line 9432 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyvsp[-1].item_list)->push_front((yyvsp[-3].item), thd->mem_root);
(yyvsp[-1].item_list)->push_front((yyvsp[-7].item), thd->mem_root);
Item_func_in *item= new (thd->mem_root) Item_func_in(thd, *(yyvsp[-1].item_list));
if (unlikely(item == NULL))
MYSQL_YYABORT;
(yyval.item)= item->neg_transformer(thd);
}
#line 39981 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1462:
#line 9441 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_func_between(thd, (yyvsp[-4].item), (yyvsp[-2].item), (yyvsp[0].item));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 39993 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1463:
#line 9447 "/home/buildbot/git/sql/sql_yacc.yy"
{
Item_func_between *item;
item= new (thd->mem_root) Item_func_between(thd, (yyvsp[-5].item), (yyvsp[-2].item), (yyvsp[0].item));
if (unlikely(item == NULL))
MYSQL_YYABORT;
(yyval.item)= item->neg_transformer(thd);
}
#line 40007 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1464:
#line 9455 "/home/buildbot/git/sql/sql_yacc.yy"
{
Item *item1= new (thd->mem_root) Item_func_soundex(thd, (yyvsp[-3].item));
Item *item4= new (thd->mem_root) Item_func_soundex(thd, (yyvsp[0].item));
if (unlikely(item1 == NULL) || unlikely(item4 == NULL))
MYSQL_YYABORT;
(yyval.item)= new (thd->mem_root) Item_func_eq(thd, item1, item4);
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 40023 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1465:
#line 9465 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_func_like(thd, (yyvsp[-2].item), (yyvsp[0].item), escape(thd), false);
if (unlikely(!(yyval.item)))
MYSQL_YYABORT;
}
#line 40035 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1466:
#line 9471 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->escape_used= true;
(yyval.item)= new (thd->mem_root) Item_func_like(thd, (yyvsp[-4].item), (yyvsp[-2].item), (yyvsp[0].item), true);
if (unlikely(!(yyval.item)))
MYSQL_YYABORT;
}
#line 40048 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1467:
#line 9478 "/home/buildbot/git/sql/sql_yacc.yy"
{
Item *item= new (thd->mem_root) Item_func_like(thd, (yyvsp[-3].item), (yyvsp[0].item), escape(thd), false);
if (unlikely(!item))
MYSQL_YYABORT;
(yyval.item)= item->neg_transformer(thd);
}
#line 40061 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1468:
#line 9485 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->escape_used= true;
Item *item= new (thd->mem_root) Item_func_like(thd, (yyvsp[-5].item), (yyvsp[-2].item), (yyvsp[0].item), true);
if (unlikely(!item))
MYSQL_YYABORT;
(yyval.item)= item->neg_transformer(thd);
}
#line 40075 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1469:
#line 9493 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_func_regex(thd, (yyvsp[-2].item), (yyvsp[0].item));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 40087 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1470:
#line 9499 "/home/buildbot/git/sql/sql_yacc.yy"
{
Item *item= new (thd->mem_root) Item_func_regex(thd, (yyvsp[-3].item), (yyvsp[0].item));
if (unlikely(item == NULL))
MYSQL_YYABORT;
(yyval.item)= negate_expression(thd, item);
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 40102 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1472:
#line 9512 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_func_bit_or(thd, (yyvsp[-2].item), (yyvsp[0].item));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 40114 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1473:
#line 9518 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_func_bit_and(thd, (yyvsp[-2].item), (yyvsp[0].item));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 40126 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1474:
#line 9524 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_func_shift_left(thd, (yyvsp[-2].item), (yyvsp[0].item));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 40138 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1475:
#line 9530 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_func_shift_right(thd, (yyvsp[-2].item), (yyvsp[0].item));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 40150 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1476:
#line 9536 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_func_concat_operator_oracle(thd,
(yyvsp[-2].item), (yyvsp[0].item));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 40163 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1477:
#line 9543 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_func_plus(thd, (yyvsp[-2].item), (yyvsp[0].item));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 40175 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1478:
#line 9549 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_func_minus(thd, (yyvsp[-2].item), (yyvsp[0].item));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 40187 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1479:
#line 9555 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_date_add_interval(thd, (yyvsp[-4].item), (yyvsp[-1].item), (yyvsp[0].interval), 0);
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 40199 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1480:
#line 9561 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_date_add_interval(thd, (yyvsp[-4].item), (yyvsp[-1].item), (yyvsp[0].interval), 1);
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 40211 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1481:
#line 9568 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_date_add_interval(thd, (yyvsp[0].item), (yyvsp[-3].item), (yyvsp[-2].interval), 0);
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 40223 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1482:
#line 9574 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_date_add_interval(thd, (yyvsp[0].item), (yyvsp[-3].item), (yyvsp[-2].interval), 0);
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 40235 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1483:
#line 9580 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_date_add_interval(thd, (yyvsp[0].item), (yyvsp[-3].item), (yyvsp[-2].interval), 1);
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 40247 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1484:
#line 9586 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_func_mul(thd, (yyvsp[-2].item), (yyvsp[0].item));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 40259 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1485:
#line 9592 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_func_div(thd, (yyvsp[-2].item), (yyvsp[0].item));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 40271 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1486:
#line 9598 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_func_mod(thd, (yyvsp[-2].item), (yyvsp[0].item));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 40283 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1487:
#line 9604 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_func_int_div(thd, (yyvsp[-2].item), (yyvsp[0].item));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 40295 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1488:
#line 9610 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_func_mod(thd, (yyvsp[-2].item), (yyvsp[0].item));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 40307 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1489:
#line 9616 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_func_bit_xor(thd, (yyvsp[-2].item), (yyvsp[0].item));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 40319 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1499:
#line 9645 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.boolfunc2creator) = &comp_eq_creator; }
#line 40327 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1500:
#line 9646 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.boolfunc2creator) = &comp_ge_creator; }
#line 40335 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1501:
#line 9647 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.boolfunc2creator) = &comp_gt_creator; }
#line 40343 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1502:
#line 9648 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.boolfunc2creator) = &comp_le_creator; }
#line 40351 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1503:
#line 9649 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.boolfunc2creator) = &comp_lt_creator; }
#line 40359 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1504:
#line 9650 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.boolfunc2creator) = &comp_ne_creator; }
#line 40367 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1505:
#line 9654 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.num) = 1; }
#line 40375 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1506:
#line 9655 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.num) = 0; }
#line 40383 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1507:
#line 9660 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.Lex_dyncol_type).set(DYN_COL_NULL); /* automatic type */
Lex->charset= NULL;
}
#line 40394 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1508:
#line 9664 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.Lex_dyncol_type)= (yyvsp[0].Lex_dyncol_type); }
#line 40402 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1509:
#line 9668 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.Lex_dyncol_type)= (yyvsp[0].Lex_dyncol_type); Lex->charset= NULL; }
#line 40410 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1510:
#line 9669 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.Lex_dyncol_type)= (yyvsp[0].Lex_dyncol_type); Lex->charset= NULL; }
#line 40418 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1511:
#line 9670 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.Lex_dyncol_type)= (yyvsp[0].Lex_dyncol_type); }
#line 40426 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1512:
#line 9674 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.Lex_dyncol_type).set(DYN_COL_INT); }
#line 40434 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1513:
#line 9675 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.Lex_dyncol_type).set(DYN_COL_UINT); }
#line 40442 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1514:
#line 9676 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.Lex_dyncol_type).set(DYN_COL_DOUBLE); }
#line 40450 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1515:
#line 9677 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.Lex_dyncol_type).set(DYN_COL_DOUBLE); }
#line 40458 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1516:
#line 9678 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.Lex_dyncol_type).set(DYN_COL_DOUBLE); }
#line 40466 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1517:
#line 9679 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.Lex_dyncol_type).set(DYN_COL_DECIMAL, (yyvsp[0].Lex_length_and_dec)); }
#line 40474 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1518:
#line 9683 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.Lex_dyncol_type).set(DYN_COL_DATE); }
#line 40482 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1519:
#line 9684 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.Lex_dyncol_type).set(DYN_COL_TIME, 0, (yyvsp[0].const_simple_string)); }
#line 40490 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1520:
#line 9685 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.Lex_dyncol_type).set(DYN_COL_DATETIME, 0, (yyvsp[0].const_simple_string)); }
#line 40498 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1521:
#line 9690 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->charset= thd->variables.collation_connection; }
#line 40506 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1522:
#line 9692 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.Lex_dyncol_type).set(DYN_COL_STRING);
}
#line 40516 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1523:
#line 9696 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.Lex_dyncol_type).set(DYN_COL_STRING);
Lex->charset= national_charset_info;
}
#line 40527 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1524:
#line 9704 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
(yyval.dyncol_def)= (DYNCALL_CREATE_DEF *)
alloc_root(thd->mem_root, sizeof(DYNCALL_CREATE_DEF));
if (unlikely((yyval.dyncol_def) == NULL))
MYSQL_YYABORT;
(yyval.dyncol_def)->key= (yyvsp[-3].item);
(yyval.dyncol_def)->value= (yyvsp[-1].item);
(yyval.dyncol_def)->type= (DYNAMIC_COLUMN_TYPE)(yyvsp[0].Lex_dyncol_type).dyncol_type();
(yyval.dyncol_def)->cs= lex->charset;
if ((yyvsp[0].Lex_dyncol_type).length())
(yyval.dyncol_def)->len= strtoul((yyvsp[0].Lex_dyncol_type).length(), NULL, 10);
else
(yyval.dyncol_def)->len= 0;
if ((yyvsp[0].Lex_dyncol_type).dec())
(yyval.dyncol_def)->frac= strtoul((yyvsp[0].Lex_dyncol_type).dec(), NULL, 10);
else
(yyval.dyncol_def)->len= 0;
}
#line 40553 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1525:
#line 9727 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.dyncol_def_list)= new (thd->mem_root) List;
if (unlikely((yyval.dyncol_def_list) == NULL))
MYSQL_YYABORT;
(yyval.dyncol_def_list)->push_back((yyvsp[0].dyncol_def), thd->mem_root);
}
#line 40566 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1526:
#line 9734 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyvsp[-2].dyncol_def_list)->push_back((yyvsp[0].dyncol_def), thd->mem_root);
(yyval.dyncol_def_list)= (yyvsp[-2].dyncol_def_list);
}
#line 40577 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1527:
#line 9742 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.plsql_cursor_attr)= PLSQL_CURSOR_ATTR_ISOPEN; }
#line 40585 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1528:
#line 9743 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.plsql_cursor_attr)= PLSQL_CURSOR_ATTR_FOUND; }
#line 40593 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1529:
#line 9744 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.plsql_cursor_attr)= PLSQL_CURSOR_ATTR_NOTFOUND; }
#line 40601 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1530:
#line 9745 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.plsql_cursor_attr)= PLSQL_CURSOR_ATTR_ROWCOUNT; }
#line 40609 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1531:
#line 9750 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(!((yyval.item)= Lex->make_item_plsql_cursor_attr(thd, &(yyvsp[-2].ident_sys), (yyvsp[0].plsql_cursor_attr)))))
MYSQL_YYABORT;
}
#line 40620 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1532:
#line 9758 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.trim).set(TRIM_BOTH, (yyvsp[0].item)); }
#line 40628 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1533:
#line 9759 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.trim).set(TRIM_LEADING, (yyvsp[-2].item), (yyvsp[0].item)); }
#line 40636 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1534:
#line 9760 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.trim).set(TRIM_TRAILING, (yyvsp[-2].item), (yyvsp[0].item)); }
#line 40644 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1535:
#line 9761 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.trim).set(TRIM_BOTH, (yyvsp[-2].item), (yyvsp[0].item)); }
#line 40652 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1536:
#line 9762 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.trim).set(TRIM_LEADING, (yyvsp[0].item)); }
#line 40660 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1537:
#line 9763 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.trim).set(TRIM_TRAILING, (yyvsp[0].item)); }
#line 40668 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1538:
#line 9764 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.trim).set(TRIM_BOTH, (yyvsp[0].item)); }
#line 40676 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1539:
#line 9765 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.trim).set(TRIM_BOTH, (yyvsp[-2].item), (yyvsp[0].item)); }
#line 40684 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1546:
#line 9803 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.item)= (yyvsp[0].item_param); }
#line 40692 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1548:
#line 9806 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (!Lex->select_stack_top)
{
my_error(ER_INVALID_GROUP_FUNC_USE, MYF(0));
MYSQL_YYABORT;
}
}
#line 40706 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1549:
#line 9814 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (!Lex->select_stack_top)
{
my_error(ER_WRONG_PLACEMENT_OF_WINDOW_FUNCTION, MYF(0));
MYSQL_YYABORT;
}
}
#line 40720 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1551:
#line 9823 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyvsp[-1].item_list)->push_front((yyvsp[-3].item), thd->mem_root);
(yyval.item)= new (thd->mem_root) Item_row(thd, *(yyvsp[-1].item_list));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 40733 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1552:
#line 9830 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_exists_subselect(thd, (yyvsp[-1].select_lex));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 40745 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1553:
#line 9836 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(!((yyval.item)= (yyvsp[-1].item)->make_odbc_literal(thd, &(yyvsp[-2].ident_sys)))))
MYSQL_YYABORT;
}
#line 40756 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1554:
#line 9841 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyvsp[-5].item_list)->push_front((yyvsp[-2].item), thd->mem_root);
Item_func_match *i1= new (thd->mem_root) Item_func_match(thd, *(yyvsp[-5].item_list),
(yyvsp[-1].num));
if (unlikely(i1 == NULL))
MYSQL_YYABORT;
Select->add_ftfunc_to_list(thd, i1);
(yyval.item)= i1;
}
#line 40772 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1555:
#line 9851 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(!((yyval.item)= (yyvsp[-1].Lex_cast_type).create_typecast_item_or_error(thd, (yyvsp[-3].item),
Lex->charset))))
MYSQL_YYABORT;
}
#line 40784 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1556:
#line 9857 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(!((yyval.item)= new(thd->mem_root) Item_func_case_searched(thd, *(yyvsp[-1].item_list)))))
MYSQL_YYABORT;
}
#line 40795 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1557:
#line 9862 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyvsp[-1].item_list)->push_front((yyvsp[-2].item), thd->mem_root);
if (unlikely(!((yyval.item)= new (thd->mem_root) Item_func_case_simple(thd, *(yyvsp[-1].item_list)))))
MYSQL_YYABORT;
}
#line 40807 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1558:
#line 9868 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(!((yyval.item)= (yyvsp[-1].Lex_cast_type).create_typecast_item_or_error(thd, (yyvsp[-3].item),
Lex->charset))))
MYSQL_YYABORT;
}
#line 40819 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1559:
#line 9874 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_func_conv_charset(thd, (yyvsp[-3].item), (yyvsp[-1].charset));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 40831 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1560:
#line 9880 "/home/buildbot/git/sql/sql_yacc.yy"
{
Item_splocal *il= (yyvsp[-1].item)->get_item_splocal();
if (unlikely(il))
my_yyabort_error((ER_WRONG_COLUMN_NAME, MYF(0), il->my_name()->str));
(yyval.item)= new (thd->mem_root) Item_default_value(thd, Lex->current_context(),
(yyvsp[-1].item), 0);
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
Lex->default_used= TRUE;
}
#line 40848 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1561:
#line 9891 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_insert_value(thd, Lex->current_context(),
(yyvsp[-1].item));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 40861 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1562:
#line 9898 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(!((yyval.item)= Lex->create_item_func_nextval(thd, (yyvsp[0].table)))))
MYSQL_YYABORT;
}
#line 40872 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1563:
#line 9903 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(!((yyval.item)= Lex->create_item_func_nextval(thd, (yyvsp[-1].table)))))
MYSQL_YYABORT;
}
#line 40883 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1564:
#line 9908 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(!((yyval.item)= Lex->create_item_func_lastval(thd, (yyvsp[0].table)))))
MYSQL_YYABORT;
}
#line 40894 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1565:
#line 9913 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(!((yyval.item)= Lex->create_item_func_lastval(thd, (yyvsp[-1].table)))))
MYSQL_YYABORT;
}
#line 40905 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1566:
#line 9918 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(!((yyval.item)= Lex->create_item_func_setval(thd, (yyvsp[-3].table), (yyvsp[-1].longlong_number), 0, 1))))
MYSQL_YYABORT;
}
#line 40916 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1567:
#line 9923 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(!((yyval.item)= Lex->create_item_func_setval(thd, (yyvsp[-5].table), (yyvsp[-3].longlong_number), 0, (yyvsp[-1].ulong_num)))))
MYSQL_YYABORT;
}
#line 40927 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1568:
#line 9928 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(!((yyval.item)= Lex->create_item_func_setval(thd, (yyvsp[-7].table), (yyvsp[-5].longlong_number), (yyvsp[-1].ulonglong_number), (yyvsp[-3].ulong_num)))))
MYSQL_YYABORT;
}
#line 40938 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1571:
#line 9937 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.item)= (yyvsp[-1].item); }
#line 40946 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1572:
#line 9939 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (!((yyval.item)= Lex->create_item_query_expression(thd, (yyvsp[0].select_lex)->master_unit())))
MYSQL_YYABORT;
}
#line 40957 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1574:
#line 9948 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(!((yyval.item)= new (thd->mem_root) Item_func_set_collation(thd, (yyvsp[-2].item), (yyvsp[0].charset)))))
MYSQL_YYABORT;
}
#line 40968 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1576:
#line 9957 "/home/buildbot/git/sql/sql_yacc.yy"
{
Type_cast_attributes at(&my_charset_bin);
if (unlikely(!((yyval.item)= type_handler_long_blob.create_typecast_item(thd, (yyvsp[0].item), at))))
MYSQL_YYABORT;
}
#line 40980 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1577:
#line 9963 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= (yyvsp[0].item);
}
#line 40990 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1578:
#line 9967 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= (yyvsp[0].item)->neg(thd);
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 41002 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1579:
#line 9973 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_func_bit_neg(thd, (yyvsp[0].item));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 41014 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1580:
#line 9979 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= negate_expression(thd, (yyvsp[0].item));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 41026 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1582:
#line 9989 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_func_concat(thd, (yyvsp[-2].item), (yyvsp[0].item));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 41038 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1583:
#line 9998 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_datetime_typecast(thd, (yyvsp[-1].item),
AUTO_SEC_PART_DIGITS);
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 41051 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1584:
#line 10005 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_func_timestamp(thd, (yyvsp[-3].item), (yyvsp[-1].item));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 41063 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1585:
#line 10019 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_func_char(thd, *(yyvsp[-1].item_list));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 41075 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1586:
#line 10025 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_func_char(thd, *(yyvsp[-3].item_list), (yyvsp[-1].charset));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 41087 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1587:
#line 10031 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_func_current_user(thd,
Lex->current_context());
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
Lex->set_stmt_unsafe(LEX::BINLOG_STMT_UNSAFE_SYSTEM_FUNCTION);
Lex->safe_to_cache_query= 0;
}
#line 41102 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1588:
#line 10040 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_func_current_role(thd,
Lex->current_context());
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
Lex->set_stmt_unsafe(LEX::BINLOG_STMT_UNSAFE_SYSTEM_FUNCTION);
Lex->safe_to_cache_query= 0;
}
#line 41117 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1589:
#line 10049 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_date_typecast(thd, (yyvsp[-1].item));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 41129 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1590:
#line 10055 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_func_dayofmonth(thd, (yyvsp[-1].item));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 41141 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1591:
#line 10061 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_func_hour(thd, (yyvsp[-1].item));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 41153 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1592:
#line 10067 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_func_insert(thd, (yyvsp[-7].item), (yyvsp[-5].item), (yyvsp[-3].item), (yyvsp[-1].item));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 41165 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1593:
#line 10073 "/home/buildbot/git/sql/sql_yacc.yy"
{
List- *list= new (thd->mem_root) List
- ;
if (unlikely(list == NULL))
MYSQL_YYABORT;
if (unlikely(list->push_front((yyvsp[-1].item), thd->mem_root)) ||
unlikely(list->push_front((yyvsp[-3].item), thd->mem_root)))
MYSQL_YYABORT;
Item_row *item= new (thd->mem_root) Item_row(thd, *list);
if (unlikely(item == NULL))
MYSQL_YYABORT;
(yyval.item)= new (thd->mem_root) Item_func_interval(thd, item);
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 41186 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1594:
#line 10088 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyvsp[-1].item_list)->push_front((yyvsp[-3].item), thd->mem_root);
(yyvsp[-1].item_list)->push_front((yyvsp[-5].item), thd->mem_root);
Item_row *item= new (thd->mem_root) Item_row(thd, *(yyvsp[-1].item_list));
if (unlikely(item == NULL))
MYSQL_YYABORT;
(yyval.item)= new (thd->mem_root) Item_func_interval(thd, item);
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 41203 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1595:
#line 10099 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_func_left(thd, (yyvsp[-3].item), (yyvsp[-1].item));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 41215 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1596:
#line 10105 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_func_minute(thd, (yyvsp[-1].item));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 41227 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1597:
#line 10111 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_func_month(thd, (yyvsp[-1].item));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 41239 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1598:
#line 10117 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_func_right(thd, (yyvsp[-3].item), (yyvsp[-1].item));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 41251 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1599:
#line 10123 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_func_second(thd, (yyvsp[-1].item));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 41263 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1600:
#line 10129 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_func_oracle_sql_rowcount(thd);
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
Lex->set_stmt_unsafe(LEX::BINLOG_STMT_UNSAFE_SYSTEM_FUNCTION);
Lex->safe_to_cache_query= 0;
}
#line 41277 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1601:
#line 10137 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_time_typecast(thd, (yyvsp[-1].item),
AUTO_SEC_PART_DIGITS);
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 41290 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1602:
#line 10144 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= (yyvsp[0].item);
}
#line 41300 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1603:
#line 10148 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(!((yyval.item)= (yyvsp[-1].trim).make_item_func_trim(thd))))
MYSQL_YYABORT;
}
#line 41311 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1604:
#line 10153 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_func_user(thd);
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
Lex->set_stmt_unsafe(LEX::BINLOG_STMT_UNSAFE_SYSTEM_FUNCTION);
Lex->safe_to_cache_query=0;
}
#line 41325 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1605:
#line 10161 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_func_year(thd, (yyvsp[-1].item));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 41337 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1606:
#line 10182 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_date_add_interval(thd, (yyvsp[-3].item), (yyvsp[-1].item),
INTERVAL_DAY, 0);
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 41350 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1607:
#line 10189 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_date_add_interval(thd, (yyvsp[-5].item), (yyvsp[-2].item), (yyvsp[-1].interval), 0);
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 41362 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1608:
#line 10195 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_func_curdate_local(thd);
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
Lex->safe_to_cache_query=0;
}
#line 41375 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1609:
#line 10202 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_func_curtime_local(thd, (yyvsp[0].num));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
Lex->safe_to_cache_query=0;
}
#line 41388 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1610:
#line 10209 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_date_add_interval(thd, (yyvsp[-5].item), (yyvsp[-2].item), (yyvsp[-1].interval), 0);
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 41400 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1611:
#line 10215 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_date_add_interval(thd, (yyvsp[-5].item), (yyvsp[-2].item), (yyvsp[-1].interval), 1);
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 41412 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1612:
#line 10221 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_func_date_format(thd, (yyvsp[-3].item), (yyvsp[-1].item));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 41424 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1613:
#line 10227 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_func_date_format(thd, (yyvsp[-5].item), (yyvsp[-3].item), (yyvsp[-1].item));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 41436 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1614:
#line 10233 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_func_decode(thd, (yyvsp[-3].item), (yyvsp[-1].item));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 41448 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1615:
#line 10239 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyvsp[-1].item_list)->push_front((yyvsp[-3].item), thd->mem_root);
if (unlikely(!((yyval.item)= new (thd->mem_root) Item_func_decode_oracle(thd, *(yyvsp[-1].item_list)))))
MYSQL_YYABORT;
}
#line 41460 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1616:
#line 10245 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)=new (thd->mem_root) Item_extract(thd, (yyvsp[-3].interval), (yyvsp[-1].item));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 41472 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1617:
#line 10251 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_func_get_format(thd, (yyvsp[-3].date_time_type), (yyvsp[-1].item));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 41484 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1618:
#line 10257 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_func_now_local(thd, (yyvsp[0].num));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
Lex->safe_to_cache_query=0;
}
#line 41497 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1619:
#line 10264 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_func_locate(thd, (yyvsp[-1].item), (yyvsp[-3].item));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 41509 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1620:
#line 10270 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_date_add_interval(thd, (yyvsp[-3].item), (yyvsp[-1].item),
INTERVAL_DAY, 1);
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 41522 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1621:
#line 10277 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_date_add_interval(thd, (yyvsp[-5].item), (yyvsp[-2].item), (yyvsp[-1].interval), 1);
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 41534 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1622:
#line 10283 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(!((yyval.item)= Lex->make_item_func_substr(thd, (yyvsp[-5].item), (yyvsp[-3].item), (yyvsp[-1].item)))))
MYSQL_YYABORT;
}
#line 41545 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1623:
#line 10288 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(!((yyval.item)= Lex->make_item_func_substr(thd, (yyvsp[-3].item), (yyvsp[-1].item)))))
MYSQL_YYABORT;
}
#line 41556 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1624:
#line 10293 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(!((yyval.item)= Lex->make_item_func_substr(thd, (yyvsp[-5].item), (yyvsp[-3].item), (yyvsp[-1].item)))))
MYSQL_YYABORT;
}
#line 41567 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1625:
#line 10298 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(!((yyval.item)= Lex->make_item_func_substr(thd, (yyvsp[-3].item), (yyvsp[-1].item)))))
MYSQL_YYABORT;
}
#line 41578 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1626:
#line 10303 "/home/buildbot/git/sql/sql_yacc.yy"
{
/*
Unlike other time-related functions, SYSDATE() is
replication-unsafe because it is not affected by the
TIMESTAMP variable. It is unsafe even if
sysdate_is_now=1, because the slave may have
sysdate_is_now=0.
*/
Lex->set_stmt_unsafe(LEX::BINLOG_STMT_UNSAFE_SYSTEM_FUNCTION);
if (global_system_variables.sysdate_is_now == 0)
(yyval.item)= new (thd->mem_root) Item_func_sysdate_local(thd, (yyvsp[0].num));
else
(yyval.item)= new (thd->mem_root) Item_func_now_local(thd, (yyvsp[0].num));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
Lex->safe_to_cache_query=0;
}
#line 41602 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1627:
#line 10321 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_date_add_interval(thd, (yyvsp[-1].item), (yyvsp[-3].item), (yyvsp[-5].interval_time_st), 0);
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 41614 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1628:
#line 10327 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_func_timestamp_diff(thd, (yyvsp[-3].item), (yyvsp[-1].item), (yyvsp[-5].interval_time_st));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 41626 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1629:
#line 10333 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(!((yyval.item)= (yyvsp[-1].trim).make_item_func_trim_oracle(thd))))
MYSQL_YYABORT;
}
#line 41637 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1630:
#line 10338 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_func_curdate_utc(thd);
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
Lex->safe_to_cache_query=0;
}
#line 41650 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1631:
#line 10345 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_func_curtime_utc(thd, (yyvsp[0].num));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
Lex->safe_to_cache_query=0;
}
#line 41663 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1632:
#line 10352 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_func_now_utc(thd, (yyvsp[0].num));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
Lex->safe_to_cache_query=0;
}
#line 41676 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1633:
#line 10360 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= create_func_dyncol_add(thd, (yyvsp[-3].item), *(yyvsp[-1].dyncol_def_list));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 41688 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1634:
#line 10367 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= create_func_dyncol_delete(thd, (yyvsp[-3].item), *(yyvsp[-1].item_list));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 41700 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1635:
#line 10374 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_func_dyncol_check(thd, (yyvsp[-1].item));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 41712 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1636:
#line 10381 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= create_func_dyncol_create(thd, *(yyvsp[-1].dyncol_def_list));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 41724 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1637:
#line 10388 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
(yyval.item)= create_func_dyncol_get(thd, (yyvsp[-5].item), (yyvsp[-3].item), (yyvsp[-1].Lex_cast_type).type_handler(),
(yyvsp[-1].Lex_cast_type).length(), (yyvsp[-1].Lex_cast_type).dec(),
lex->charset);
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 41739 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1638:
#line 10405 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_func_ascii(thd, (yyvsp[-1].item));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 41751 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1639:
#line 10411 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_func_charset(thd, (yyvsp[-1].item));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 41763 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1640:
#line 10417 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_func_coalesce(thd, *(yyvsp[-1].item_list));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 41775 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1641:
#line 10423 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_func_collation(thd, (yyvsp[-1].item));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 41787 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1642:
#line 10429 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_func_database(thd);
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
Lex->safe_to_cache_query=0;
}
#line 41800 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1643:
#line 10436 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_func_if(thd, (yyvsp[-5].item), (yyvsp[-3].item), (yyvsp[-1].item));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 41812 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1644:
#line 10442 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_func_format(thd, (yyvsp[-3].item), (yyvsp[-1].item));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 41824 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1645:
#line 10448 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_func_format(thd, (yyvsp[-5].item), (yyvsp[-3].item), (yyvsp[-1].item));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 41836 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1646:
#line 10457 "/home/buildbot/git/sql/sql_yacc.yy"
{
List
- *list= new (thd->mem_root) List
- ;
if (unlikely(list == NULL))
MYSQL_YYABORT;
list->push_back((yyvsp[-1].item), thd->mem_root);
(yyval.item)= new (thd->mem_root) Item_func_last_value(thd, *list);
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 41853 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1647:
#line 10468 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyvsp[-3].item_list)->push_back((yyvsp[-1].item), thd->mem_root);
(yyval.item)= new (thd->mem_root) Item_func_last_value(thd, *(yyvsp[-3].item_list));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 41866 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1648:
#line 10475 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_func_microsecond(thd, (yyvsp[-1].item));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 41878 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1649:
#line 10481 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_func_mod(thd, (yyvsp[-3].item), (yyvsp[-1].item));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 41890 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1650:
#line 10487 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root)
Item_func_password(thd, (yyvsp[-1].item), Item_func_password::OLD);
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 41903 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1651:
#line 10494 "/home/buildbot/git/sql/sql_yacc.yy"
{
Item* i1;
i1= new (thd->mem_root) Item_func_password(thd, (yyvsp[-1].item));
if (unlikely(i1 == NULL))
MYSQL_YYABORT;
(yyval.item)= i1;
}
#line 41917 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1652:
#line 10502 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_func_quarter(thd, (yyvsp[-1].item));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 41929 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1653:
#line 10508 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_func_repeat(thd, (yyvsp[-3].item), (yyvsp[-1].item));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 41941 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1654:
#line 10514 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(!((yyval.item)= Lex->make_item_func_replace(thd, (yyvsp[-5].item), (yyvsp[-3].item), (yyvsp[-1].item)))))
MYSQL_YYABORT;
}
#line 41952 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1655:
#line 10519 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_func_reverse(thd, (yyvsp[-1].item));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 41964 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1656:
#line 10525 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_func_row_count(thd);
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
Lex->set_stmt_unsafe(LEX::BINLOG_STMT_UNSAFE_SYSTEM_FUNCTION);
Lex->safe_to_cache_query= 0;
}
#line 41978 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1657:
#line 10533 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_func_round(thd, (yyvsp[-3].item), (yyvsp[-1].item), 1);
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 41990 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1658:
#line 10539 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_func_week(thd, (yyvsp[-1].item));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 42002 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1659:
#line 10545 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_func_week(thd, (yyvsp[-3].item), (yyvsp[-1].item));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 42014 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1660:
#line 10551 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_func_weight_string(thd, (yyvsp[-2].item), 0, 0, (yyvsp[-1].ulong_num));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 42026 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1661:
#line 10557 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root)
Item_func_weight_string(thd, (yyvsp[-5].item), 0, (yyvsp[-2].ulong_num),
(yyvsp[-1].ulong_num) | MY_STRXFRM_PAD_WITH_SPACE);
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 42040 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1662:
#line 10565 "/home/buildbot/git/sql/sql_yacc.yy"
{
Item *item= new (thd->mem_root) Item_char_typecast(thd, (yyvsp[-4].item), (yyvsp[-1].ulong_num),
&my_charset_bin);
if (unlikely(item == NULL))
MYSQL_YYABORT;
(yyval.item)= new (thd->mem_root)
Item_func_weight_string(thd, item, 0, (yyvsp[-1].ulong_num),
MY_STRXFRM_PAD_WITH_SPACE);
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 42058 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1663:
#line 10577 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_func_weight_string(thd, (yyvsp[-7].item), (yyvsp[-5].ulong_num), (yyvsp[-3].ulong_num),
(yyvsp[-1].ulong_num));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 42071 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1664:
#line 10596 "/home/buildbot/git/sql/sql_yacc.yy"
{
#ifdef HAVE_DLOPEN
udf_func *udf= 0;
LEX *lex= Lex;
if (using_udf_functions &&
(udf= find_udf((yyvsp[-1].ident_sys).str, (yyvsp[-1].ident_sys).length)) &&
udf->type == UDFTYPE_AGGREGATE)
{
if (unlikely(lex->current_select->inc_in_sum_expr()))
{
thd->parse_error();
MYSQL_YYABORT;
}
}
/* Temporary placing the result of find_udf in $3 */
(yyval.udf)= udf;
#endif
}
#line 42096 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1665:
#line 10615 "/home/buildbot/git/sql/sql_yacc.yy"
{
const Type_handler *h;
Create_func *builder;
Item *item= NULL;
if (unlikely(check_routine_name(&(yyvsp[-4].ident_sys))))
MYSQL_YYABORT;
/*
Implementation note:
names are resolved with the following order:
- MySQL native functions,
- User Defined Functions,
- Constructors, like POINT(1,1)
- Stored Functions (assuming the current
database)
This will be revised with WL#2128 (SQL PATH)
*/
if ((builder= find_native_function_builder(thd, &(yyvsp[-4].ident_sys))))
{
item= builder->create_func(thd, &(yyvsp[-4].ident_sys), (yyvsp[-1].item_list));
}
else if ((h= Type_handler::handler_by_name(thd, (yyvsp[-4].ident_sys))) &&
(item= h->make_constructor_item(thd, (yyvsp[-1].item_list))))
{
// Found a constructor with a proper argument count
}
else
{
#ifdef HAVE_DLOPEN
/* Retrieving the result of find_udf */
udf_func *udf= (yyvsp[-2].udf);
if (udf)
{
if (udf->type == UDFTYPE_AGGREGATE)
{
Select->in_sum_expr--;
}
item= Create_udf_func::s_singleton.create(thd, udf, (yyvsp[-1].item_list));
}
else
#endif
{
builder= find_qualified_function_builder(thd);
DBUG_ASSERT(builder);
item= builder->create_func(thd, &(yyvsp[-4].ident_sys), (yyvsp[-1].item_list));
}
}
if (unlikely(! ((yyval.item)= item)))
MYSQL_YYABORT;
}
#line 42157 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1666:
#line 10670 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (!((yyval.item)= Lex->make_item_func_call_native_or_parse_error(thd,
(yyvsp[-3].kwd), (yyvsp[-1].item_list))))
MYSQL_YYABORT;
}
#line 42169 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1667:
#line 10676 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (!((yyval.item)= Lex->make_item_func_call_native_or_parse_error(thd,
(yyvsp[-3].kwd), (yyvsp[-1].item_list))))
MYSQL_YYABORT;
}
#line 42181 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1668:
#line 10682 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (!((yyval.item)= Lex->make_item_func_call_native_or_parse_error(thd,
(yyvsp[-3].kwd), (yyvsp[-1].item_list))))
MYSQL_YYABORT;
}
#line 42193 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1669:
#line 10688 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(!((yyval.item)= Lex->make_item_func_call_generic(thd, &(yyvsp[-5].ident_cli), &(yyvsp[-3].ident_cli), (yyvsp[-1].item_list)))))
MYSQL_YYABORT;
}
#line 42204 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1670:
#line 10696 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.num)= (yyvsp[-1].num) | (yyvsp[0].num); }
#line 42212 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1671:
#line 10698 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.num)= FT_BOOL; }
#line 42220 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1672:
#line 10702 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.num)= FT_NL; }
#line 42228 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1673:
#line 10703 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.num)= FT_NL; }
#line 42236 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1674:
#line 10707 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.num)= 0; }
#line 42244 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1675:
#line 10708 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.num)= FT_EXPAND; }
#line 42252 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1676:
#line 10712 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.item_list)= NULL; }
#line 42260 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1677:
#line 10713 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.item_list)= (yyvsp[0].item_list); }
#line 42268 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1678:
#line 10718 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item_list)= new (thd->mem_root) List- ;
if (unlikely((yyval.item_list) == NULL))
MYSQL_YYABORT;
(yyval.item_list)->push_back((yyvsp[0].item), thd->mem_root);
}
#line 42281 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1679:
#line 10725 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyvsp[-2].item_list)->push_back((yyvsp[0].item), thd->mem_root);
(yyval.item_list)= (yyvsp[-2].item_list);
}
#line 42292 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1680:
#line 10733 "/home/buildbot/git/sql/sql_yacc.yy"
{
/*
Use Item::name as a storage for the attribute value of user
defined function argument. It is safe to use Item::name
because the syntax will not allow having an explicit name here.
See WL#1017 re. udf attributes.
*/
if ((yyvsp[0].lex_str).str)
{
(yyvsp[-2].item)->common_flags&= ~IS_AUTO_GENERATED_NAME;
(yyvsp[-2].item)->set_name(thd, (yyvsp[0].lex_str));
}
/*
A field has to have its proper name in order for name
resolution to work, something we are only guaranteed if we
parse it out. If we hijack the input stream with
remember_name we may get quoted or escaped names.
*/
else if ((yyvsp[-2].item)->type() != Item::FIELD_ITEM &&
(yyvsp[-2].item)->type() != Item::REF_ITEM /* For HAVING */ )
(yyvsp[-2].item)->set_name(thd, (yyvsp[-3].simple_string), (uint) ((yyvsp[-1].simple_string) - (yyvsp[-3].simple_string)), thd->charset());
(yyval.item)= (yyvsp[-2].item);
}
#line 42322 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1681:
#line 10760 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_sum_avg(thd, (yyvsp[-1].item), FALSE);
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 42334 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1682:
#line 10766 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_sum_avg(thd, (yyvsp[-1].item), TRUE);
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 42346 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1683:
#line 10772 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_sum_and(thd, (yyvsp[-1].item));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 42358 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1684:
#line 10778 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_sum_or(thd, (yyvsp[-1].item));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 42370 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1685:
#line 10784 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_sum_xor(thd, (yyvsp[-1].item));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 42382 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1686:
#line 10790 "/home/buildbot/git/sql/sql_yacc.yy"
{
Item *item= new (thd->mem_root) Item_int(thd, (int32) 0L, 1);
if (unlikely(item == NULL))
MYSQL_YYABORT;
(yyval.item)= new (thd->mem_root) Item_sum_count(thd, item);
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 42397 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1687:
#line 10799 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_sum_count(thd, (yyvsp[-1].item));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 42409 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1688:
#line 10805 "/home/buildbot/git/sql/sql_yacc.yy"
{ Select->in_sum_expr++; }
#line 42417 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1689:
#line 10807 "/home/buildbot/git/sql/sql_yacc.yy"
{ Select->in_sum_expr--; }
#line 42425 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1690:
#line 10809 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_sum_count(thd, *(yyvsp[-2].item_list));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 42437 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1691:
#line 10815 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_sum_min(thd, (yyvsp[-1].item));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 42449 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1692:
#line 10826 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_sum_min(thd, (yyvsp[-1].item));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 42461 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1693:
#line 10832 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_sum_max(thd, (yyvsp[-1].item));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 42473 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1694:
#line 10838 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_sum_max(thd, (yyvsp[-1].item));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 42485 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1695:
#line 10844 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_sum_std(thd, (yyvsp[-1].item), 0);
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 42497 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1696:
#line 10850 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_sum_variance(thd, (yyvsp[-1].item), 0);
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 42509 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1697:
#line 10856 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_sum_std(thd, (yyvsp[-1].item), 1);
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 42521 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1698:
#line 10862 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_sum_variance(thd, (yyvsp[-1].item), 1);
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 42533 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1699:
#line 10868 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_sum_sum(thd, (yyvsp[-1].item), FALSE);
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 42545 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1700:
#line 10874 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_sum_sum(thd, (yyvsp[-1].item), TRUE);
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 42557 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1701:
#line 10880 "/home/buildbot/git/sql/sql_yacc.yy"
{ Select->in_sum_expr++; }
#line 42565 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1702:
#line 10884 "/home/buildbot/git/sql/sql_yacc.yy"
{
SELECT_LEX *sel= Select;
sel->in_sum_expr--;
(yyval.item)= new (thd->mem_root)
Item_func_group_concat(thd, Lex->current_context(),
(yyvsp[-6].num), (yyvsp[-4].item_list),
sel->gorder_list, (yyvsp[-2].string), (yyvsp[-1].num),
sel->select_limit,
sel->offset_limit);
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
sel->select_limit= NULL;
sel->offset_limit= NULL;
sel->explicit_limit= 0;
(yyvsp[-4].item_list)->empty();
sel->gorder_list.empty();
}
#line 42589 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1703:
#line 10902 "/home/buildbot/git/sql/sql_yacc.yy"
{ Select->in_sum_expr++; }
#line 42597 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1704:
#line 10905 "/home/buildbot/git/sql/sql_yacc.yy"
{
SELECT_LEX *sel= Select;
List
- *args= (yyvsp[-3].item_list);
sel->in_sum_expr--;
if (args && args->elements > 1)
{
/* JSON_ARRAYAGG supports only one parameter */
my_error(ER_WRONG_PARAMCOUNT_TO_NATIVE_FCT, MYF(0), "JSON_ARRAYAGG");
MYSQL_YYABORT;
}
String* s= new (thd->mem_root) String(",", 1, &my_charset_latin1);
if (unlikely(s == NULL))
MYSQL_YYABORT;
(yyval.item)= new (thd->mem_root)
Item_func_json_arrayagg(thd, Lex->current_context(),
(yyvsp[-5].num), args,
sel->gorder_list, s, (yyvsp[-1].num),
sel->select_limit,
sel->offset_limit);
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
sel->select_limit= NULL;
sel->offset_limit= NULL;
sel->explicit_limit= 0;
(yyvsp[-3].item_list)->empty();
sel->gorder_list.empty();
}
#line 42632 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1705:
#line 10934 "/home/buildbot/git/sql/sql_yacc.yy"
{ Select->in_sum_expr++; }
#line 42640 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1706:
#line 10936 "/home/buildbot/git/sql/sql_yacc.yy"
{
SELECT_LEX *sel= Select;
sel->in_sum_expr--;
(yyval.item)= new (thd->mem_root) Item_func_json_objectagg(thd, (yyvsp[-3].item), (yyvsp[-1].item));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 42655 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1707:
#line 10948 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_window_func(thd, (Item_sum *) (yyvsp[-2].item), (yyvsp[0].lex_str_ptr));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
if (unlikely(Select->add_window_func((Item_window_func *) (yyval.item))))
MYSQL_YYABORT;
}
#line 42669 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1708:
#line 10957 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
if (unlikely(Select->add_window_spec(thd, lex->win_ref,
Select->group_list,
Select->order_list,
lex->win_frame)))
MYSQL_YYABORT;
(yyval.item)= new (thd->mem_root) Item_window_func(thd, (Item_sum *) (yyvsp[-2].item),
thd->lex->win_spec);
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
if (unlikely(Select->add_window_func((Item_window_func *) (yyval.item))))
MYSQL_YYABORT;
}
#line 42690 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1710:
#line 10977 "/home/buildbot/git/sql/sql_yacc.yy"
{
((Item_sum *) (yyvsp[0].item))->mark_as_window_func_sum_expr();
}
#line 42700 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1711:
#line 10982 "/home/buildbot/git/sql/sql_yacc.yy"
{
Item* item = (Item*)(yyvsp[0].item);
/* Only UDF aggregate here possible */
if ((item == NULL) ||
(item->type() != Item::SUM_FUNC_ITEM)
|| (((Item_sum *)item)->sum_func() != Item_sum::UDF_SUM_FUNC))
{
thd->parse_error();
MYSQL_YYABORT;
}
((Item_sum *) (yyvsp[0].item))->mark_as_window_func_sum_expr();
}
#line 42720 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1712:
#line 10999 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_sum_row_number(thd);
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 42732 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1713:
#line 11006 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_sum_rank(thd);
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 42744 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1714:
#line 11013 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_sum_dense_rank(thd);
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 42756 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1715:
#line 11020 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_sum_percent_rank(thd);
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 42768 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1716:
#line 11027 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_sum_cume_dist(thd);
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 42780 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1717:
#line 11034 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_sum_ntile(thd, (yyvsp[-1].item));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 42792 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1718:
#line 11041 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_sum_first_value(thd, (yyvsp[-1].item));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 42804 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1719:
#line 11048 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_sum_last_value(thd, (yyvsp[-1].item));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 42816 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1720:
#line 11055 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_sum_nth_value(thd, (yyvsp[-3].item), (yyvsp[-1].item));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 42828 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1721:
#line 11062 "/home/buildbot/git/sql/sql_yacc.yy"
{
/* No second argument defaults to 1. */
Item* item_offset= new (thd->mem_root) Item_uint(thd, 1);
if (unlikely(item_offset == NULL))
MYSQL_YYABORT;
(yyval.item)= new (thd->mem_root) Item_sum_lead(thd, (yyvsp[-1].item), item_offset);
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 42844 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1722:
#line 11073 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_sum_lead(thd, (yyvsp[-3].item), (yyvsp[-1].item));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 42856 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1723:
#line 11080 "/home/buildbot/git/sql/sql_yacc.yy"
{
/* No second argument defaults to 1. */
Item* item_offset= new (thd->mem_root) Item_uint(thd, 1);
if (unlikely(item_offset == NULL))
MYSQL_YYABORT;
(yyval.item)= new (thd->mem_root) Item_sum_lag(thd, (yyvsp[-1].item), item_offset);
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 42872 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1724:
#line 11091 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_sum_lag(thd, (yyvsp[-3].item), (yyvsp[-1].item));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 42884 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1725:
#line 11103 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
if (unlikely(Select->add_window_spec(thd, lex->win_ref,
Select->group_list,
Select->order_list,
NULL)))
MYSQL_YYABORT;
(yyval.item)= new (thd->mem_root) Item_window_func(thd, (Item_sum *) (yyvsp[-4].item),
thd->lex->win_spec);
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
if (unlikely(Select->add_window_func((Item_window_func *) (yyval.item))))
MYSQL_YYABORT;
}
#line 42905 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1726:
#line 11121 "/home/buildbot/git/sql/sql_yacc.yy"
{ Select->prepare_add_window_spec(thd); }
#line 42913 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1727:
#line 11123 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= (yyvsp[-6].item);
}
#line 42923 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1728:
#line 11127 "/home/buildbot/git/sql/sql_yacc.yy"
{
Item *args= new (thd->mem_root) Item_decimal(thd, "0.5", 3,
thd->charset());
if (unlikely(args == NULL) || unlikely(thd->is_error()))
MYSQL_YYABORT;
Select->prepare_add_window_spec(thd);
if (unlikely(add_order_to_list(thd, (yyvsp[-1].item),FALSE)))
MYSQL_YYABORT;
(yyval.item)= new (thd->mem_root) Item_sum_percentile_cont(thd, args);
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 42943 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1729:
#line 11144 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_sum_percentile_cont(thd, (yyvsp[-1].item));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 42955 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1730:
#line 11150 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_sum_percentile_disc(thd, (yyvsp[-1].item));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 42967 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1731:
#line 11159 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(add_order_to_list(thd, (yyvsp[-1].item),(bool) (yyvsp[0].num))))
MYSQL_YYABORT;
}
#line 42978 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1732:
#line 11168 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.lex_str_ptr)= (LEX_CSTRING *) thd->memdup(&(yyvsp[0].ident_sys), sizeof(LEX_CSTRING));
if (unlikely((yyval.lex_str_ptr) == NULL))
MYSQL_YYABORT;
}
#line 42990 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1733:
#line 11177 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(! Lex->parsing_options.allows_variable))
my_yyabort_error((ER_VIEW_SELECT_VARIABLE, MYF(0)));
}
#line 43001 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1734:
#line 11182 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= (yyvsp[0].item);
}
#line 43011 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1735:
#line 11189 "/home/buildbot/git/sql/sql_yacc.yy"
{
Item_func_set_user_var *item;
(yyval.item)= item= new (thd->mem_root) Item_func_set_user_var(thd, &(yyvsp[-2].lex_str), (yyvsp[0].item));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
LEX *lex= Lex;
lex->uncacheable(UNCACHEABLE_SIDEEFFECT);
lex->set_var_list.push_back(item, thd->mem_root);
}
#line 43027 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1736:
#line 11199 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_func_get_user_var(thd, &(yyvsp[0].lex_str));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
LEX *lex= Lex;
lex->uncacheable(UNCACHEABLE_SIDEEFFECT);
}
#line 43041 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1737:
#line 11207 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(!((yyval.item)= Lex->make_item_sysvar(thd, (yyvsp[-1].var_type), &(yyvsp[0].ident_sys)))))
MYSQL_YYABORT;
}
#line 43052 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1738:
#line 11212 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(!((yyval.item)= Lex->make_item_sysvar(thd, (yyvsp[-3].var_type), &(yyvsp[-2].ident_sys), &(yyvsp[0].ident_sys)))))
MYSQL_YYABORT;
}
#line 43063 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1739:
#line 11219 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.num) = 0; }
#line 43071 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1740:
#line 11220 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.num) = 1; }
#line 43079 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1741:
#line 11225 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.string)= new (thd->mem_root) String(",", 1, &my_charset_latin1);
if (unlikely((yyval.string) == NULL))
MYSQL_YYABORT;
}
#line 43091 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1742:
#line 11230 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.string) = (yyvsp[0].string); }
#line 43099 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1745:
#line 11240 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(add_gorder_to_list(thd, (yyvsp[-1].item),(bool) (yyvsp[0].num))))
MYSQL_YYABORT;
}
#line 43110 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1746:
#line 11245 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(add_gorder_to_list(thd, (yyvsp[-1].item),(bool) (yyvsp[0].num))))
MYSQL_YYABORT;
}
#line 43121 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1747:
#line 11252 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.num) = 0; }
#line 43129 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1748:
#line 11253 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.num) = 1; }
#line 43137 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1749:
#line 11257 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 43145 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1750:
#line 11262 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->set_stmt_unsafe(LEX::BINLOG_STMT_UNSAFE_LIMIT);
}
#line 43155 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1751:
#line 11269 "/home/buildbot/git/sql/sql_yacc.yy"
{
SELECT_LEX *sel= Select;
sel->select_limit= (yyvsp[0].item);
sel->offset_limit= 0;
sel->explicit_limit= 1;
}
#line 43168 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1752:
#line 11276 "/home/buildbot/git/sql/sql_yacc.yy"
{
SELECT_LEX *sel= Select;
sel->select_limit= (yyvsp[0].item);
sel->offset_limit= (yyvsp[-2].item);
sel->explicit_limit= 1;
}
#line 43181 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1753:
#line 11283 "/home/buildbot/git/sql/sql_yacc.yy"
{
SELECT_LEX *sel= Select;
sel->select_limit= (yyvsp[-2].item);
sel->offset_limit= (yyvsp[0].item);
sel->explicit_limit= 1;
}
#line 43194 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1754:
#line 11295 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
if (unlikely(lex->current_select->inc_in_sum_expr()))
{
thd->parse_error();
MYSQL_YYABORT;
}
}
#line 43209 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1755:
#line 11304 "/home/buildbot/git/sql/sql_yacc.yy"
{
Select->in_sum_expr--;
(yyval.item)= (yyvsp[0].item);
}
#line 43220 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1756:
#line 11312 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.Lex_cast_type).set(&type_handler_long_blob, (yyvsp[0].const_simple_string)); Lex->charset= &my_charset_bin; }
#line 43228 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1757:
#line 11314 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->charset= thd->variables.collation_connection; }
#line 43236 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1758:
#line 11316 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.Lex_cast_type).set(&type_handler_long_blob, (yyvsp[-2].const_simple_string)); }
#line 43244 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1759:
#line 11318 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->charset= thd->variables.collation_connection; }
#line 43252 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1760:
#line 11320 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.Lex_cast_type).set(&type_handler_long_blob, (yyvsp[-2].const_simple_string)); }
#line 43260 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1761:
#line 11322 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->charset= thd->variables.collation_connection; }
#line 43268 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1762:
#line 11324 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.Lex_cast_type).set(&type_handler_long_blob, (yyvsp[-2].const_simple_string)); }
#line 43276 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1763:
#line 11326 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->charset= national_charset_info;
(yyval.Lex_cast_type).set(&type_handler_long_blob, (yyvsp[0].const_simple_string), 0);
}
#line 43287 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1764:
#line 11330 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.Lex_cast_type)= (yyvsp[0].Lex_cast_type); Lex->charset= NULL; }
#line 43295 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1765:
#line 11331 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.Lex_cast_type)= (yyvsp[0].Lex_cast_type); Lex->charset= NULL; }
#line 43303 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1766:
#line 11333 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (Lex->set_cast_type_udt(&(yyval.Lex_cast_type), (yyvsp[0].ident_sys)))
MYSQL_YYABORT;
}
#line 43314 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1767:
#line 11338 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (Lex->set_cast_type_udt(&(yyval.Lex_cast_type), (yyvsp[0].kwd)))
MYSQL_YYABORT;
}
#line 43325 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1768:
#line 11343 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (Lex->set_cast_type_udt(&(yyval.Lex_cast_type), (yyvsp[0].kwd)))
MYSQL_YYABORT;
}
#line 43336 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1769:
#line 11350 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.Lex_cast_type).set(&type_handler_slonglong); }
#line 43344 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1770:
#line 11351 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.Lex_cast_type).set(&type_handler_slonglong); }
#line 43352 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1771:
#line 11352 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.Lex_cast_type).set(&type_handler_slonglong); }
#line 43360 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1772:
#line 11353 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.Lex_cast_type).set(&type_handler_ulonglong); }
#line 43368 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1773:
#line 11354 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.Lex_cast_type).set(&type_handler_ulonglong); }
#line 43376 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1774:
#line 11355 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.Lex_cast_type).set(&type_handler_newdecimal, (yyvsp[0].Lex_length_and_dec)); }
#line 43384 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1775:
#line 11356 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.Lex_cast_type).set(&type_handler_float); }
#line 43392 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1776:
#line 11357 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.Lex_cast_type).set(&type_handler_double, (yyvsp[0].Lex_length_and_dec)); }
#line 43400 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1777:
#line 11361 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.Lex_cast_type).set(&type_handler_newdate); }
#line 43408 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1778:
#line 11362 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.Lex_cast_type).set(&type_handler_time2, 0, (yyvsp[0].const_simple_string)); }
#line 43416 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1779:
#line 11363 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.Lex_cast_type).set(&type_handler_datetime2, 0, (yyvsp[0].const_simple_string)); }
#line 43424 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1780:
#line 11365 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.Lex_cast_type).set(&type_handler_interval_DDhhmmssff, 0, (yyvsp[0].const_simple_string));
}
#line 43434 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1781:
#line 11371 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.item_list)= NULL; }
#line 43442 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1782:
#line 11372 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.item_list)= (yyvsp[0].item_list);}
#line 43450 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1783:
#line 11377 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(!((yyval.item_list)= List
- ::make(thd->mem_root, (yyvsp[0].item)))))
MYSQL_YYABORT;
}
#line 43461 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1784:
#line 11382 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyvsp[-2].item_list)->push_back((yyvsp[0].item), thd->mem_root);
(yyval.item_list)= (yyvsp[-2].item_list);
}
#line 43472 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1785:
#line 11389 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.item_list)= (yyvsp[0].item_list); }
#line 43480 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1786:
#line 11390 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.item_list)= (yyvsp[-1].item_list); }
#line 43488 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1787:
#line 11395 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item_list)= new (thd->mem_root) List
- ;
if (unlikely((yyval.item_list) == NULL) ||
unlikely((yyval.item_list)->push_back((yyvsp[0].item), thd->mem_root)))
MYSQL_YYABORT;
}
#line 43501 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1788:
#line 11402 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyvsp[-2].item_list)->push_back((yyvsp[0].item), thd->mem_root);
(yyval.item_list)= (yyvsp[-2].item_list);
}
#line 43512 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1789:
#line 11410 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item_list)= new (thd->mem_root) List
- ;
if (unlikely((yyval.item_list) == NULL))
MYSQL_YYABORT;
if (unlikely((yyval.item_list)->push_back((yyvsp[-2].item), thd->mem_root) ||
(yyval.item_list)->push_back((yyvsp[0].item), thd->mem_root)))
MYSQL_YYABORT;
}
#line 43527 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1790:
#line 11419 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely((yyvsp[-4].item_list)->push_back((yyvsp[-2].item), thd->mem_root) ||
(yyvsp[-4].item_list)->push_back((yyvsp[0].item), thd->mem_root)))
MYSQL_YYABORT;
(yyval.item_list)= (yyvsp[-4].item_list);
}
#line 43540 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1792:
#line 11430 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely((yyvsp[-2].item_list)->push_back((yyvsp[0].item), thd->mem_root)))
MYSQL_YYABORT;
(yyval.item_list)= (yyvsp[-2].item_list);
}
#line 43552 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1793:
#line 11439 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item_list)= new (thd->mem_root) List
- ;
if (unlikely((yyval.item_list) == NULL) ||
unlikely((yyval.item_list)->push_back((yyvsp[-2].item), thd->mem_root)) ||
unlikely((yyval.item_list)->push_back((yyvsp[0].item), thd->mem_root)))
MYSQL_YYABORT;
}
#line 43567 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1794:
#line 11448 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item_list)= (yyvsp[-2].item_list);
if (unlikely((yyval.item_list)->push_back((yyvsp[0].item), thd->mem_root)))
MYSQL_YYABORT;
}
#line 43579 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1795:
#line 11459 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.table_list)= (yyvsp[0].table_list); }
#line 43587 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1796:
#line 11461 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
if (unlikely(!((yyval.table_list)= lex->current_select->nest_last_join(thd))))
{
thd->parse_error();
MYSQL_YYABORT;
}
}
#line 43602 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1797:
#line 11472 "/home/buildbot/git/sql/sql_yacc.yy"
{ MYSQL_YYABORT_UNLESS((yyval.table_list)=(yyvsp[0].table_list)); }
#line 43610 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1798:
#line 11483 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.table_list)=(yyvsp[0].table_list); }
#line 43618 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1799:
#line 11484 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.table_list)=(yyvsp[-1].table_list); }
#line 43626 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1800:
#line 11491 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.table_list)=(yyvsp[0].table_list);
Select->add_joined_table((yyvsp[0].table_list));
}
#line 43637 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1801:
#line 11496 "/home/buildbot/git/sql/sql_yacc.yy"
{
MYSQL_YYABORT_UNLESS((yyvsp[-2].table_list) && ((yyval.table_list)=(yyvsp[0].table_list)));
Select->add_joined_table((yyvsp[0].table_list));
}
#line 43648 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1802:
#line 11510 "/home/buildbot/git/sql/sql_yacc.yy"
{
MYSQL_YYABORT_UNLESS((yyvsp[-2].table_list) && ((yyval.table_list)=(yyvsp[0].table_list)));
if (unlikely(Select->add_cross_joined_table((yyvsp[-2].table_list), (yyvsp[0].table_list), (yyvsp[-1].num))))
MYSQL_YYABORT;
}
#line 43660 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1803:
#line 11517 "/home/buildbot/git/sql/sql_yacc.yy"
{
MYSQL_YYABORT_UNLESS((yyvsp[-3].table_list) && (yyvsp[-1].table_list));
Select->add_joined_table((yyvsp[-3].table_list));
Select->add_joined_table((yyvsp[-1].table_list));
/* Change the current name resolution context to a local context. */
if (unlikely(push_new_name_resolution_context(thd, (yyvsp[-3].table_list), (yyvsp[-1].table_list))))
MYSQL_YYABORT;
Select->parsing_place= IN_ON;
}
#line 43676 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1804:
#line 11527 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyvsp[-3].table_list)->straight=(yyvsp[-4].num);
add_join_on(thd, (yyvsp[-3].table_list), (yyvsp[0].item));
(yyvsp[-3].table_list)->on_context= Lex->pop_context();
Select->parsing_place= NO_MATTER;
}
#line 43689 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1805:
#line 11535 "/home/buildbot/git/sql/sql_yacc.yy"
{
MYSQL_YYABORT_UNLESS((yyvsp[-3].table_list) && (yyvsp[-1].table_list));
Select->add_joined_table((yyvsp[-3].table_list));
Select->add_joined_table((yyvsp[-1].table_list));
}
#line 43701 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1806:
#line 11541 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyvsp[-5].table_list)->straight=(yyvsp[-6].num);
add_join_natural((yyvsp[-7].table_list),(yyvsp[-5].table_list),(yyvsp[-1].string_list),Select);
(yyval.table_list)=(yyvsp[-5].table_list);
}
#line 43713 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1807:
#line 11547 "/home/buildbot/git/sql/sql_yacc.yy"
{
MYSQL_YYABORT_UNLESS((yyvsp[-3].table_list) && ((yyval.table_list)=(yyvsp[0].table_list)));
Select->add_joined_table((yyvsp[-3].table_list));
Select->add_joined_table((yyvsp[0].table_list));
(yyvsp[0].table_list)->straight=(yyvsp[-1].num);
add_join_natural((yyvsp[-3].table_list),(yyvsp[0].table_list),NULL,Select);
}
#line 43727 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1808:
#line 11558 "/home/buildbot/git/sql/sql_yacc.yy"
{
MYSQL_YYABORT_UNLESS((yyvsp[-5].table_list) && (yyvsp[-1].table_list));
Select->add_joined_table((yyvsp[-5].table_list));
Select->add_joined_table((yyvsp[-1].table_list));
/* Change the current name resolution context to a local context. */
if (unlikely(push_new_name_resolution_context(thd, (yyvsp[-5].table_list), (yyvsp[-1].table_list))))
MYSQL_YYABORT;
Select->parsing_place= IN_ON;
}
#line 43743 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1809:
#line 11568 "/home/buildbot/git/sql/sql_yacc.yy"
{
add_join_on(thd, (yyvsp[-3].table_list), (yyvsp[0].item));
(yyvsp[-3].table_list)->on_context= Lex->pop_context();
(yyvsp[-3].table_list)->outer_join|=JOIN_TYPE_LEFT;
(yyval.table_list)=(yyvsp[-3].table_list);
Select->parsing_place= NO_MATTER;
}
#line 43757 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1810:
#line 11576 "/home/buildbot/git/sql/sql_yacc.yy"
{
MYSQL_YYABORT_UNLESS((yyvsp[-4].table_list) && (yyvsp[0].table_list));
Select->add_joined_table((yyvsp[-4].table_list));
Select->add_joined_table((yyvsp[0].table_list));
}
#line 43769 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1811:
#line 11582 "/home/buildbot/git/sql/sql_yacc.yy"
{
add_join_natural((yyvsp[-9].table_list),(yyvsp[-5].table_list),(yyvsp[-1].string_list),Select);
(yyvsp[-5].table_list)->outer_join|=JOIN_TYPE_LEFT;
(yyval.table_list)=(yyvsp[-5].table_list);
}
#line 43781 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1812:
#line 11588 "/home/buildbot/git/sql/sql_yacc.yy"
{
MYSQL_YYABORT_UNLESS((yyvsp[-5].table_list) && (yyvsp[0].table_list));
Select->add_joined_table((yyvsp[-5].table_list));
Select->add_joined_table((yyvsp[0].table_list));
add_join_natural((yyvsp[-5].table_list),(yyvsp[0].table_list),NULL,Select);
(yyvsp[0].table_list)->outer_join|=JOIN_TYPE_LEFT;
(yyval.table_list)=(yyvsp[0].table_list);
}
#line 43796 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1813:
#line 11600 "/home/buildbot/git/sql/sql_yacc.yy"
{
MYSQL_YYABORT_UNLESS((yyvsp[-5].table_list) && (yyvsp[-1].table_list));
Select->add_joined_table((yyvsp[-5].table_list));
Select->add_joined_table((yyvsp[-1].table_list));
/* Change the current name resolution context to a local context. */
if (unlikely(push_new_name_resolution_context(thd, (yyvsp[-5].table_list), (yyvsp[-1].table_list))))
MYSQL_YYABORT;
Select->parsing_place= IN_ON;
}
#line 43812 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1814:
#line 11610 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
if (unlikely(!((yyval.table_list)= lex->current_select->convert_right_join())))
MYSQL_YYABORT;
add_join_on(thd, (yyval.table_list), (yyvsp[0].item));
(yyvsp[-7].table_list)->on_context= Lex->pop_context();
Select->parsing_place= NO_MATTER;
}
#line 43827 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1815:
#line 11619 "/home/buildbot/git/sql/sql_yacc.yy"
{
MYSQL_YYABORT_UNLESS((yyvsp[-4].table_list) && (yyvsp[0].table_list));
Select->add_joined_table((yyvsp[-4].table_list));
Select->add_joined_table((yyvsp[0].table_list));
}
#line 43839 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1816:
#line 11625 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
if (unlikely(!((yyval.table_list)= lex->current_select->convert_right_join())))
MYSQL_YYABORT;
add_join_natural((yyval.table_list),(yyvsp[-5].table_list),(yyvsp[-1].string_list),Select);
}
#line 43852 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1817:
#line 11632 "/home/buildbot/git/sql/sql_yacc.yy"
{
MYSQL_YYABORT_UNLESS((yyvsp[-5].table_list) && (yyvsp[0].table_list));
Select->add_joined_table((yyvsp[-5].table_list));
Select->add_joined_table((yyvsp[0].table_list));
add_join_natural((yyvsp[0].table_list),(yyvsp[-5].table_list),NULL,Select);
LEX *lex= Lex;
if (unlikely(!((yyval.table_list)= lex->current_select->convert_right_join())))
MYSQL_YYABORT;
}
#line 43868 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1818:
#line 11645 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.num) = 0; }
#line 43876 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1819:
#line 11646 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.num) = 0; }
#line 43884 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1820:
#line 11647 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.num) = 1; }
#line 43892 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1821:
#line 11651 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.num) = (yyvsp[0].num); }
#line 43900 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1822:
#line 11652 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.num) = 0; }
#line 43908 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1823:
#line 11660 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.string_list)= 0;}
#line 43916 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1825:
#line 11666 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.string_list)= (yyvsp[-2].string_list);
Select->parsing_place= Select->save_parsing_place;
Select->save_parsing_place= NO_MATTER;
}
#line 43928 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1826:
#line 11674 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.table_list)= (yyvsp[0].table_list); }
#line 43936 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1827:
#line 11675 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.table_list)= (yyvsp[0].table_list); }
#line 43944 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1828:
#line 11677 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyvsp[0].table_list)->nested_join->nest_type= 0;
(yyval.table_list)= (yyvsp[0].table_list);
}
#line 43955 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1829:
#line 11681 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.table_list)= (yyvsp[0].table_list); }
#line 43963 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1830:
#line 11685 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.table_list)= (yyvsp[0].table_list); }
#line 43971 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1831:
#line 11686 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.table_list)= (yyvsp[-1].table_list); }
#line 43979 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1832:
#line 11690 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.table_list)= (yyvsp[0].table_list); }
#line 43987 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1833:
#line 11691 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.table_list)= (yyvsp[-1].table_list); }
#line 43995 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1834:
#line 11695 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.table_list)= (yyvsp[-1].table_list); }
#line 44003 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1835:
#line 11697 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (!((yyval.table_list)= Select->end_nested_join(thd)))
MYSQL_YYABORT;
}
#line 44014 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1836:
#line 11705 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (Select->init_nested_join(thd))
MYSQL_YYABORT;
Select->add_joined_table((yyvsp[-2].table_list));
Select->add_joined_table((yyvsp[0].table_list));
(yyval.table_list)= (yyvsp[-2].table_list)->embedding;
}
#line 44028 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1837:
#line 11713 "/home/buildbot/git/sql/sql_yacc.yy"
{
Select->add_joined_table((yyvsp[0].table_list));
(yyval.table_list)= (yyvsp[-2].table_list);
}
#line 44039 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1838:
#line 11720 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.table_list)= (yyvsp[-1].table_list); }
#line 44047 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1839:
#line 11722 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
if (!((yyval.table_list)= lex->current_select->nest_last_join(thd)))
{
thd->parse_error();
MYSQL_YYABORT;
}
}
#line 44062 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1840:
#line 11736 "/home/buildbot/git/sql/sql_yacc.yy"
{
SELECT_LEX *sel= Select;
sel->table_join_options= 0;
if (!((yyval.table_list)= Select->add_table_to_list(thd, (yyvsp[-4].table), (yyvsp[-1].lex_str_ptr),
Select->get_table_join_options(),
YYPS->m_lock_type,
YYPS->m_mdl_type,
Select->pop_index_hints(),
(yyvsp[-3].string_list))))
MYSQL_YYABORT;
if ((yyvsp[-2].num))
(yyval.table_list)->vers_conditions= Lex->vers_conditions;
}
#line 44082 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1841:
#line 11754 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (!((yyval.table_list)= Lex->parsed_derived_table((yyvsp[-2].select_lex)->master_unit(), (yyvsp[-1].num), (yyvsp[0].lex_str_ptr))))
MYSQL_YYABORT;
}
#line 44093 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1842:
#line 11761 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 44101 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1843:
#line 11762 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 44109 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1844:
#line 11767 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.num)= thd->variables.old_mode ? INDEX_HINT_MASK_JOIN : INDEX_HINT_MASK_ALL;
}
#line 44119 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1845:
#line 11770 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.num)= INDEX_HINT_MASK_JOIN; }
#line 44127 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1846:
#line 11771 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.num)= INDEX_HINT_MASK_ORDER; }
#line 44135 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1847:
#line 11772 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.num)= INDEX_HINT_MASK_GROUP; }
#line 44143 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1848:
#line 11776 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.index_hint)= INDEX_HINT_FORCE; }
#line 44151 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1849:
#line 11777 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.index_hint)= INDEX_HINT_IGNORE; }
#line 44159 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1850:
#line 11782 "/home/buildbot/git/sql/sql_yacc.yy"
{
Select->set_index_hint_type((yyvsp[-2].index_hint), (yyvsp[0].num));
}
#line 44169 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1852:
#line 11787 "/home/buildbot/git/sql/sql_yacc.yy"
{
Select->set_index_hint_type(INDEX_HINT_USE, (yyvsp[0].num));
}
#line 44179 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1857:
#line 11800 "/home/buildbot/git/sql/sql_yacc.yy"
{ Select->alloc_index_hints(thd); }
#line 44187 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1859:
#line 11804 "/home/buildbot/git/sql/sql_yacc.yy"
{ Select->clear_index_hints(); }
#line 44195 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1861:
#line 11809 "/home/buildbot/git/sql/sql_yacc.yy"
{ Select->add_index_hint(thd, NULL, 0); }
#line 44203 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1862:
#line 11810 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 44211 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1863:
#line 11815 "/home/buildbot/git/sql/sql_yacc.yy"
{ Select->add_index_hint(thd, (yyvsp[0].ident_sys).str, (yyvsp[0].ident_sys).length); }
#line 44219 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1864:
#line 11817 "/home/buildbot/git/sql/sql_yacc.yy"
{ Select->add_index_hint(thd, "PRIMARY", 7); }
#line 44227 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1867:
#line 11827 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(!((yyval.string_list)= new (thd->mem_root) List
)))
MYSQL_YYABORT;
String *s= new (thd->mem_root) String((const char *) (yyvsp[0].ident_sys).str,
(yyvsp[0].ident_sys).length,
system_charset_info);
if (unlikely(unlikely(s == NULL)))
MYSQL_YYABORT;
(yyval.string_list)->push_back(s, thd->mem_root);
}
#line 44244 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1868:
#line 11838 "/home/buildbot/git/sql/sql_yacc.yy"
{
String *s= new (thd->mem_root) String((const char *) (yyvsp[0].ident_sys).str,
(yyvsp[0].ident_sys).length,
system_charset_info);
if (unlikely(unlikely(s == NULL)))
MYSQL_YYABORT;
if (unlikely((yyvsp[-2].string_list)->push_back(s, thd->mem_root)))
MYSQL_YYABORT;
(yyval.string_list)= (yyvsp[-2].string_list);
}
#line 44261 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1869:
#line 11851 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 44269 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1870:
#line 11852 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.interval)=INTERVAL_DAY_HOUR; }
#line 44277 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1871:
#line 11853 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.interval)=INTERVAL_DAY_MICROSECOND; }
#line 44285 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1872:
#line 11854 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.interval)=INTERVAL_DAY_MINUTE; }
#line 44293 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1873:
#line 11855 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.interval)=INTERVAL_DAY_SECOND; }
#line 44301 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1874:
#line 11856 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.interval)=INTERVAL_HOUR_MICROSECOND; }
#line 44309 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1875:
#line 11857 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.interval)=INTERVAL_HOUR_MINUTE; }
#line 44317 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1876:
#line 11858 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.interval)=INTERVAL_HOUR_SECOND; }
#line 44325 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1877:
#line 11859 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.interval)=INTERVAL_MINUTE_MICROSECOND; }
#line 44333 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1878:
#line 11860 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.interval)=INTERVAL_MINUTE_SECOND; }
#line 44341 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1879:
#line 11861 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.interval)=INTERVAL_SECOND_MICROSECOND; }
#line 44349 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1880:
#line 11862 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.interval)=INTERVAL_YEAR_MONTH; }
#line 44357 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1881:
#line 11866 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.interval_time_st)=INTERVAL_DAY; }
#line 44365 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1882:
#line 11867 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.interval_time_st)=INTERVAL_WEEK; }
#line 44373 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1883:
#line 11868 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.interval_time_st)=INTERVAL_HOUR; }
#line 44381 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1884:
#line 11869 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.interval_time_st)=INTERVAL_MINUTE; }
#line 44389 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1885:
#line 11870 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.interval_time_st)=INTERVAL_MONTH; }
#line 44397 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1886:
#line 11871 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.interval_time_st)=INTERVAL_QUARTER; }
#line 44405 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1887:
#line 11872 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.interval_time_st)=INTERVAL_SECOND; }
#line 44413 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1888:
#line 11873 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.interval_time_st)=INTERVAL_MICROSECOND; }
#line 44421 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1889:
#line 11874 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.interval_time_st)=INTERVAL_YEAR; }
#line 44429 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1890:
#line 11878 "/home/buildbot/git/sql/sql_yacc.yy"
{(yyval.date_time_type)=MYSQL_TIMESTAMP_DATE;}
#line 44437 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1891:
#line 11879 "/home/buildbot/git/sql/sql_yacc.yy"
{(yyval.date_time_type)=MYSQL_TIMESTAMP_TIME;}
#line 44445 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1892:
#line 11880 "/home/buildbot/git/sql/sql_yacc.yy"
{(yyval.date_time_type)=MYSQL_TIMESTAMP_DATETIME;}
#line 44453 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1893:
#line 11881 "/home/buildbot/git/sql/sql_yacc.yy"
{(yyval.date_time_type)=MYSQL_TIMESTAMP_DATETIME;}
#line 44461 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1897:
#line 11891 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.lex_str_ptr)=0; }
#line 44469 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1898:
#line 11892 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.lex_str_ptr)= (yyvsp[0].lex_str_ptr); }
#line 44477 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1899:
#line 11897 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.lex_str_ptr)= (LEX_CSTRING*) thd->memdup(&(yyvsp[0].ident_sys),sizeof(LEX_STRING));
if (unlikely((yyval.lex_str_ptr) == NULL))
MYSQL_YYABORT;
}
#line 44489 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1902:
#line 11910 "/home/buildbot/git/sql/sql_yacc.yy"
{ Select->where= 0; }
#line 44497 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1903:
#line 11912 "/home/buildbot/git/sql/sql_yacc.yy"
{
Select->parsing_place= IN_WHERE;
}
#line 44507 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1904:
#line 11916 "/home/buildbot/git/sql/sql_yacc.yy"
{
SELECT_LEX *select= Select;
select->where= normalize_cond(thd, (yyvsp[0].item));
select->parsing_place= NO_MATTER;
if ((yyvsp[0].item))
(yyvsp[0].item)->top_level_item();
}
#line 44521 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1906:
#line 11928 "/home/buildbot/git/sql/sql_yacc.yy"
{
Select->parsing_place= IN_HAVING;
}
#line 44531 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1907:
#line 11932 "/home/buildbot/git/sql/sql_yacc.yy"
{
SELECT_LEX *sel= Select;
sel->having= normalize_cond(thd, (yyvsp[0].item));
sel->parsing_place= NO_MATTER;
if ((yyvsp[0].item))
(yyvsp[0].item)->top_level_item();
}
#line 44545 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1910:
#line 11952 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(add_group_to_list(thd, (yyvsp[-1].item),(bool) (yyvsp[0].num))))
MYSQL_YYABORT;
}
#line 44556 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1911:
#line 11957 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(add_group_to_list(thd, (yyvsp[-1].item),(bool) (yyvsp[0].num))))
MYSQL_YYABORT;
}
#line 44567 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1912:
#line 11964 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 44575 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1913:
#line 11966 "/home/buildbot/git/sql/sql_yacc.yy"
{
/*
'WITH CUBE' is reserved in the MySQL syntax, but not implemented,
and cause LALR(2) conflicts.
This syntax is not standard.
MySQL syntax: GROUP BY col1, col2, col3 WITH CUBE
SQL-2003: GROUP BY ... CUBE(col1, col2, col3)
*/
LEX *lex=Lex;
if (unlikely(lex->current_select->get_linkage() == GLOBAL_OPTIONS_TYPE))
my_yyabort_error((ER_WRONG_USAGE, MYF(0), "WITH CUBE",
"global union parameters"));
lex->current_select->olap= CUBE_TYPE;
my_yyabort_error((ER_NOT_SUPPORTED_YET, MYF(0), "CUBE"));
}
#line 44598 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1914:
#line 11983 "/home/buildbot/git/sql/sql_yacc.yy"
{
/*
'WITH ROLLUP' is needed for backward compatibility,
and cause LALR(2) conflicts.
This syntax is not standard.
MySQL syntax: GROUP BY col1, col2, col3 WITH ROLLUP
SQL-2003: GROUP BY ... ROLLUP(col1, col2, col3)
*/
LEX *lex= Lex;
if (unlikely(lex->current_select->get_linkage() == GLOBAL_OPTIONS_TYPE))
my_yyabort_error((ER_WRONG_USAGE, MYF(0), "WITH ROLLUP",
"global union parameters"));
lex->current_select->olap= ROLLUP_TYPE;
}
#line 44619 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1915:
#line 12005 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 44627 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1916:
#line 12008 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 44635 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1919:
#line 12018 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
if (unlikely(Select->add_window_def(thd, (yyvsp[-2].lex_str_ptr), lex->win_ref,
Select->group_list,
Select->order_list,
lex->win_frame)))
MYSQL_YYABORT;
}
#line 44650 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1920:
#line 12030 "/home/buildbot/git/sql/sql_yacc.yy"
{ Select->prepare_add_window_spec(thd); }
#line 44658 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1921:
#line 12034 "/home/buildbot/git/sql/sql_yacc.yy"
{ }
#line 44666 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1922:
#line 12038 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 44674 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1923:
#line 12040 "/home/buildbot/git/sql/sql_yacc.yy"
{
thd->lex->win_ref= (LEX_CSTRING *) thd->memdup(&(yyvsp[0].ident_sys), sizeof(LEX_CSTRING));
if (unlikely(thd->lex->win_ref == NULL))
MYSQL_YYABORT;
}
#line 44686 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1924:
#line 12048 "/home/buildbot/git/sql/sql_yacc.yy"
{ }
#line 44694 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1926:
#line 12053 "/home/buildbot/git/sql/sql_yacc.yy"
{ }
#line 44702 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1927:
#line 12054 "/home/buildbot/git/sql/sql_yacc.yy"
{ Select->order_list= *((yyvsp[0].select_order)); }
#line 44710 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1928:
#line 12058 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 44718 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1929:
#line 12060 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
lex->win_frame=
new (thd->mem_root) Window_frame((yyvsp[-2].frame_units),
lex->frame_top_bound,
lex->frame_bottom_bound,
(yyvsp[0].frame_exclusion));
if (unlikely(lex->win_frame == NULL))
MYSQL_YYABORT;
}
#line 44735 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1930:
#line 12073 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.frame_units)= Window_frame::UNITS_ROWS; }
#line 44743 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1931:
#line 12074 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.frame_units)= Window_frame::UNITS_RANGE; }
#line 44751 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1932:
#line 12079 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
lex->frame_top_bound= (yyvsp[0].window_frame_bound);
lex->frame_bottom_bound=
new (thd->mem_root)
Window_frame_bound(Window_frame_bound::CURRENT, NULL);
if (unlikely(lex->frame_bottom_bound == NULL))
MYSQL_YYABORT;
}
#line 44767 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1933:
#line 12089 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
lex->frame_top_bound= (yyvsp[-2].window_frame_bound);
lex->frame_bottom_bound= (yyvsp[0].window_frame_bound);
}
#line 44779 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1934:
#line 12098 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.window_frame_bound)= new (thd->mem_root)
Window_frame_bound(Window_frame_bound::PRECEDING, NULL);
if (unlikely((yyval.window_frame_bound) == NULL))
MYSQL_YYABORT;
}
#line 44792 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1935:
#line 12105 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.window_frame_bound)= new (thd->mem_root)
Window_frame_bound(Window_frame_bound::CURRENT, NULL);
if (unlikely((yyval.window_frame_bound) == NULL))
MYSQL_YYABORT;
}
#line 44805 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1936:
#line 12112 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.window_frame_bound)= new (thd->mem_root)
Window_frame_bound(Window_frame_bound::PRECEDING, (yyvsp[-1].item));
if (unlikely((yyval.window_frame_bound) == NULL))
MYSQL_YYABORT;
}
#line 44818 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1937:
#line 12121 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.window_frame_bound)= (yyvsp[0].window_frame_bound); }
#line 44826 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1938:
#line 12123 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.window_frame_bound)= new (thd->mem_root)
Window_frame_bound(Window_frame_bound::FOLLOWING, NULL);
if (unlikely((yyval.window_frame_bound) == NULL))
MYSQL_YYABORT;
}
#line 44839 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1939:
#line 12130 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.window_frame_bound)= new (thd->mem_root)
Window_frame_bound(Window_frame_bound::FOLLOWING, (yyvsp[-1].item));
if (unlikely((yyval.window_frame_bound) == NULL))
MYSQL_YYABORT;
}
#line 44852 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1940:
#line 12139 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.frame_exclusion)= Window_frame::EXCL_NONE; }
#line 44860 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1941:
#line 12141 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.frame_exclusion)= Window_frame::EXCL_CURRENT_ROW; }
#line 44868 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1942:
#line 12143 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.frame_exclusion)= Window_frame::EXCL_GROUP; }
#line 44876 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1943:
#line 12145 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.frame_exclusion)= Window_frame::EXCL_TIES; }
#line 44884 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1944:
#line 12147 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.frame_exclusion)= Window_frame::EXCL_NONE; }
#line 44892 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1945:
#line 12149 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.frame_exclusion)= Window_frame::EXCL_NONE; }
#line 44900 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1949:
#line 12167 "/home/buildbot/git/sql/sql_yacc.yy"
{
bool ascending= ((yyvsp[0].num) == 1) ? true : false;
if (unlikely(add_order_to_list(thd, (yyvsp[-1].item), ascending)))
MYSQL_YYABORT;
}
#line 44912 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1950:
#line 12180 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.select_order)= NULL; }
#line 44920 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1951:
#line 12182 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.select_order)= (yyvsp[0].select_order); }
#line 44928 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1952:
#line 12187 "/home/buildbot/git/sql/sql_yacc.yy"
{
thd->where= "ORDER clause";
}
#line 44938 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1953:
#line 12191 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.select_order)= (yyvsp[0].select_order);
}
#line 44948 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1954:
#line 12198 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.select_order)= (yyvsp[-3].select_order);
if (add_to_list(thd, *(yyval.select_order), (yyvsp[-1].item),(bool) (yyvsp[0].num)))
MYSQL_YYABORT;
}
#line 44960 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1955:
#line 12204 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.select_order)= new (thd->mem_root) SQL_I_List();
if (add_to_list(thd, *(yyval.select_order), (yyvsp[-1].item), (bool) (yyvsp[0].num)))
MYSQL_YYABORT;
}
#line 44972 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1956:
#line 12212 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.num) = 1; }
#line 44980 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1957:
#line 12213 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.num) =1; }
#line 44988 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1958:
#line 12214 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.num) =0; }
#line 44996 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1959:
#line 12219 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.select_limit).empty(); }
#line 45004 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1960:
#line 12221 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.select_limit)= (yyvsp[0].select_limit); }
#line 45012 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1961:
#line 12226 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.select_limit)= (yyvsp[0].select_limit);
if (!(yyval.select_limit).select_limit->basic_const_item() ||
(yyval.select_limit).select_limit->val_int() > 0)
Lex->set_stmt_unsafe(LEX::BINLOG_STMT_UNSAFE_LIMIT);
}
#line 45025 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1962:
#line 12234 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.select_limit)= (yyvsp[-3].select_limit);
Lex->set_stmt_unsafe(LEX::BINLOG_STMT_UNSAFE_LIMIT);
}
#line 45036 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1963:
#line 12239 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.select_limit).select_limit= 0;
(yyval.select_limit).offset_limit= 0;
(yyval.select_limit).explicit_limit= 0;
Lex->set_stmt_unsafe(LEX::BINLOG_STMT_UNSAFE_LIMIT);
}
#line 45049 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1964:
#line 12249 "/home/buildbot/git/sql/sql_yacc.yy"
{
Select->explicit_limit= (yyvsp[0].select_limit).explicit_limit;
Select->select_limit= (yyvsp[0].select_limit).select_limit;
Select->offset_limit= (yyvsp[0].select_limit).offset_limit;
}
#line 45061 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1965:
#line 12258 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.select_limit).select_limit= (yyvsp[0].item);
(yyval.select_limit).offset_limit= 0;
(yyval.select_limit).explicit_limit= 1;
}
#line 45073 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1966:
#line 12264 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.select_limit).select_limit= (yyvsp[0].item);
(yyval.select_limit).offset_limit= (yyvsp[-2].item);
(yyval.select_limit).explicit_limit= 1;
}
#line 45085 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1967:
#line 12270 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.select_limit).select_limit= (yyvsp[-2].item);
(yyval.select_limit).offset_limit= (yyvsp[0].item);
(yyval.select_limit).explicit_limit= 1;
}
#line 45097 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1968:
#line 12279 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(!((yyval.item)= Lex->create_item_limit(thd, &(yyvsp[0].ident_cli)))))
MYSQL_YYABORT;
}
#line 45108 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1969:
#line 12284 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(!((yyval.item)= Lex->create_item_limit(thd, &(yyvsp[-2].ident_cli), &(yyvsp[0].ident_cli)))))
MYSQL_YYABORT;
}
#line 45119 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1970:
#line 12289 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyvsp[0].item_param)->limit_clause_param= TRUE;
}
#line 45129 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1971:
#line 12293 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_uint(thd, (yyvsp[0].lex_str).str, (yyvsp[0].lex_str).length);
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 45141 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1972:
#line 12299 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_uint(thd, (yyvsp[0].lex_str).str, (yyvsp[0].lex_str).length);
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 45153 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1973:
#line 12305 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_uint(thd, (yyvsp[0].lex_str).str, (yyvsp[0].lex_str).length);
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 45165 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1974:
#line 12314 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex=Lex;
lex->limit_rows_examined= (yyvsp[0].item);
}
#line 45176 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1975:
#line 12322 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex=Lex;
lex->current_select->select_limit= 0;
}
#line 45187 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1976:
#line 12327 "/home/buildbot/git/sql/sql_yacc.yy"
{
SELECT_LEX *sel= Select;
sel->select_limit= (yyvsp[0].item);
Lex->set_stmt_unsafe(LEX::BINLOG_STMT_UNSAFE_LIMIT);
sel->explicit_limit= 1;
}
#line 45200 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1977:
#line 12333 "/home/buildbot/git/sql/sql_yacc.yy"
{ thd->parse_error(); MYSQL_YYABORT; }
#line 45208 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1978:
#line 12334 "/home/buildbot/git/sql/sql_yacc.yy"
{ thd->parse_error(); MYSQL_YYABORT; }
#line 45216 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1979:
#line 12339 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.order_limit_lock)= (yyvsp[0].order_limit_lock);
(yyval.order_limit_lock)->lock.empty();
}
#line 45227 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1980:
#line 12344 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.order_limit_lock)= (yyvsp[-1].order_limit_lock);
(yyval.order_limit_lock)->lock= (yyvsp[0].select_lock);
}
#line 45238 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1981:
#line 12349 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.order_limit_lock)= new(thd->mem_root) Lex_order_limit_lock;
if (!(yyval.order_limit_lock))
YYABORT;
(yyval.order_limit_lock)->order_list= NULL;
(yyval.order_limit_lock)->limit.empty();
(yyval.order_limit_lock)->lock= (yyvsp[0].select_lock);
}
#line 45253 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1982:
#line 12361 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->pop_select();
(yyval.order_limit_lock)= NULL;
}
#line 45264 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1983:
#line 12365 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.order_limit_lock)= (yyvsp[0].order_limit_lock); }
#line 45272 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1986:
#line 12378 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.select_lock).empty();
}
#line 45282 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1987:
#line 12382 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.select_lock)= (yyvsp[0].select_lock);
}
#line 45292 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1988:
#line 12386 "/home/buildbot/git/sql/sql_yacc.yy"
{
push_warning_printf(thd, Sql_condition::WARN_LEVEL_WARN,
ER_WARN_DEPRECATED_SYNTAX,
ER_THD(thd, ER_WARN_DEPRECATED_SYNTAX),
" INTO ;",
"'SELECT INTO "
" FROM...'");
(yyval.select_lock)= (yyvsp[0].select_lock);
}
#line 45308 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1989:
#line 12399 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.order_limit_lock)= new(thd->mem_root) Lex_order_limit_lock;
if (!(yyval.order_limit_lock))
YYABORT;
(yyval.order_limit_lock)->order_list= (yyvsp[-1].select_order);
(yyval.order_limit_lock)->limit= (yyvsp[0].select_limit);
}
#line 45322 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1990:
#line 12407 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex_order_limit_lock *op= (yyval.order_limit_lock)= new(thd->mem_root) Lex_order_limit_lock;
if (!(yyval.order_limit_lock))
YYABORT;
op->order_list= NULL;
op->limit= (yyvsp[0].select_limit);
(yyval.order_limit_lock)->order_list= NULL;
(yyval.order_limit_lock)->limit= (yyvsp[0].select_limit);
}
#line 45338 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1993:
#line 12425 "/home/buildbot/git/sql/sql_yacc.yy"
{ int error; (yyval.num)= (int) my_strtoll10((yyvsp[0].lex_str).str, (char**) 0, &error); }
#line 45346 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1994:
#line 12426 "/home/buildbot/git/sql/sql_yacc.yy"
{ int error; (yyval.num)= -(int) my_strtoll10((yyvsp[0].lex_str).str, (char**) 0, &error); }
#line 45354 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1995:
#line 12430 "/home/buildbot/git/sql/sql_yacc.yy"
{ int error; (yyval.ulong_num)= (ulong) my_strtoll10((yyvsp[0].lex_str).str, (char**) 0, &error); }
#line 45362 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1996:
#line 12431 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.ulong_num)= strtoul((yyvsp[0].lex_str).str, (char**) 0, 16); }
#line 45370 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1997:
#line 12432 "/home/buildbot/git/sql/sql_yacc.yy"
{ int error; (yyval.ulong_num)= (ulong) my_strtoll10((yyvsp[0].lex_str).str, (char**) 0, &error); }
#line 45378 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1998:
#line 12433 "/home/buildbot/git/sql/sql_yacc.yy"
{ int error; (yyval.ulong_num)= (ulong) my_strtoll10((yyvsp[0].lex_str).str, (char**) 0, &error); }
#line 45386 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 1999:
#line 12434 "/home/buildbot/git/sql/sql_yacc.yy"
{ int error; (yyval.ulong_num)= (ulong) my_strtoll10((yyvsp[0].lex_str).str, (char**) 0, &error); }
#line 45394 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2000:
#line 12435 "/home/buildbot/git/sql/sql_yacc.yy"
{ int error; (yyval.ulong_num)= (ulong) my_strtoll10((yyvsp[0].lex_str).str, (char**) 0, &error); }
#line 45402 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2001:
#line 12439 "/home/buildbot/git/sql/sql_yacc.yy"
{ int error; (yyval.ulong_num)= (ulong) my_strtoll10((yyvsp[0].lex_str).str, (char**) 0, &error); }
#line 45410 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2002:
#line 12440 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.ulong_num)= (ulong) strtol((yyvsp[0].lex_str).str, (char**) 0, 16); }
#line 45418 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2003:
#line 12441 "/home/buildbot/git/sql/sql_yacc.yy"
{ int error; (yyval.ulong_num)= (ulong) my_strtoll10((yyvsp[0].lex_str).str, (char**) 0, &error); }
#line 45426 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2004:
#line 12442 "/home/buildbot/git/sql/sql_yacc.yy"
{ int error; (yyval.ulong_num)= (ulong) my_strtoll10((yyvsp[0].lex_str).str, (char**) 0, &error); }
#line 45434 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2005:
#line 12443 "/home/buildbot/git/sql/sql_yacc.yy"
{ MYSQL_YYABORT; }
#line 45442 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2006:
#line 12447 "/home/buildbot/git/sql/sql_yacc.yy"
{ int error; (yyval.longlong_number)= (longlong) my_strtoll10((yyvsp[0].lex_str).str, (char**) 0, &error); }
#line 45450 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2007:
#line 12448 "/home/buildbot/git/sql/sql_yacc.yy"
{ int error; (yyval.longlong_number)= (longlong) my_strtoll10((yyvsp[0].lex_str).str, (char**) 0, &error); }
#line 45458 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2008:
#line 12449 "/home/buildbot/git/sql/sql_yacc.yy"
{ int error; (yyval.longlong_number)= -(longlong) my_strtoll10((yyvsp[0].lex_str).str, (char**) 0, &error); }
#line 45466 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2009:
#line 12450 "/home/buildbot/git/sql/sql_yacc.yy"
{ int error; (yyval.longlong_number)= -(longlong) my_strtoll10((yyvsp[0].lex_str).str, (char**) 0, &error); }
#line 45474 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2010:
#line 12454 "/home/buildbot/git/sql/sql_yacc.yy"
{ int error; (yyval.ulonglong_number)= (ulonglong) my_strtoll10((yyvsp[0].lex_str).str, (char**) 0, &error); }
#line 45482 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2011:
#line 12455 "/home/buildbot/git/sql/sql_yacc.yy"
{ int error; (yyval.ulonglong_number)= (ulonglong) my_strtoll10((yyvsp[0].lex_str).str, (char**) 0, &error); }
#line 45490 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2012:
#line 12456 "/home/buildbot/git/sql/sql_yacc.yy"
{ int error; (yyval.ulonglong_number)= (ulonglong) my_strtoll10((yyvsp[0].lex_str).str, (char**) 0, &error); }
#line 45498 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2013:
#line 12457 "/home/buildbot/git/sql/sql_yacc.yy"
{ int error; (yyval.ulonglong_number)= (ulonglong) my_strtoll10((yyvsp[0].lex_str).str, (char**) 0, &error); }
#line 45506 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2014:
#line 12458 "/home/buildbot/git/sql/sql_yacc.yy"
{ int error; (yyval.ulonglong_number)= (ulonglong) my_strtoll10((yyvsp[0].lex_str).str, (char**) 0, &error); }
#line 45514 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2015:
#line 12462 "/home/buildbot/git/sql/sql_yacc.yy"
{ int error; (yyval.ulonglong_number)= (ulonglong) my_strtoll10((yyvsp[0].lex_str).str, (char**) 0, &error); }
#line 45522 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2016:
#line 12463 "/home/buildbot/git/sql/sql_yacc.yy"
{ int error; (yyval.ulonglong_number)= (ulonglong) my_strtoll10((yyvsp[0].lex_str).str, (char**) 0, &error); }
#line 45530 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2017:
#line 12464 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.ulonglong_number)= strtoull((yyvsp[0].lex_str).str, (char**) 0, 16); }
#line 45538 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2018:
#line 12465 "/home/buildbot/git/sql/sql_yacc.yy"
{ int error; (yyval.ulonglong_number)= (ulonglong) my_strtoll10((yyvsp[0].lex_str).str, (char**) 0, &error); }
#line 45546 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2019:
#line 12466 "/home/buildbot/git/sql/sql_yacc.yy"
{ MYSQL_YYABORT; }
#line 45554 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2020:
#line 12471 "/home/buildbot/git/sql/sql_yacc.yy"
{ thd->parse_error(ER_ONLY_INTEGERS_ALLOWED); }
#line 45562 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2023:
#line 12480 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.choice)= (yyvsp[0].ulong_num) != 0 ? HA_CHOICE_YES : HA_CHOICE_NO; }
#line 45570 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2024:
#line 12481 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.choice)= HA_CHOICE_UNDEF; }
#line 45578 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2025:
#line 12485 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.ulong_num)= (yyvsp[0].ulong_num) != 0; }
#line 45586 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2026:
#line 12486 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.ulong_num)= 1; }
#line 45594 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2027:
#line 12487 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.ulong_num)= 0; }
#line 45602 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2028:
#line 12492 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex=Lex;
lex->proc_list.elements=0;
lex->proc_list.first=0;
lex->proc_list.next= &lex->proc_list.first;
Item_field *item= new (thd->mem_root)
Item_field(thd, &lex->current_select->context,
(yyvsp[0].ident_sys));
if (unlikely(item == NULL))
MYSQL_YYABORT;
if (unlikely(add_proc_to_list(thd, item)))
MYSQL_YYABORT;
Lex->uncacheable(UNCACHEABLE_SIDEEFFECT);
/*
PROCEDURE CLAUSE cannot handle subquery as one of its parameter,
so disallow any subqueries further.
Alow subqueries back once the parameters are reduced.
*/
Lex->clause_that_disallows_subselect= "PROCEDURE";
Select->options|= OPTION_PROCEDURE_CLAUSE;
}
#line 45632 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2029:
#line 12516 "/home/buildbot/git/sql/sql_yacc.yy"
{
/* Subqueries are allowed from now.*/
Lex->clause_that_disallows_subselect= NULL;
}
#line 45643 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2030:
#line 12523 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 45651 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2031:
#line 12524 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 45659 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2034:
#line 12534 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(add_proc_to_list(thd, (yyvsp[-1].item))))
MYSQL_YYABORT;
if (!(yyvsp[-1].item)->name.str || (yyvsp[-1].item)->name.str == item_empty_name)
(yyvsp[-1].item)->set_name(thd, (yyvsp[-2].simple_string), (uint) ((yyvsp[0].simple_string) - (yyvsp[-2].simple_string)), thd->charset());
}
#line 45672 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2035:
#line 12543 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex=Lex;
if (!lex->describe &&
unlikely((!(lex->result= new (thd->mem_root)
select_dumpvar(thd)))))
MYSQL_YYABORT;
}
#line 45686 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2036:
#line 12551 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 45694 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2038:
#line 12556 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 45702 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2039:
#line 12560 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (Lex->result)
{
if (unlikely((yyvsp[0].myvar) == NULL))
MYSQL_YYABORT;
((select_dumpvar *)Lex->result)->var_list.push_back((yyvsp[0].myvar), thd->mem_root);
}
else
{
/*
The parser won't create select_result instance only
if it's an EXPLAIN.
*/
DBUG_ASSERT(Lex->describe);
}
}
#line 45725 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2040:
#line 12580 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.myvar) = Lex->result ? new (thd->mem_root) my_var_user(&(yyvsp[0].lex_str)) : NULL;
}
#line 45735 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2041:
#line 12584 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(!((yyval.myvar)= Lex->create_outvar(thd, &(yyvsp[0].lex_str))) && Lex->result))
MYSQL_YYABORT;
}
#line 45746 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2042:
#line 12589 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(!((yyval.myvar)= Lex->create_outvar(thd, &(yyvsp[-2].ident_sys), &(yyvsp[0].ident_sys))) && Lex->result))
MYSQL_YYABORT;
}
#line 45757 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2043:
#line 12597 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 45765 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2044:
#line 12602 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
lex->uncacheable(UNCACHEABLE_SIDEEFFECT);
if (unlikely(!(lex->exchange=
new (thd->mem_root) sql_exchange((yyvsp[0].lex_str).str, 0))) ||
unlikely(!(lex->result=
new (thd->mem_root)
select_export(thd, lex->exchange))))
MYSQL_YYABORT;
}
#line 45782 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2045:
#line 12613 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->exchange->cs= (yyvsp[0].charset); }
#line 45790 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2047:
#line 12616 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex=Lex;
if (!lex->describe)
{
lex->uncacheable(UNCACHEABLE_SIDEEFFECT);
if (unlikely(!(lex->exchange=
new (thd->mem_root) sql_exchange((yyvsp[0].lex_str).str,1))))
MYSQL_YYABORT;
if (unlikely(!(lex->result=
new (thd->mem_root)
select_dump(thd, lex->exchange))))
MYSQL_YYABORT;
}
}
#line 45811 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2048:
#line 12631 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->uncacheable(UNCACHEABLE_SIDEEFFECT);
}
#line 45821 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2049:
#line 12642 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex=Lex;
lex->sql_command = SQLCOM_DO;
if (lex->main_select_push(true))
MYSQL_YYABORT;
mysql_init_select(lex);
}
#line 45835 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2050:
#line 12650 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->insert_list= (yyvsp[0].item_list);
Lex->pop_select(); //main select
if (Lex->check_cte_dependencies_and_resolve_references())
MYSQL_YYABORT;
}
#line 45848 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2051:
#line 12664 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex=Lex;
lex->set_command(SQLCOM_DROP_TABLE, (yyvsp[-2].num), (yyvsp[0].object_ddl_options));
YYPS->m_lock_type= TL_UNLOCK;
YYPS->m_mdl_type= MDL_EXCLUSIVE;
}
#line 45861 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2052:
#line 12671 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 45869 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2053:
#line 12673 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (Lex->main_select_push())
MYSQL_YYABORT;
}
#line 45880 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2054:
#line 12678 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex=Lex;
Alter_drop *ad= (new (thd->mem_root)
Alter_drop(Alter_drop::KEY, (yyvsp[-3].ident_sys).str, (yyvsp[-4].num)));
if (unlikely(ad == NULL))
MYSQL_YYABORT;
lex->sql_command= SQLCOM_DROP_INDEX;
lex->alter_info.reset();
lex->alter_info.flags= ALTER_DROP_INDEX;
lex->alter_info.drop_list.push_back(ad, thd->mem_root);
if (unlikely(!lex->current_select->
add_table_to_list(thd, (yyvsp[-1].table), NULL, TL_OPTION_UPDATING,
TL_READ_NO_INSERT,
MDL_SHARED_UPGRADABLE)))
MYSQL_YYABORT;
Lex->pop_select(); //main select
}
#line 45904 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2055:
#line 12696 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex=Lex;
lex->set_command(SQLCOM_DROP_DB, (yyvsp[-1].object_ddl_options));
lex->name= (yyvsp[0].ident_sys);
}
#line 45916 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2056:
#line 12702 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->set_command(SQLCOM_DROP_USER, (yyvsp[-2].object_ddl_options));
}
#line 45926 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2057:
#line 12706 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->set_command(SQLCOM_DROP_ROLE, (yyvsp[-2].object_ddl_options));
}
#line 45936 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2058:
#line 12710 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
lex->set_command(SQLCOM_DROP_VIEW, (yyvsp[0].object_ddl_options));
YYPS->m_lock_type= TL_UNLOCK;
YYPS->m_mdl_type= MDL_EXCLUSIVE;
}
#line 45949 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2059:
#line 12717 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 45957 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2060:
#line 12719 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->spname= (yyvsp[0].spname);
Lex->set_command(SQLCOM_DROP_EVENT, (yyvsp[-1].object_ddl_options));
}
#line 45968 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2061:
#line 12724 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
lex->set_command(SQLCOM_DROP_TRIGGER, (yyvsp[-1].object_ddl_options));
lex->spname= (yyvsp[0].spname);
}
#line 45980 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2062:
#line 12730 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
lex->alter_tablespace_info->ts_cmd_type= DROP_TABLESPACE;
}
#line 45991 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2063:
#line 12735 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
lex->alter_tablespace_info->ts_cmd_type= DROP_LOGFILE_GROUP;
}
#line 46002 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2064:
#line 12740 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->set_command(SQLCOM_DROP_SERVER, (yyvsp[-1].object_ddl_options));
Lex->server_options.reset((yyvsp[0].lex_str));
}
#line 46013 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2065:
#line 12746 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
lex->set_command(SQLCOM_DROP_SEQUENCE, (yyvsp[-2].num), (yyvsp[0].object_ddl_options));
lex->table_type= TABLE_TYPE_SEQUENCE;
YYPS->m_lock_type= TL_UNLOCK;
YYPS->m_mdl_type= MDL_EXCLUSIVE;
}
#line 46027 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2066:
#line 12754 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 46035 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2070:
#line 12765 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (!thd->lex->current_select_or_default()->
add_table_to_list(thd, (yyvsp[0].table), NULL,
TL_OPTION_UPDATING,
YYPS->m_lock_type,
YYPS->m_mdl_type))
MYSQL_YYABORT;
}
#line 46050 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2071:
#line 12777 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(!Select->add_table_to_list(thd, (yyvsp[-1].table), NULL,
TL_OPTION_UPDATING,
YYPS->m_lock_type,
YYPS->m_mdl_type,
NULL,
(yyvsp[0].string_list))))
MYSQL_YYABORT;
}
#line 46066 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2074:
#line 12795 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(!Select->
add_table_to_list(thd, (yyvsp[0].table), NULL,
(TL_OPTION_UPDATING |
TL_OPTION_ALIAS),
YYPS->m_lock_type,
YYPS->m_mdl_type)))
MYSQL_YYABORT;
}
#line 46082 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2075:
#line 12808 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->check_exists= FALSE;
(yyval.num)= 0;
}
#line 46093 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2076:
#line 12813 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->check_exists= TRUE;
(yyval.num)= 1;
}
#line 46104 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2077:
#line 12821 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.object_ddl_options).set(DDL_options_st::OPT_NONE);
}
#line 46114 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2078:
#line 12825 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.object_ddl_options).set(DDL_options_st::OPT_IF_EXISTS);
}
#line 46124 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2079:
#line 12831 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.num)= 0; }
#line 46132 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2080:
#line 12832 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.num)= HA_LEX_CREATE_TMP_TABLE; }
#line 46140 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2081:
#line 12840 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->sql_command= SQLCOM_INSERT;
Lex->duplicates= DUP_ERROR;
}
#line 46151 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2082:
#line 12845 "/home/buildbot/git/sql/sql_yacc.yy"
{
Select->set_lock_for_tables((yyvsp[-3].lock_type), true);
}
#line 46161 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2083:
#line 12850 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->mark_first_table_as_inserting();
}
#line 46171 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2084:
#line 12857 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->sql_command = SQLCOM_REPLACE;
Lex->duplicates= DUP_REPLACE;
}
#line 46182 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2085:
#line 12862 "/home/buildbot/git/sql/sql_yacc.yy"
{
Select->set_lock_for_tables((yyvsp[-2].lock_type), true);
}
#line 46192 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2086:
#line 12867 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->mark_first_table_as_inserting();
}
#line 46202 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2087:
#line 12872 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (Lex->main_select_push())
MYSQL_YYABORT;
mysql_init_select(Lex);
Lex->current_select->parsing_place= BEFORE_OPT_LIST;
}
#line 46215 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2088:
#line 12880 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->pop_select(); //main select
if (Lex->check_main_unit_semantics())
MYSQL_YYABORT;
}
#line 46227 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2089:
#line 12889 "/home/buildbot/git/sql/sql_yacc.yy"
{
/*
If it is SP we do not allow insert optimisation when result of
insert visible only after the table unlocking but everyone can
read table.
*/
(yyval.lock_type)= (Lex->sphead ? TL_WRITE_DEFAULT : TL_WRITE_CONCURRENT_INSERT);
}
#line 46242 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2091:
#line 12898 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.lock_type)= TL_WRITE; }
#line 46250 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2092:
#line 12902 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.lock_type)= TL_WRITE_DEFAULT; }
#line 46258 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2094:
#line 12907 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.lock_type)= TL_WRITE_LOW_PRIORITY; }
#line 46266 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2095:
#line 12909 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->keyword_delayed_begin_offset= (uint)((yyvsp[0].kwd).pos() - thd->query());
Lex->keyword_delayed_end_offset= (uint)((yyvsp[0].kwd).end() - thd->query());
(yyval.lock_type)= TL_WRITE_DELAYED;
}
#line 46278 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2098:
#line 12919 "/home/buildbot/git/sql/sql_yacc.yy"
{
Select->save_parsing_place= Select->parsing_place;
}
#line 46288 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2099:
#line 12923 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex=Lex;
//lex->field_list.empty();
lex->many_values.empty();
lex->insert_list=0;
}
#line 46301 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2100:
#line 12932 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 46309 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2101:
#line 12933 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 46317 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2102:
#line 12935 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex=Lex;
if (unlikely(!(lex->insert_list= new (thd->mem_root) List_item)) ||
unlikely(lex->many_values.push_back(lex->insert_list,
thd->mem_root)))
MYSQL_YYABORT;
lex->current_select->parsing_place= NO_MATTER;
}
#line 46332 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2104:
#line 12948 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->current_select->parsing_place= AFTER_LIST;
}
#line 46342 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2107:
#line 12960 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->field_list.push_back((yyvsp[0].item), thd->mem_root); }
#line 46350 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2108:
#line 12961 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->field_list.push_back((yyvsp[0].item), thd->mem_root); }
#line 46358 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2109:
#line 12967 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 46366 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2114:
#line 12982 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex=Lex;
if (unlikely(lex->field_list.push_back((yyvsp[-2].item), thd->mem_root)) ||
unlikely(lex->insert_list->push_back((yyvsp[0].item), thd->mem_root)))
MYSQL_YYABORT;
}
#line 46379 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2115:
#line 12991 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 46387 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2116:
#line 12992 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 46395 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2117:
#line 12996 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 46403 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2118:
#line 12997 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 46411 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2119:
#line 13001 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 46419 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2120:
#line 13002 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 46427 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2121:
#line 13006 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 46435 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2122:
#line 13007 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 46443 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2123:
#line 13012 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(!(Lex->insert_list= new (thd->mem_root) List_item)))
MYSQL_YYABORT;
}
#line 46454 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2124:
#line 13017 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex=Lex;
if (unlikely(lex->many_values.push_back(lex->insert_list,
thd->mem_root)))
MYSQL_YYABORT;
}
#line 46467 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2125:
#line 13027 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(!(Lex->insert_list= new (thd->mem_root) List_item)))
MYSQL_YYABORT;
}
#line 46478 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2126:
#line 13032 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex=Lex;
if (unlikely(lex->many_values.push_back(lex->insert_list,
thd->mem_root)))
MYSQL_YYABORT;
}
#line 46491 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2127:
#line 13041 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 46499 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2129:
#line 13046 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 46507 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2131:
#line 13052 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->insert_list->push_back((yyvsp[0].item), thd->mem_root)))
MYSQL_YYABORT;
}
#line 46518 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2132:
#line 13057 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->insert_list->push_back((yyvsp[0].item), thd->mem_root)))
MYSQL_YYABORT;
}
#line 46529 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2133:
#line 13065 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->insert_list->push_back((yyvsp[-1].item), thd->mem_root)))
MYSQL_YYABORT;
// give some name in case of using in table value constuctor (TVC)
if (!(yyvsp[-1].item)->name.str || (yyvsp[-1].item)->name.str == item_empty_name)
(yyvsp[-1].item)->set_name(thd, (yyvsp[-2].simple_string), (uint) ((yyvsp[0].simple_string) - (yyvsp[-2].simple_string)), thd->charset());
}
#line 46543 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2134:
#line 13073 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->insert_list->push_back((yyvsp[-1].item), thd->mem_root)))
MYSQL_YYABORT;
// give some name in case of using in table value constuctor (TVC)
if (!(yyvsp[-1].item)->name.str || (yyvsp[-1].item)->name.str == item_empty_name)
(yyvsp[-1].item)->set_name(thd, (yyvsp[-2].simple_string), (uint) ((yyvsp[0].simple_string) - (yyvsp[-2].simple_string)), thd->charset());
}
#line 46557 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2135:
#line 13083 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.item)= (yyvsp[0].item);}
#line 46565 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2136:
#line 13085 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_ignore_specification(thd);
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 46577 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2137:
#line 13093 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.item)= (yyvsp[0].item);}
#line 46585 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2138:
#line 13095 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_default_specification(thd);
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 46597 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2140:
#line 13104 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->duplicates= DUP_UPDATE; }
#line 46605 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2141:
#line 13106 "/home/buildbot/git/sql/sql_yacc.yy"
{
Select->parsing_place= IN_UPDATE_ON_DUP_KEY;
}
#line 46615 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2142:
#line 13110 "/home/buildbot/git/sql/sql_yacc.yy"
{
Select->parsing_place= NO_MATTER;
}
#line 46625 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2143:
#line 13118 "/home/buildbot/git/sql/sql_yacc.yy"
{
SELECT_LEX *sel= Select;
sel->table_join_options= 0;
if (!((yyval.table_list)= Select->add_table_to_list(thd, (yyvsp[-4].table), (yyvsp[-1].lex_str_ptr),
Select->get_table_join_options(),
YYPS->m_lock_type,
YYPS->m_mdl_type,
Select->pop_index_hints(),
(yyvsp[-3].string_list))))
MYSQL_YYABORT;
(yyval.table_list)->period_conditions= Lex->period_conditions;
}
#line 46644 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2144:
#line 13130 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.table_list)= (yyvsp[0].table_list); }
#line 46652 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2145:
#line 13137 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
if (Lex->main_select_push())
MYSQL_YYABORT;
mysql_init_select(lex);
lex->sql_command= SQLCOM_UPDATE;
lex->duplicates= DUP_ERROR;
}
#line 46667 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2146:
#line 13147 "/home/buildbot/git/sql/sql_yacc.yy"
{
SELECT_LEX *slex= Lex->first_select_lex();
if (slex->table_list.elements > 1)
Lex->sql_command= SQLCOM_UPDATE_MULTI;
else if (slex->get_table_list()->derived)
{
/* it is single table update and it is update of derived table */
my_error(ER_NON_UPDATABLE_TABLE, MYF(0),
slex->get_table_list()->alias.str, "UPDATE");
MYSQL_YYABORT;
}
/*
In case of multi-update setting write lock for all tables may
be too pessimistic. We will decrease lock level if possible in
mysql_multi_update().
*/
slex->set_lock_for_tables((yyvsp[-4].lock_type), slex->table_list.elements == 1);
}
#line 46692 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2147:
#line 13166 "/home/buildbot/git/sql/sql_yacc.yy"
{
if ((yyvsp[-1].select_order))
Select->order_list= *((yyvsp[-1].select_order));
}
#line 46703 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2148:
#line 13169 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 46711 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2151:
#line 13179 "/home/buildbot/git/sql/sql_yacc.yy"
{
Item *def= new (thd->mem_root) Item_default_value(thd,
Lex->current_context(), (yyvsp[-2].item), 1);
if (!def || add_item_to_list(thd, (yyvsp[-2].item)) || add_value_to_list(thd, def))
MYSQL_YYABORT;
}
#line 46724 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2152:
#line 13186 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (add_item_to_list(thd, (yyvsp[-2].item)) || add_value_to_list(thd, (yyvsp[0].item)))
MYSQL_YYABORT;
}
#line 46735 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2155:
#line 13199 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
if (unlikely(lex->update_list.push_back((yyvsp[-2].item), thd->mem_root)) ||
unlikely(lex->value_list.push_back((yyvsp[0].item), thd->mem_root)))
MYSQL_YYABORT;
}
#line 46748 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2156:
#line 13208 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.lock_type)= TL_WRITE_DEFAULT; }
#line 46756 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2157:
#line 13209 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.lock_type)= TL_WRITE_LOW_PRIORITY; }
#line 46764 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2158:
#line 13216 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
lex->sql_command= SQLCOM_DELETE;
YYPS->m_lock_type= TL_WRITE_DEFAULT;
YYPS->m_mdl_type= MDL_SHARED_WRITE;
if (Lex->main_select_push())
MYSQL_YYABORT;
mysql_init_select(lex);
lex->ignore= 0;
lex->first_select_lex()->order_list.empty();
}
#line 46782 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2159:
#line 13228 "/home/buildbot/git/sql/sql_yacc.yy"
{ }
#line 46790 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2160:
#line 13233 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->vers_conditions.init(SYSTEM_TIME_HISTORY);
}
#line 46800 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2161:
#line 13237 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->vers_conditions.init(SYSTEM_TIME_BEFORE, (yyvsp[0].vers_history_point));
}
#line 46810 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2162:
#line 13243 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 46818 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2163:
#line 13245 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->last_table()->vers_conditions= Lex->vers_conditions;
Lex->pop_select(); //main select
}
#line 46829 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2164:
#line 13253 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(!Select->
add_table_to_list(thd, (yyvsp[-1].table), NULL, TL_OPTION_UPDATING,
YYPS->m_lock_type,
YYPS->m_mdl_type,
NULL,
(yyvsp[0].string_list))))
MYSQL_YYABORT;
YYPS->m_lock_type= TL_READ_DEFAULT;
YYPS->m_mdl_type= MDL_SHARED_READ;
}
#line 46847 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2165:
#line 13268 "/home/buildbot/git/sql/sql_yacc.yy"
{
if ((yyvsp[0].num))
Lex->last_table()->period_conditions= Lex->period_conditions;
}
#line 46858 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2166:
#line 13280 "/home/buildbot/git/sql/sql_yacc.yy"
{
if ((yyvsp[-2].select_order))
Select->order_list= *((yyvsp[-2].select_order));
Lex->pop_select(); //main select
}
#line 46870 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2167:
#line 13286 "/home/buildbot/git/sql/sql_yacc.yy"
{
mysql_init_multi_delete(Lex);
YYPS->m_lock_type= TL_READ_DEFAULT;
YYPS->m_mdl_type= MDL_SHARED_READ;
}
#line 46882 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2168:
#line 13292 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(multi_delete_set_locks_and_link_aux_tables(Lex)))
MYSQL_YYABORT;
}
#line 46893 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2169:
#line 13295 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 46901 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2170:
#line 13297 "/home/buildbot/git/sql/sql_yacc.yy"
{
mysql_init_multi_delete(Lex);
YYPS->m_lock_type= TL_READ_DEFAULT;
YYPS->m_mdl_type= MDL_SHARED_READ;
}
#line 46913 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2171:
#line 13303 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(multi_delete_set_locks_and_link_aux_tables(Lex)))
MYSQL_YYABORT;
}
#line 46924 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2172:
#line 13306 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 46932 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2173:
#line 13311 "/home/buildbot/git/sql/sql_yacc.yy"
{
DBUG_ASSERT(!Lex->has_returning());
}
#line 46942 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2174:
#line 13315 "/home/buildbot/git/sql/sql_yacc.yy"
{
DBUG_ASSERT(!Lex->has_returning());
if (((yyval.num)= (Select != Lex->returning())))
{
SELECT_LEX *sl= Lex->returning();
sl->set_master_unit(0);
Select->add_slave(Lex->create_unit(sl));
sl->include_global((st_select_lex_node**)&Lex->all_selects_list);
Lex->push_select(sl);
}
}
#line 46960 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2175:
#line 13327 "/home/buildbot/git/sql/sql_yacc.yy"
{
if ((yyvsp[-1].num))
Lex->pop_select();
}
#line 46971 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2178:
#line 13340 "/home/buildbot/git/sql/sql_yacc.yy"
{
Table_ident *ti= new (thd->mem_root) Table_ident(&(yyvsp[-1].ident_sys));
if (unlikely(ti == NULL))
MYSQL_YYABORT;
if (unlikely(!Select->
add_table_to_list(thd,
ti,
NULL,
(TL_OPTION_UPDATING |
TL_OPTION_ALIAS),
YYPS->m_lock_type,
YYPS->m_mdl_type)))
MYSQL_YYABORT;
}
#line 46992 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2179:
#line 13355 "/home/buildbot/git/sql/sql_yacc.yy"
{
Table_ident *ti= new (thd->mem_root) Table_ident(thd, &(yyvsp[-3].ident_sys), &(yyvsp[-1].ident_sys), 0);
if (unlikely(ti == NULL))
MYSQL_YYABORT;
if (unlikely(!Select->
add_table_to_list(thd,
ti,
NULL,
(TL_OPTION_UPDATING |
TL_OPTION_ALIAS),
YYPS->m_lock_type,
YYPS->m_mdl_type)))
MYSQL_YYABORT;
}
#line 47013 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2180:
#line 13372 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 47021 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2181:
#line 13373 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 47029 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2182:
#line 13377 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 47037 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2183:
#line 13378 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 47045 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2184:
#line 13382 "/home/buildbot/git/sql/sql_yacc.yy"
{ Select->options|= OPTION_QUICK; }
#line 47053 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2185:
#line 13383 "/home/buildbot/git/sql/sql_yacc.yy"
{ YYPS->m_lock_type= TL_WRITE_LOW_PRIORITY; }
#line 47061 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2186:
#line 13384 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->ignore= 1; }
#line 47069 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2187:
#line 13389 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX* lex= Lex;
lex->sql_command= SQLCOM_TRUNCATE;
lex->alter_info.reset();
lex->first_select_lex()->options= 0;
lex->sql_cache= LEX::SQL_CACHE_UNSPECIFIED;
lex->first_select_lex()->order_list.empty();
YYPS->m_lock_type= TL_WRITE;
YYPS->m_mdl_type= MDL_EXCLUSIVE;
}
#line 47086 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2188:
#line 13400 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX* lex= thd->lex;
DBUG_ASSERT(!lex->m_sql_cmd);
lex->m_sql_cmd= new (thd->mem_root) Sql_cmd_truncate_table();
if (unlikely(lex->m_sql_cmd == NULL))
MYSQL_YYABORT;
}
#line 47100 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2189:
#line 13407 "/home/buildbot/git/sql/sql_yacc.yy"
{ }
#line 47108 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2196:
#line 13425 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->profile_options|= PROFILE_CPU;
}
#line 47118 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2197:
#line 13429 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->profile_options|= PROFILE_MEMORY;
}
#line 47128 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2198:
#line 13433 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->profile_options|= PROFILE_BLOCK_IO;
}
#line 47138 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2199:
#line 13437 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->profile_options|= PROFILE_CONTEXT;
}
#line 47148 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2200:
#line 13441 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->profile_options|= PROFILE_PAGE_FAULTS;
}
#line 47158 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2201:
#line 13445 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->profile_options|= PROFILE_IPC;
}
#line 47168 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2202:
#line 13449 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->profile_options|= PROFILE_SWAPS;
}
#line 47178 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2203:
#line 13453 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->profile_options|= PROFILE_SOURCE;
}
#line 47188 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2204:
#line 13457 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->profile_options|= PROFILE_ALL;
}
#line 47198 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2205:
#line 13464 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->profile_query_id= 0;
}
#line 47208 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2206:
#line 13468 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->profile_query_id= atoi((yyvsp[0].lex_str).str);
}
#line 47218 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2207:
#line 13477 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex=Lex;
lex->wild=0;
lex->ident= null_clex_str;
if (Lex->main_select_push())
MYSQL_YYABORT;
mysql_init_select(lex);
lex->current_select->parsing_place= SELECT_LIST;
lex->create_info.init();
}
#line 47235 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2208:
#line 13488 "/home/buildbot/git/sql/sql_yacc.yy"
{
Select->parsing_place= NO_MATTER;
Lex->pop_select(); //main select
}
#line 47246 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2209:
#line 13496 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
lex->sql_command= SQLCOM_SHOW_DATABASES;
if (unlikely(prepare_schema_table(thd, lex, 0, SCH_SCHEMATA)))
MYSQL_YYABORT;
}
#line 47259 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2210:
#line 13503 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
lex->sql_command= SQLCOM_SHOW_TABLES;
lex->first_select_lex()->db= (yyvsp[-1].lex_str);
if (prepare_schema_table(thd, lex, 0, SCH_TABLE_NAMES))
MYSQL_YYABORT;
}
#line 47273 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2211:
#line 13511 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
lex->sql_command= SQLCOM_SHOW_TRIGGERS;
lex->first_select_lex()->db= (yyvsp[-1].lex_str);
if (prepare_schema_table(thd, lex, 0, SCH_TRIGGERS))
MYSQL_YYABORT;
}
#line 47287 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2212:
#line 13519 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
lex->sql_command= SQLCOM_SHOW_EVENTS;
lex->first_select_lex()->db= (yyvsp[-1].lex_str);
if (prepare_schema_table(thd, lex, 0, SCH_EVENTS))
MYSQL_YYABORT;
}
#line 47301 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2213:
#line 13527 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
lex->sql_command= SQLCOM_SHOW_TABLE_STATUS;
lex->first_select_lex()->db= (yyvsp[-1].lex_str);
if (prepare_schema_table(thd, lex, 0, SCH_TABLES))
MYSQL_YYABORT;
}
#line 47315 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2214:
#line 13535 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
lex->sql_command= SQLCOM_SHOW_OPEN_TABLES;
lex->first_select_lex()->db= (yyvsp[-1].lex_str);
if (prepare_schema_table(thd, lex, 0, SCH_OPEN_TABLES))
MYSQL_YYABORT;
}
#line 47329 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2215:
#line 13543 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
lex->sql_command= SQLCOM_SHOW_PLUGINS;
if (unlikely(prepare_schema_table(thd, lex, 0, SCH_PLUGINS)))
MYSQL_YYABORT;
}
#line 47342 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2216:
#line 13550 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->ident= (yyvsp[0].lex_str);
Lex->sql_command= SQLCOM_SHOW_PLUGINS;
if (unlikely(prepare_schema_table(thd, Lex, 0, SCH_ALL_PLUGINS)))
MYSQL_YYABORT;
}
#line 47355 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2217:
#line 13557 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->sql_command= SQLCOM_SHOW_PLUGINS;
if (unlikely(prepare_schema_table(thd, Lex, 0, SCH_ALL_PLUGINS)))
MYSQL_YYABORT;
}
#line 47367 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2218:
#line 13563 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->create_info.db_type= (yyvsp[-1].db_type); }
#line 47375 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2219:
#line 13565 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->create_info.db_type= NULL; }
#line 47383 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2220:
#line 13567 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
lex->sql_command= SQLCOM_SHOW_FIELDS;
if ((yyvsp[-1].lex_str).str)
(yyvsp[-2].table)->change_db(&(yyvsp[-1].lex_str));
if (unlikely(prepare_schema_table(thd, lex, (yyvsp[-2].table), SCH_COLUMNS)))
MYSQL_YYABORT;
}
#line 47398 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2221:
#line 13576 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->sql_command = SQLCOM_SHOW_BINLOGS;
}
#line 47408 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2222:
#line 13580 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->sql_command = SQLCOM_SHOW_SLAVE_HOSTS;
}
#line 47418 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2223:
#line 13584 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
lex->sql_command= SQLCOM_SHOW_BINLOG_EVENTS;
}
#line 47429 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2225:
#line 13590 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
lex->sql_command= SQLCOM_SHOW_RELAYLOG_EVENTS;
}
#line 47440 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2227:
#line 13596 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
lex->sql_command= SQLCOM_SHOW_KEYS;
if ((yyvsp[-1].lex_str).str)
(yyvsp[-2].table)->change_db(&(yyvsp[-1].lex_str));
if (unlikely(prepare_schema_table(thd, lex, (yyvsp[-2].table), SCH_STATISTICS)))
MYSQL_YYABORT;
}
#line 47455 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2228:
#line 13605 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex=Lex;
lex->sql_command= SQLCOM_SHOW_STORAGE_ENGINES;
if (unlikely(prepare_schema_table(thd, lex, 0, SCH_ENGINES)))
MYSQL_YYABORT;
}
#line 47468 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2229:
#line 13612 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex=Lex;
lex->sql_command= SQLCOM_SHOW_AUTHORS;
}
#line 47479 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2230:
#line 13617 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex=Lex;
lex->sql_command= SQLCOM_SHOW_CONTRIBUTORS;
}
#line 47490 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2231:
#line 13622 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex=Lex;
lex->sql_command= SQLCOM_SHOW_PRIVILEGES;
}
#line 47501 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2232:
#line 13627 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX_CSTRING var= {STRING_WITH_LEN("warning_count")};
(void) create_select_for_variable(thd, &var);
}
#line 47512 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2233:
#line 13632 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX_CSTRING var= {STRING_WITH_LEN("error_count")};
(void) create_select_for_variable(thd, &var);
}
#line 47523 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2234:
#line 13637 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->sql_command = SQLCOM_SHOW_WARNS;}
#line 47531 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2235:
#line 13639 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->sql_command = SQLCOM_SHOW_ERRORS;}
#line 47539 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2236:
#line 13641 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->sql_command = SQLCOM_SHOW_PROFILES; }
#line 47547 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2237:
#line 13643 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
lex->sql_command= SQLCOM_SHOW_PROFILE;
if (unlikely(prepare_schema_table(thd, lex, NULL, SCH_PROFILES)))
MYSQL_YYABORT;
}
#line 47560 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2238:
#line 13650 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
lex->sql_command= SQLCOM_SHOW_STATUS;
lex->option_type= (yyvsp[-2].var_type);
if (unlikely(prepare_schema_table(thd, lex, 0, SCH_SESSION_STATUS)))
MYSQL_YYABORT;
}
#line 47574 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2239:
#line 13658 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->sql_command= SQLCOM_SHOW_PROCESSLIST;}
#line 47582 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2240:
#line 13660 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
lex->sql_command= SQLCOM_SHOW_VARIABLES;
lex->option_type= (yyvsp[-2].var_type);
if (unlikely(prepare_schema_table(thd, lex, 0, SCH_SESSION_VARIABLES)))
MYSQL_YYABORT;
}
#line 47596 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2241:
#line 13668 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
lex->sql_command= SQLCOM_SHOW_CHARSETS;
if (unlikely(prepare_schema_table(thd, lex, 0, SCH_CHARSETS)))
MYSQL_YYABORT;
}
#line 47609 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2242:
#line 13675 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
lex->sql_command= SQLCOM_SHOW_COLLATIONS;
if (unlikely(prepare_schema_table(thd, lex, 0, SCH_COLLATIONS)))
MYSQL_YYABORT;
}
#line 47622 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2243:
#line 13682 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->sql_command= SQLCOM_SHOW_GRANTS;
if (unlikely(!(Lex->grant_user=
(LEX_USER*)thd->alloc(sizeof(LEX_USER)))))
MYSQL_YYABORT;
Lex->grant_user->user= current_user_and_current_role;
}
#line 47636 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2244:
#line 13690 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex=Lex;
lex->sql_command= SQLCOM_SHOW_GRANTS;
lex->grant_user=(yyvsp[-1].lex_user);
}
#line 47648 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2245:
#line 13696 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->set_command(SQLCOM_SHOW_CREATE_DB, (yyvsp[-1].object_ddl_options));
Lex->name= (yyvsp[0].ident_sys);
}
#line 47659 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2246:
#line 13701 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
lex->sql_command = SQLCOM_SHOW_CREATE;
if (!lex->first_select_lex()->add_table_to_list(thd, (yyvsp[0].table), NULL,0))
MYSQL_YYABORT;
lex->create_info.storage_media= HA_SM_DEFAULT;
}
#line 47673 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2247:
#line 13709 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
lex->sql_command = SQLCOM_SHOW_CREATE;
if (!lex->first_select_lex()->add_table_to_list(thd, (yyvsp[0].table), NULL, 0))
MYSQL_YYABORT;
lex->table_type= TABLE_TYPE_VIEW;
}
#line 47687 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2248:
#line 13717 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
lex->sql_command = SQLCOM_SHOW_CREATE;
if (!lex->first_select_lex()->add_table_to_list(thd, (yyvsp[0].table), NULL, 0))
MYSQL_YYABORT;
lex->table_type= TABLE_TYPE_SEQUENCE;
}
#line 47701 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2249:
#line 13725 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->sql_command = SQLCOM_SHOW_BINLOG_STAT;
}
#line 47711 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2250:
#line 13729 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->sql_command = SQLCOM_SHOW_BINLOG_STAT;
}
#line 47721 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2251:
#line 13733 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (!(Lex->m_sql_cmd= new (thd->mem_root)
Sql_cmd_show_slave_status(true)))
MYSQL_YYABORT;
Lex->sql_command = SQLCOM_SHOW_SLAVE_STAT;
}
#line 47734 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2252:
#line 13740 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= thd->lex;
lex->mi.connection_name= null_clex_str;
if (!(lex->m_sql_cmd= new (thd->mem_root)
Sql_cmd_show_slave_status()))
MYSQL_YYABORT;
lex->sql_command = SQLCOM_SHOW_SLAVE_STAT;
}
#line 47749 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2253:
#line 13749 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (!(Lex->m_sql_cmd= new (thd->mem_root)
Sql_cmd_show_slave_status()))
MYSQL_YYABORT;
Lex->sql_command = SQLCOM_SHOW_SLAVE_STAT;
}
#line 47762 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2254:
#line 13756 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
lex->sql_command = SQLCOM_SHOW_CREATE_PROC;
lex->spname= (yyvsp[0].spname);
}
#line 47775 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2255:
#line 13763 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
lex->sql_command = SQLCOM_SHOW_CREATE_FUNC;
lex->spname= (yyvsp[0].spname);
}
#line 47788 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2256:
#line 13770 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
lex->sql_command = SQLCOM_SHOW_CREATE_PACKAGE;
lex->spname= (yyvsp[0].spname);
}
#line 47800 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2257:
#line 13776 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
lex->sql_command = SQLCOM_SHOW_CREATE_PACKAGE;
lex->spname= (yyvsp[0].spname);
}
#line 47812 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2258:
#line 13782 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
lex->sql_command = SQLCOM_SHOW_CREATE_PACKAGE_BODY;
lex->spname= (yyvsp[0].spname);
}
#line 47824 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2259:
#line 13788 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
lex->sql_command = SQLCOM_SHOW_CREATE_PACKAGE_BODY;
lex->spname= (yyvsp[0].spname);
}
#line 47836 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2260:
#line 13794 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
lex->sql_command= SQLCOM_SHOW_CREATE_TRIGGER;
lex->spname= (yyvsp[0].spname);
}
#line 47848 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2261:
#line 13800 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->sql_command= SQLCOM_SHOW_CREATE_USER;
if (unlikely(!(Lex->grant_user=
(LEX_USER*)thd->alloc(sizeof(LEX_USER)))))
MYSQL_YYABORT;
Lex->grant_user->user= current_user;
}
#line 47862 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2262:
#line 13808 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->sql_command= SQLCOM_SHOW_CREATE_USER;
Lex->grant_user= (yyvsp[0].lex_user);
}
#line 47873 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2263:
#line 13813 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
lex->sql_command= SQLCOM_SHOW_STATUS_PROC;
if (unlikely(prepare_schema_table(thd, lex, 0, SCH_PROCEDURES)))
MYSQL_YYABORT;
}
#line 47886 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2264:
#line 13820 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
lex->sql_command= SQLCOM_SHOW_STATUS_FUNC;
if (unlikely(prepare_schema_table(thd, lex, 0, SCH_PROCEDURES)))
MYSQL_YYABORT;
}
#line 47899 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2265:
#line 13827 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
lex->sql_command= SQLCOM_SHOW_STATUS_PACKAGE;
if (unlikely(prepare_schema_table(thd, lex, 0, SCH_PROCEDURES)))
MYSQL_YYABORT;
}
#line 47912 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2266:
#line 13834 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
lex->sql_command= SQLCOM_SHOW_STATUS_PACKAGE;
if (unlikely(prepare_schema_table(thd, lex, 0, SCH_PROCEDURES)))
MYSQL_YYABORT;
}
#line 47925 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2267:
#line 13841 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
lex->sql_command= SQLCOM_SHOW_STATUS_PACKAGE_BODY;
if (unlikely(prepare_schema_table(thd, lex, 0, SCH_PROCEDURES)))
MYSQL_YYABORT;
}
#line 47938 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2268:
#line 13848 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
lex->sql_command= SQLCOM_SHOW_STATUS_PACKAGE_BODY;
if (unlikely(prepare_schema_table(thd, lex, 0, SCH_PROCEDURES)))
MYSQL_YYABORT;
}
#line 47951 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2269:
#line 13855 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->sql_command= SQLCOM_SHOW_PROC_CODE;
Lex->spname= (yyvsp[0].spname);
}
#line 47962 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2270:
#line 13860 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->sql_command= SQLCOM_SHOW_FUNC_CODE;
Lex->spname= (yyvsp[0].spname);
}
#line 47973 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2271:
#line 13865 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->sql_command= SQLCOM_SHOW_PACKAGE_BODY_CODE;
Lex->spname= (yyvsp[0].spname);
}
#line 47984 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2272:
#line 13870 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->sql_command= SQLCOM_SHOW_PACKAGE_BODY_CODE;
Lex->spname= (yyvsp[0].spname);
}
#line 47995 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2273:
#line 13875 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->spname= (yyvsp[0].spname);
Lex->sql_command = SQLCOM_SHOW_CREATE_EVENT;
}
#line 48006 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2274:
#line 13880 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->sql_command= SQLCOM_SHOW_EXPLAIN;
if (unlikely(prepare_schema_table(thd, Lex, 0, SCH_EXPLAIN)))
MYSQL_YYABORT;
add_value_to_list(thd, (yyvsp[0].item));
}
#line 48019 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2275:
#line 13887 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
bool in_plugin;
lex->sql_command= SQLCOM_SHOW_GENERIC;
ST_SCHEMA_TABLE *table= find_schema_table(thd, &(yyvsp[-2].ident_sys), &in_plugin);
if (unlikely(!table || !table->old_format || !in_plugin))
{
thd->parse_error(ER_SYNTAX_ERROR, (yyvsp[-1].simple_string));
MYSQL_YYABORT;
}
if (unlikely(lex->wild && table->idx_field1 < 0))
{
thd->parse_error(ER_SYNTAX_ERROR, (yyvsp[0].simple_string));
MYSQL_YYABORT;
}
if (unlikely(make_schema_select(thd, Lex->current_select, table)))
MYSQL_YYABORT;
}
#line 48044 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2276:
#line 13909 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->sql_command= SQLCOM_SHOW_ENGINE_STATUS; }
#line 48052 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2277:
#line 13911 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->sql_command= SQLCOM_SHOW_ENGINE_MUTEX; }
#line 48060 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2278:
#line 13913 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->sql_command= SQLCOM_SHOW_ENGINE_LOGS; }
#line 48068 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2283:
#line 13927 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.lex_str)= null_clex_str; }
#line 48076 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2284:
#line 13928 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.lex_str)= (yyvsp[0].ident_sys); }
#line 48084 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2285:
#line 13932 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->verbose=0; }
#line 48092 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2286:
#line 13933 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->verbose=1; }
#line 48100 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2289:
#line 13942 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->mi.log_file_name = 0; }
#line 48108 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2290:
#line 13943 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->mi.log_file_name = (yyvsp[0].lex_str).str; }
#line 48116 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2291:
#line 13947 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->mi.pos = 4; /* skip magic number */ }
#line 48124 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2292:
#line 13948 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->mi.pos = (yyvsp[0].ulonglong_number); }
#line 48132 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2293:
#line 13952 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.simple_string)= 0; }
#line 48140 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2294:
#line 13954 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->wild= new (thd->mem_root) String((yyvsp[0].lex_str).str, (yyvsp[0].lex_str).length,
system_charset_info);
if (unlikely(Lex->wild == NULL))
MYSQL_YYABORT;
(yyval.simple_string)= (yyvsp[-1].simple_string);
}
#line 48154 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2295:
#line 13962 "/home/buildbot/git/sql/sql_yacc.yy"
{
Select->where= normalize_cond(thd, (yyvsp[0].item));
if ((yyvsp[0].item))
(yyvsp[0].item)->top_level_item();
(yyval.simple_string)= (yyvsp[-1].simple_string);
}
#line 48167 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2296:
#line 13973 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
if (lex->main_select_push())
MYSQL_YYABORT;
mysql_init_select(lex);
lex->current_select->parsing_place= SELECT_LIST;
lex->sql_command= SQLCOM_SHOW_FIELDS;
lex->first_select_lex()->db= null_clex_str;
lex->verbose= 0;
if (unlikely(prepare_schema_table(thd, lex, (yyvsp[0].table), SCH_COLUMNS)))
MYSQL_YYABORT;
}
#line 48186 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2297:
#line 13986 "/home/buildbot/git/sql/sql_yacc.yy"
{
Select->parsing_place= NO_MATTER;
Lex->pop_select(); //main select
}
#line 48197 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2298:
#line 13991 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->describe|= DESCRIBE_NORMAL; }
#line 48205 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2299:
#line 13993 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex=Lex;
lex->first_select_lex()->options|= SELECT_DESCRIBE;
}
#line 48216 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2308:
#line 14015 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->analyze_stmt= true;
}
#line 48226 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2309:
#line 14021 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->describe|= DESCRIBE_EXTENDED; }
#line 48234 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2310:
#line 14023 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->describe|= DESCRIBE_EXTENDED | DESCRIBE_EXTENDED2; }
#line 48242 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2311:
#line 14024 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->describe|= DESCRIBE_PARTITIONS; }
#line 48250 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2312:
#line 14025 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 48258 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2313:
#line 14029 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 48266 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2314:
#line 14031 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (lex_string_eq(&(yyvsp[0].lex_str), STRING_WITH_LEN("JSON")))
Lex->explain_json= true;
else if (lex_string_eq(&(yyvsp[0].lex_str), STRING_WITH_LEN("TRADITIONAL")))
DBUG_ASSERT(Lex->explain_json==false);
else
my_yyabort_error((ER_UNKNOWN_EXPLAIN_FORMAT, MYF(0), "EXPLAIN",
(yyvsp[0].lex_str).str));
}
#line 48282 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2315:
#line 14043 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 48290 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2316:
#line 14044 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->wild= (yyvsp[0].string); }
#line 48298 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2317:
#line 14046 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->wild= new (thd->mem_root) String((const char*) (yyvsp[0].ident_sys).str,
(yyvsp[0].ident_sys).length,
system_charset_info);
if (unlikely(Lex->wild == NULL))
MYSQL_YYABORT;
}
#line 48312 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2318:
#line 14060 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex=Lex;
lex->sql_command= SQLCOM_FLUSH;
lex->type= 0;
lex->no_write_to_binlog= (yyvsp[0].num);
}
#line 48325 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2319:
#line 14066 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 48333 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2320:
#line 14071 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->type|= REFRESH_TABLES;
/*
Set type of metadata and table locks for
FLUSH TABLES table_list [WITH READ LOCK].
*/
YYPS->m_lock_type= TL_READ_NO_INSERT;
YYPS->m_mdl_type= MDL_SHARED_HIGH_PRIO;
}
#line 48349 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2321:
#line 14081 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 48357 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2322:
#line 14083 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 48365 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2323:
#line 14087 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 48373 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2324:
#line 14089 "/home/buildbot/git/sql/sql_yacc.yy"
{
TABLE_LIST *tables= Lex->query_tables;
for (; tables; tables= tables->next_global)
{
tables->mdl_request.set_type(MDL_SHARED_NO_WRITE);
/* Don't try to flush views. */
tables->required_type= TABLE_TYPE_NORMAL;
/* Ignore temporary tables. */
tables->open_type= OT_BASE_ONLY;
}
}
#line 48391 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2325:
#line 14104 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->type|= REFRESH_READ_LOCK | (yyvsp[0].num); }
#line 48399 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2326:
#line 14106 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->query_tables == NULL))
{
// Table list can't be empty
thd->parse_error(ER_NO_TABLES_USED);
MYSQL_YYABORT;
}
Lex->type|= REFRESH_FOR_EXPORT;
}
#line 48415 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2327:
#line 14114 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 48423 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2329:
#line 14120 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 48431 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2330:
#line 14125 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->type|= REFRESH_ERROR_LOG; }
#line 48439 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2331:
#line 14127 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->type|= REFRESH_ENGINE_LOG; }
#line 48447 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2332:
#line 14129 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->type|= REFRESH_GENERAL_LOG; }
#line 48455 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2333:
#line 14131 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->type|= REFRESH_SLOW_LOG; }
#line 48463 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2334:
#line 14133 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->type|= REFRESH_BINARY_LOG; }
#line 48471 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2335:
#line 14135 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
if (unlikely(lex->type & REFRESH_RELAY_LOG))
my_yyabort_error((ER_WRONG_USAGE, MYF(0), "FLUSH", "RELAY LOGS"));
lex->type|= REFRESH_RELAY_LOG;
lex->relay_log_connection_name= lex->mi.connection_name;
}
#line 48485 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2336:
#line 14143 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->type|= REFRESH_QUERY_CACHE_FREE; }
#line 48493 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2337:
#line 14145 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->type|= REFRESH_HOSTS; }
#line 48501 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2338:
#line 14147 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->type|= REFRESH_GRANT; }
#line 48509 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2339:
#line 14149 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->type|= REFRESH_LOG;
Lex->relay_log_connection_name= empty_clex_str;
}
#line 48520 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2340:
#line 14154 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->type|= REFRESH_STATUS; }
#line 48528 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2341:
#line 14156 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
if (unlikely(lex->type & REFRESH_SLAVE))
my_yyabort_error((ER_WRONG_USAGE, MYF(0), "FLUSH","SLAVE"));
lex->type|= REFRESH_SLAVE;
lex->reset_slave_info.all= false;
}
#line 48542 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2342:
#line 14164 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->type|= REFRESH_MASTER; }
#line 48550 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2343:
#line 14166 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->type|= REFRESH_DES_KEY_FILE; }
#line 48558 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2344:
#line 14168 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->type|= REFRESH_USER_RESOURCES; }
#line 48566 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2345:
#line 14170 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->type|= REFRESH_SSL;}
#line 48574 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2346:
#line 14172 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->type|= REFRESH_THREADS;}
#line 48582 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2347:
#line 14174 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->type|= REFRESH_GENERIC;
ST_SCHEMA_TABLE *table= find_schema_table(thd, &(yyvsp[-1].ident_sys));
if (unlikely(!table || !table->reset_table))
{
thd->parse_error(ER_SYNTAX_ERROR, (yyvsp[0].simple_string));
MYSQL_YYABORT;
}
if (unlikely(Lex->view_list.push_back((LEX_CSTRING*)
thd->memdup(&(yyvsp[-1].ident_sys), sizeof(LEX_CSTRING)),
thd->mem_root)))
MYSQL_YYABORT;
}
#line 48602 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2348:
#line 14190 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 48610 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2349:
#line 14191 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 48618 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2350:
#line 14195 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 48626 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2351:
#line 14200 "/home/buildbot/git/sql/sql_yacc.yy"
{
int type;
if (unlikely(Lex->sphead))
my_yyabort_error((ER_SP_BADSTATEMENT, MYF(0), "BACKUP STAGE"));
if ((type= find_type((yyvsp[0].ident_sys).str, &backup_stage_names,
FIND_TYPE_NO_PREFIX)) <= 0)
my_yyabort_error((ER_BACKUP_UNKNOWN_STAGE, MYF(0), (yyvsp[0].ident_sys).str));
Lex->sql_command= SQLCOM_BACKUP;
Lex->backup_stage= (backup_stages) (type-1);
break;
}
#line 48644 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2352:
#line 14212 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->sphead))
my_yyabort_error((ER_SP_BADSTATEMENT, MYF(0), "BACKUP LOCK"));
if (Lex->main_select_push())
MYSQL_YYABORT;
}
#line 48657 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2353:
#line 14219 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(!Select->add_table_to_list(thd, (yyvsp[0].table), NULL, 0,
TL_READ, MDL_SHARED_HIGH_PRIO)))
MYSQL_YYABORT;
Lex->sql_command= SQLCOM_BACKUP_LOCK;
Lex->pop_select(); //main select
}
#line 48671 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2354:
#line 14227 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->sphead))
my_yyabort_error((ER_SP_BADSTATEMENT, MYF(0), "BACKUP UNLOCK"));
/* Table list is empty for unlock */
Lex->sql_command= SQLCOM_BACKUP_LOCK;
}
#line 48684 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2355:
#line 14236 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 48692 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2356:
#line 14238 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 48700 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2360:
#line 14248 "/home/buildbot/git/sql/sql_yacc.yy"
{
uint32 value= (uint32) (yyvsp[0].ulonglong_number);
if ((yyvsp[0].ulonglong_number) > UINT_MAX32)
{
my_printf_error(ER_BINLOG_CANT_DELETE_GTID_DOMAIN,
"The value of gtid domain being deleted ('%llu') "
"exceeds its maximum size "
"of 32 bit unsigned integer", MYF(0), (yyvsp[0].ulonglong_number));
MYSQL_YYABORT;
}
insert_dynamic(&Lex->delete_gtid_domain, (uchar*) &value);
}
#line 48719 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2361:
#line 14263 "/home/buildbot/git/sql/sql_yacc.yy"
{(yyval.num)= 0;}
#line 48727 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2362:
#line 14264 "/home/buildbot/git/sql/sql_yacc.yy"
{(yyval.num)= REFRESH_CHECKPOINT; }
#line 48735 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2363:
#line 14269 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex=Lex;
lex->sql_command= SQLCOM_RESET; lex->type=0;
}
#line 48746 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2364:
#line 14274 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 48754 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2367:
#line 14283 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->type|= REFRESH_SLAVE; }
#line 48762 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2368:
#line 14285 "/home/buildbot/git/sql/sql_yacc.yy"
{ }
#line 48770 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2369:
#line 14287 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->type|= REFRESH_MASTER;
Lex->next_binlog_file_number= 0;
}
#line 48781 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2371:
#line 14292 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->type|= REFRESH_QUERY_CACHE;}
#line 48789 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2372:
#line 14296 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->reset_slave_info.all= false; }
#line 48797 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2373:
#line 14297 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->reset_slave_info.all= true; }
#line 48805 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2374:
#line 14301 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 48813 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2375:
#line 14303 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->next_binlog_file_number = (yyvsp[0].ulong_num);
}
#line 48823 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2376:
#line 14310 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->stmt_purge_to((yyvsp[0].lex_str));
}
#line 48833 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2377:
#line 14314 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->clause_that_disallows_subselect= "PURGE..BEFORE"; }
#line 48841 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2378:
#line 14316 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->clause_that_disallows_subselect= NULL;
if (Lex->stmt_purge_before((yyvsp[0].item)))
MYSQL_YYABORT;
}
#line 48853 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2379:
#line 14328 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex=Lex;
lex->value_list.empty();
lex->users_list.empty();
lex->sql_command= SQLCOM_KILL;
lex->kill_type= KILL_TYPE_ID;
}
#line 48867 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2380:
#line 14336 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->kill_signal= (killed_state) ((yyvsp[-1].num) | (yyvsp[0].num));
}
#line 48877 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2381:
#line 14342 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.num)= (int) KILL_HARD_BIT; }
#line 48885 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2382:
#line 14343 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.num)= (int) KILL_HARD_BIT; }
#line 48893 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2383:
#line 14344 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.num)= 0; }
#line 48901 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2384:
#line 14348 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.num)= (int) KILL_CONNECTION; }
#line 48909 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2385:
#line 14349 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.num)= (int) KILL_QUERY; }
#line 48917 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2386:
#line 14351 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.num)= (int) KILL_QUERY;
Lex->kill_type= KILL_TYPE_QUERY;
Lex->value_list.push_front((yyvsp[0].item), thd->mem_root);
}
#line 48929 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2387:
#line 14359 "/home/buildbot/git/sql/sql_yacc.yy"
{ }
#line 48937 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2388:
#line 14360 "/home/buildbot/git/sql/sql_yacc.yy"
{ }
#line 48945 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2389:
#line 14365 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->value_list.push_front((yyval.item), thd->mem_root);
}
#line 48955 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2390:
#line 14369 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->users_list.push_back((yyvsp[0].lex_user), thd->mem_root);
Lex->kill_type= KILL_TYPE_USER;
}
#line 48966 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2391:
#line 14376 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->sql_command= SQLCOM_SHUTDOWN; }
#line 48974 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2392:
#line 14377 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 48982 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2393:
#line 14381 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->is_shutdown_wait_for_slaves= false; }
#line 48990 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2394:
#line 14383 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->is_shutdown_wait_for_slaves= true;
}
#line 49000 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2395:
#line 14392 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex=Lex;
lex->sql_command=SQLCOM_CHANGE_DB;
lex->first_select_lex()->db= (yyvsp[0].ident_sys);
}
#line 49012 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2396:
#line 14403 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= thd->lex;
if (unlikely(lex->sphead))
{
my_error(ER_SP_BADSTATEMENT, MYF(0),
(yyvsp[0].filetype) == FILETYPE_CSV ? "LOAD DATA" : "LOAD XML");
MYSQL_YYABORT;
}
if (lex->main_select_push())
MYSQL_YYABORT;
mysql_init_select(lex);
}
#line 49032 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2397:
#line 14417 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex=Lex;
lex->sql_command= SQLCOM_LOAD;
lex->local_file= (yyvsp[-2].num);
lex->duplicates= DUP_ERROR;
lex->ignore= 0;
if (unlikely(!(lex->exchange= new (thd->mem_root)
sql_exchange((yyvsp[0].lex_str).str, 0, (yyvsp[-5].filetype)))))
MYSQL_YYABORT;
}
#line 49049 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2398:
#line 14428 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex=Lex;
if (unlikely(!Select->add_table_to_list(thd, (yyvsp[-1].table), NULL,
TL_OPTION_UPDATING,
(yyvsp[-9].lock_type), MDL_SHARED_WRITE,
NULL, (yyvsp[0].string_list))))
MYSQL_YYABORT;
lex->field_list.empty();
lex->update_list.empty();
lex->value_list.empty();
lex->many_values.empty();
}
#line 49068 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2399:
#line 14441 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->exchange->cs= (yyvsp[0].charset); }
#line 49076 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2400:
#line 14446 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->mark_first_table_as_inserting();
}
#line 49086 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2401:
#line 14452 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.filetype)= FILETYPE_CSV; }
#line 49094 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2402:
#line 14453 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.filetype)= FILETYPE_XML; }
#line 49102 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2403:
#line 14457 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.num)=0;}
#line 49110 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2404:
#line 14458 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.num)=1;}
#line 49118 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2405:
#line 14462 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.lock_type)= TL_WRITE_DEFAULT; }
#line 49126 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2406:
#line 14464 "/home/buildbot/git/sql/sql_yacc.yy"
{
/*
Ignore this option in SP to avoid problem with query cache and
triggers with non default priority locks
*/
(yyval.lock_type)= (Lex->sphead ? TL_WRITE_DEFAULT : TL_WRITE_CONCURRENT_INSERT);
}
#line 49140 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2407:
#line 14471 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.lock_type)= TL_WRITE_LOW_PRIORITY; }
#line 49148 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2408:
#line 14475 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->duplicates=DUP_ERROR; }
#line 49156 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2409:
#line 14476 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->duplicates=DUP_REPLACE; }
#line 49164 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2410:
#line 14477 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->ignore= 1; }
#line 49172 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2415:
#line 14492 "/home/buildbot/git/sql/sql_yacc.yy"
{
DBUG_ASSERT(Lex->exchange != 0);
Lex->exchange->field_term= (yyvsp[0].string);
}
#line 49183 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2416:
#line 14497 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
DBUG_ASSERT(lex->exchange != 0);
lex->exchange->enclosed= (yyvsp[0].string);
lex->exchange->opt_enclosed= 1;
}
#line 49196 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2417:
#line 14504 "/home/buildbot/git/sql/sql_yacc.yy"
{
DBUG_ASSERT(Lex->exchange != 0);
Lex->exchange->enclosed= (yyvsp[0].string);
}
#line 49207 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2418:
#line 14509 "/home/buildbot/git/sql/sql_yacc.yy"
{
DBUG_ASSERT(Lex->exchange != 0);
Lex->exchange->escaped= (yyvsp[0].string);
}
#line 49218 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2423:
#line 14527 "/home/buildbot/git/sql/sql_yacc.yy"
{
DBUG_ASSERT(Lex->exchange != 0);
Lex->exchange->line_term= (yyvsp[0].string);
}
#line 49229 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2424:
#line 14532 "/home/buildbot/git/sql/sql_yacc.yy"
{
DBUG_ASSERT(Lex->exchange != 0);
Lex->exchange->line_start= (yyvsp[0].string);
}
#line 49240 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2425:
#line 14539 "/home/buildbot/git/sql/sql_yacc.yy"
{ }
#line 49248 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2426:
#line 14541 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->exchange->line_term = (yyvsp[0].string); }
#line 49256 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2428:
#line 14547 "/home/buildbot/git/sql/sql_yacc.yy"
{
DBUG_ASSERT(Lex->exchange != 0);
Lex->exchange->skip_lines= atol((yyvsp[-1].lex_str).str);
}
#line 49267 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2429:
#line 14554 "/home/buildbot/git/sql/sql_yacc.yy"
{ }
#line 49275 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2430:
#line 14555 "/home/buildbot/git/sql/sql_yacc.yy"
{ }
#line 49283 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2431:
#line 14559 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 49291 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2432:
#line 14560 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 49299 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2433:
#line 14561 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 49307 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2434:
#line 14566 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->field_list.push_back((yyvsp[0].item), thd->mem_root); }
#line 49315 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2435:
#line 14568 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->field_list.push_back((yyvsp[0].item), thd->mem_root); }
#line 49323 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2436:
#line 14572 "/home/buildbot/git/sql/sql_yacc.yy"
{(yyval.item)= (yyvsp[0].item);}
#line 49331 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2437:
#line 14574 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_user_var_as_out_param(thd, &(yyvsp[0].lex_str));
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 49343 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2438:
#line 14582 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 49351 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2439:
#line 14583 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 49359 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2442:
#line 14593 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
if (unlikely(lex->update_list.push_back((yyvsp[-4].item), thd->mem_root)) ||
unlikely(lex->value_list.push_back((yyvsp[-1].item), thd->mem_root)))
MYSQL_YYABORT;
(yyvsp[-1].item)->set_name_no_truncate(thd, (yyvsp[-2].simple_string), (uint) ((yyvsp[0].simple_string) - (yyvsp[-2].simple_string)), thd->charset());
}
#line 49373 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2443:
#line 14606 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(!((yyval.item_basic_constant)= thd->make_string_literal((yyvsp[0].lex_string_with_metadata)))))
MYSQL_YYABORT;
}
#line 49384 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2444:
#line 14611 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(!((yyval.item_basic_constant)= thd->make_string_literal_nchar((yyvsp[0].lex_string_with_metadata)))))
MYSQL_YYABORT;
}
#line 49395 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2445:
#line 14616 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(!((yyval.item_basic_constant)= thd->make_string_literal_charset((yyvsp[0].lex_string_with_metadata), (yyvsp[-1].charset)))))
MYSQL_YYABORT;
}
#line 49406 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2446:
#line 14621 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(!((yyval.item_basic_constant)= (yyvsp[-1].item_basic_constant)->make_string_literal_concat(thd, &(yyvsp[0].lex_str)))))
MYSQL_YYABORT;
}
#line 49417 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2447:
#line 14629 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.string)= new (thd->mem_root) String((yyvsp[0].lex_str).str,
(yyvsp[0].lex_str).length,
thd->variables.collation_connection);
if (unlikely((yyval.string) == NULL))
MYSQL_YYABORT;
}
#line 49431 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2448:
#line 14636 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.string)= (yyvsp[0].string); }
#line 49439 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2449:
#line 14642 "/home/buildbot/git/sql/sql_yacc.yy"
{
Item *tmp= new (thd->mem_root) Item_hex_hybrid(thd, (yyvsp[0].lex_str).str,
(yyvsp[0].lex_str).length);
if (unlikely(tmp == NULL))
MYSQL_YYABORT;
(yyval.string)= tmp->val_str((String*) 0);
}
#line 49453 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2450:
#line 14650 "/home/buildbot/git/sql/sql_yacc.yy"
{
Item *tmp= new (thd->mem_root) Item_hex_string(thd, (yyvsp[0].lex_str).str,
(yyvsp[0].lex_str).length);
if (unlikely(tmp == NULL))
MYSQL_YYABORT;
(yyval.string)= tmp->val_str((String*) 0);
}
#line 49467 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2451:
#line 14658 "/home/buildbot/git/sql/sql_yacc.yy"
{
Item *tmp= new (thd->mem_root) Item_bin_string(thd, (yyvsp[0].lex_str).str,
(yyvsp[0].lex_str).length);
if (unlikely(tmp == NULL))
MYSQL_YYABORT;
/*
it is OK only emulate fix_fields, because we need only
value of constant
*/
(yyval.string)= tmp->val_str((String*) 0);
}
#line 49485 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2452:
#line 14673 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(!((yyval.item_param)= Lex->add_placeholder(thd, ¶m_clex_str,
YYLIP->get_tok_start(),
YYLIP->get_tok_start() + 1))))
MYSQL_YYABORT;
}
#line 49498 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2453:
#line 14680 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(!((yyval.item_param)= Lex->add_placeholder(thd, &null_clex_str,
(yyvsp[-1].kwd).pos(), (yyvsp[0].ident_cli).end()))))
MYSQL_YYABORT;
}
#line 49510 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2454:
#line 14686 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(!((yyval.item_param)= Lex->add_placeholder(thd, &null_clex_str,
(yyvsp[-1].kwd).pos(),
YYLIP->get_ptr()))))
MYSQL_YYABORT;
}
#line 49523 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2455:
#line 14695 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.item) = (yyvsp[0].item_num); }
#line 49531 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2456:
#line 14697 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyvsp[0].item_num)->max_length++;
(yyval.item)= (yyvsp[0].item_num)->neg(thd);
}
#line 49542 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2457:
#line 14704 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.item) = (yyvsp[0].item_basic_constant); }
#line 49550 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2458:
#line 14705 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.item) = (yyvsp[0].item_num); }
#line 49558 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2459:
#line 14706 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.item)= (yyvsp[0].item); }
#line 49566 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2460:
#line 14708 "/home/buildbot/git/sql/sql_yacc.yy"
{
/*
For the digest computation, in this context only,
NULL is considered a literal, hence reduced to '?'
REDUCE:
TOK_GENERIC_VALUE := NULL_SYM
*/
YYLIP->reduce_digest_token(TOK_GENERIC_VALUE, NULL_SYM);
(yyval.item)= new (thd->mem_root) Item_null(thd);
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
YYLIP->next_state= MY_LEX_OPERATOR_OR_IDENT;
}
#line 49586 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2461:
#line 14722 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_bool(thd, (char*) "FALSE",0);
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 49598 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2462:
#line 14728 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_bool(thd, (char*) "TRUE",1);
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 49610 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2463:
#line 14734 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_hex_hybrid(thd, (yyvsp[0].lex_str).str, (yyvsp[0].lex_str).length);
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 49622 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2464:
#line 14740 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_hex_string(thd, (yyvsp[0].lex_str).str, (yyvsp[0].lex_str).length);
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 49634 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2465:
#line 14746 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)= new (thd->mem_root) Item_bin_string(thd, (yyvsp[0].lex_str).str, (yyvsp[0].lex_str).length);
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 49646 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2466:
#line 14752 "/home/buildbot/git/sql/sql_yacc.yy"
{
Item_string_with_introducer *item_str;
LEX_CSTRING tmp;
(yyvsp[0].string)->get_value(&tmp);
/*
Pass NULL as name. Name will be set in the "select_item" rule and
will include the introducer and the original hex/bin notation.
*/
item_str= new (thd->mem_root)
Item_string_with_introducer(thd, null_clex_str,
tmp, (yyvsp[-1].charset));
if (unlikely(!item_str ||
!item_str->check_well_formed_result(true)))
MYSQL_YYABORT;
(yyval.item)= item_str;
}
#line 49670 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2467:
#line 14773 "/home/buildbot/git/sql/sql_yacc.yy"
{
int error;
(yyval.item_num)= new (thd->mem_root)
Item_int(thd, (yyvsp[0].lex_str).str,
(longlong) my_strtoll10((yyvsp[0].lex_str).str, NULL, &error),
(yyvsp[0].lex_str).length);
if (unlikely((yyval.item_num) == NULL))
MYSQL_YYABORT;
}
#line 49686 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2468:
#line 14783 "/home/buildbot/git/sql/sql_yacc.yy"
{
int error;
(yyval.item_num)= new (thd->mem_root)
Item_int(thd, (yyvsp[0].lex_str).str,
(longlong) my_strtoll10((yyvsp[0].lex_str).str, NULL, &error),
(yyvsp[0].lex_str).length);
if (unlikely((yyval.item_num) == NULL))
MYSQL_YYABORT;
}
#line 49702 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2469:
#line 14793 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item_num)= new (thd->mem_root) Item_uint(thd, (yyvsp[0].lex_str).str, (yyvsp[0].lex_str).length);
if (unlikely((yyval.item_num) == NULL))
MYSQL_YYABORT;
}
#line 49714 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2470:
#line 14799 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item_num)= new (thd->mem_root) Item_decimal(thd, (yyvsp[0].lex_str).str, (yyvsp[0].lex_str).length,
thd->charset());
if (unlikely((yyval.item_num) == NULL) || unlikely(thd->is_error()))
MYSQL_YYABORT;
}
#line 49727 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2471:
#line 14806 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item_num)= new (thd->mem_root) Item_float(thd, (yyvsp[0].lex_str).str, (yyvsp[0].lex_str).length);
if (unlikely((yyval.item_num) == NULL) || unlikely(thd->is_error()))
MYSQL_YYABORT;
}
#line 49739 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2472:
#line 14816 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(!((yyval.item)= type_handler_newdate.create_literal_item(thd,
(yyvsp[0].lex_string_with_metadata).str, (yyvsp[0].lex_string_with_metadata).length,
YYCSCL, true))))
MYSQL_YYABORT;
}
#line 49752 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2473:
#line 14823 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(!((yyval.item)= type_handler_time2.create_literal_item(thd,
(yyvsp[0].lex_string_with_metadata).str, (yyvsp[0].lex_string_with_metadata).length,
YYCSCL, true))))
MYSQL_YYABORT;
}
#line 49765 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2474:
#line 14830 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(!((yyval.item)= type_handler_datetime.create_literal_item(thd,
(yyvsp[0].lex_string_with_metadata).str, (yyvsp[0].lex_string_with_metadata).length,
YYCSCL, true))))
MYSQL_YYABORT;
}
#line 49778 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2475:
#line 14840 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
With_clause *with_clause=
new With_clause((yyvsp[0].num), Lex->curr_with_clause);
if (unlikely(with_clause == NULL))
MYSQL_YYABORT;
lex->derived_tables|= DERIVED_WITH;
lex->with_cte_resolution= true;
lex->curr_with_clause= with_clause;
with_clause->add_to_list(Lex->with_clauses_list_last_next);
if (lex->current_select &&
lex->current_select->parsing_place == BEFORE_OPT_LIST)
lex->current_select->parsing_place= NO_MATTER;
}
#line 49799 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2476:
#line 14855 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.with_clause)= Lex->curr_with_clause;
Lex->curr_with_clause= Lex->curr_with_clause->pop();
}
#line 49810 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2477:
#line 14863 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.num)= 0; }
#line 49818 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2478:
#line 14864 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.num)= 1; }
#line 49826 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2481:
#line 14878 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= thd->lex;
const char *query_start= lex->sphead ? lex->sphead->m_tmp_query
: thd->query();
const char *spec_start= (yyvsp[-3].kwd).pos() + 1;
With_element *elem= new With_element((yyvsp[-6].with_element_head), *(yyvsp[-5].ident_sys_list), (yyvsp[-2].select_lex_unit));
if (elem == NULL || Lex->curr_with_clause->add_with_element(elem))
MYSQL_YYABORT;
if (elem->set_unparsed_spec(thd, spec_start, (yyvsp[-1].kwd).pos(),
spec_start - query_start))
MYSQL_YYABORT;
if ((yyvsp[0].ident_sys_list))
{
elem->set_cycle_list((yyvsp[0].ident_sys_list));
}
elem->set_tables_end_pos(lex->query_tables_last);
}
#line 49850 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2482:
#line 14899 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.ident_sys_list)= NULL; }
#line 49858 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2483:
#line 14902 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (!Lex->curr_with_clause->with_recursive)
{
thd->parse_error(ER_SYNTAX_ERROR, (yyvsp[0].kwd).pos());
}
}
#line 49871 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2484:
#line 14909 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.ident_sys_list)= (yyvsp[-1].ident_sys_list);
}
#line 49881 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2485:
#line 14917 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (((yyval.ident_sys_list)= new (thd->mem_root) List) == NULL)
MYSQL_YYABORT;
}
#line 49892 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2486:
#line 14922 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.ident_sys_list)= (yyvsp[-1].ident_sys_list); }
#line 49900 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2488:
#line 14931 "/home/buildbot/git/sql/sql_yacc.yy"
{
void *buf= thd->alloc(sizeof(Lex_ident_sys));
if (!buf)
MYSQL_YYABORT;
(yyval.ident_sys_ptr)= new (buf) Lex_ident_sys(thd, &(yyvsp[0].ident_cli));
}
#line 49913 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2489:
#line 14941 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.ident_sys_list)= new (thd->mem_root) List;
if (unlikely((yyval.ident_sys_list) == NULL || (yyval.ident_sys_list)->push_back((yyvsp[0].ident_sys_ptr))))
MYSQL_YYABORT;
}
#line 49925 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2490:
#line 14947 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (((yyval.ident_sys_list)= (yyvsp[-2].ident_sys_list))->push_back((yyvsp[0].ident_sys_ptr)))
MYSQL_YYABORT;
}
#line 49936 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2491:
#line 14956 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX_CSTRING *name=
(LEX_CSTRING *) thd->memdup(&(yyvsp[0].ident_sys), sizeof(LEX_CSTRING));
(yyval.with_element_head)= new (thd->mem_root) With_element_head(name);
if (unlikely(name == NULL || (yyval.with_element_head) == NULL))
MYSQL_YYABORT;
(yyval.with_element_head)->tables_pos.set_start_pos(Lex->query_tables_last);
}
#line 49951 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2492:
#line 14973 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.item)=(yyvsp[0].item); }
#line 49959 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2493:
#line 14974 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.item)=(yyvsp[0].item); }
#line 49967 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2494:
#line 14979 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(!((yyval.item)= Lex->create_item_qualified_asterisk(thd, &(yyvsp[-2].ident_sys)))))
MYSQL_YYABORT;
}
#line 49978 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2495:
#line 14984 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(!((yyval.item)= Lex->create_item_qualified_asterisk(thd, &(yyvsp[-4].ident_sys), &(yyvsp[-2].ident_sys)))))
MYSQL_YYABORT;
}
#line 49989 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2496:
#line 14992 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(!((yyval.item)= Lex->create_item_qualified_asterisk(thd, &(yyvsp[-2].ident_cli)))))
MYSQL_YYABORT;
}
#line 50000 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2497:
#line 14997 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(!((yyval.item)= Lex->create_item_qualified_asterisk(thd, &(yyvsp[-4].ident_cli), &(yyvsp[-2].ident_cli)))))
MYSQL_YYABORT;
}
#line 50011 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2498:
#line 15004 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.item)=(yyvsp[0].item); }
#line 50019 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2499:
#line 15010 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(!((yyval.item)= Lex->create_item_ident(thd, &(yyvsp[0].ident_cli)))))
MYSQL_YYABORT;
}
#line 50030 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2500:
#line 15015 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(!((yyval.item)= Lex->create_item_ident(thd, &(yyvsp[-2].ident_cli), &(yyvsp[0].ident_cli)))))
MYSQL_YYABORT;
}
#line 50041 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2501:
#line 15020 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex_ident_cli empty((yyvsp[-2].ident_cli).pos(), 0);
if (unlikely(!((yyval.item)= Lex->create_item_ident(thd, &empty, &(yyvsp[-2].ident_cli), &(yyvsp[0].ident_cli)))))
MYSQL_YYABORT;
}
#line 50053 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2502:
#line 15026 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(!((yyval.item)= Lex->create_item_ident(thd, &(yyvsp[-4].ident_cli), &(yyvsp[-2].ident_cli), &(yyvsp[0].ident_cli)))))
MYSQL_YYABORT;
}
#line 50064 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2503:
#line 15031 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(!((yyval.item)= Lex->make_item_colon_ident_ident(thd, &(yyvsp[-2].ident_cli), &(yyvsp[0].ident_cli)))))
MYSQL_YYABORT;
}
#line 50075 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2504:
#line 15039 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(!((yyval.item)= Lex->create_item_ident_nosp(thd, &(yyvsp[0].ident_sys)))))
MYSQL_YYABORT;
}
#line 50086 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2505:
#line 15044 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(!((yyval.item)= Lex->create_item_ident_nospvar(thd, &(yyvsp[-2].ident_sys), &(yyvsp[0].ident_sys)))))
MYSQL_YYABORT;
}
#line 50097 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2506:
#line 15049 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(!((yyval.item)= Lex->make_item_colon_ident_ident(thd, &(yyvsp[-2].ident_cli), &(yyvsp[0].ident_cli)))))
MYSQL_YYABORT;
}
#line 50108 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2507:
#line 15054 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex_ident_sys none;
if (unlikely(!((yyval.item)= Lex->create_item_ident(thd, &none, &(yyvsp[-2].ident_sys), &(yyvsp[0].ident_sys)))))
MYSQL_YYABORT;
}
#line 50120 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2508:
#line 15060 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(!((yyval.item)= Lex->create_item_ident(thd, &(yyvsp[-4].ident_sys), &(yyvsp[-2].ident_sys), &(yyvsp[0].ident_sys)))))
MYSQL_YYABORT;
}
#line 50131 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2509:
#line 15067 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.lex_str)=(yyvsp[0].ident_sys);}
#line 50139 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2510:
#line 15069 "/home/buildbot/git/sql/sql_yacc.yy"
{
TABLE_LIST *table= Select->table_list.first;
if (unlikely(my_strcasecmp(table_alias_charset, (yyvsp[-4].ident_sys).str,
table->db.str)))
my_yyabort_error((ER_WRONG_DB_NAME, MYF(0), (yyvsp[-4].ident_sys).str));
if (unlikely(my_strcasecmp(table_alias_charset, (yyvsp[-2].ident_sys).str,
table->table_name.str)))
my_yyabort_error((ER_WRONG_TABLE_NAME, MYF(0), (yyvsp[-2].ident_sys).str));
(yyval.lex_str)=(yyvsp[0].ident_sys);
}
#line 50156 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2511:
#line 15080 "/home/buildbot/git/sql/sql_yacc.yy"
{
TABLE_LIST *table= Select->table_list.first;
if (unlikely(my_strcasecmp(table_alias_charset, (yyvsp[-2].ident_sys).str,
table->alias.str)))
my_yyabort_error((ER_WRONG_TABLE_NAME, MYF(0), (yyvsp[-2].ident_sys).str));
(yyval.lex_str)=(yyvsp[0].ident_sys);
}
#line 50170 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2512:
#line 15087 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.lex_str)=(yyvsp[0].ident_sys);}
#line 50178 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2513:
#line 15092 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.table)= new (thd->mem_root) Table_ident(&(yyvsp[0].ident_sys));
if (unlikely((yyval.table) == NULL))
MYSQL_YYABORT;
}
#line 50190 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2514:
#line 15098 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.table)= new (thd->mem_root) Table_ident(thd, &(yyvsp[-2].ident_sys), &(yyvsp[0].ident_sys), 0);
if (unlikely((yyval.table) == NULL))
MYSQL_YYABORT;
}
#line 50202 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2515:
#line 15104 "/home/buildbot/git/sql/sql_yacc.yy"
{
/* For Delphi */
(yyval.table)= new (thd->mem_root) Table_ident(&(yyvsp[0].ident_sys));
if (unlikely((yyval.table) == NULL))
MYSQL_YYABORT;
}
#line 50215 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2516:
#line 15114 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.table)= new (thd->mem_root) Table_ident(&(yyvsp[-1].ident_sys));
if (unlikely((yyval.table) == NULL))
MYSQL_YYABORT;
}
#line 50227 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2517:
#line 15120 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.table)= new (thd->mem_root) Table_ident(thd, &(yyvsp[-3].ident_sys), &(yyvsp[-1].ident_sys), 0);
if (unlikely((yyval.table) == NULL))
MYSQL_YYABORT;
}
#line 50239 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2518:
#line 15129 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX_CSTRING db={(char*) any_db,3};
(yyval.table)= new (thd->mem_root) Table_ident(thd, &db, &(yyvsp[0].ident_sys), 0);
if (unlikely((yyval.table) == NULL))
MYSQL_YYABORT;
}
#line 50252 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2523:
#line 15145 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.ident_cli)= (yyvsp[0].kwd); }
#line 50260 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2524:
#line 15150 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(thd->to_ident_sys_alloc(&(yyval.ident_sys), &(yyvsp[0].ident_cli))))
MYSQL_YYABORT;
}
#line 50271 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2525:
#line 15158 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (thd->make_text_string_sys(&(yyval.lex_str), &(yyvsp[0].lex_string_with_metadata)))
MYSQL_YYABORT;
}
#line 50282 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2526:
#line 15166 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (thd->make_text_string_connection(&(yyval.lex_str), &(yyvsp[0].lex_string_with_metadata)))
MYSQL_YYABORT;
}
#line 50293 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2527:
#line 15174 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (thd->make_text_string_filesystem(&(yyval.lex_str), &(yyvsp[0].lex_string_with_metadata)))
MYSQL_YYABORT;
}
#line 50304 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2529:
#line 15183 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely((yyval.ident_sys).copy_keyword(thd, &(yyvsp[0].kwd))))
MYSQL_YYABORT;
}
#line 50315 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2530:
#line 15190 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.ident_cli)= (yyvsp[0].ident_cli); }
#line 50323 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2531:
#line 15191 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.ident_cli)= (yyvsp[0].kwd); }
#line 50331 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2533:
#line 15197 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely((yyval.ident_sys).copy_keyword(thd, &(yyvsp[0].kwd))))
MYSQL_YYABORT;
}
#line 50342 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2534:
#line 15202 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely((yyval.ident_sys).copy_sys(thd, &(yyvsp[0].lex_str))))
MYSQL_YYABORT;
}
#line 50353 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2536:
#line 15212 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely((yyval.ident_sys).copy_keyword(thd, &(yyvsp[0].kwd))))
MYSQL_YYABORT;
}
#line 50364 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2538:
#line 15221 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely((yyval.ident_sys).copy_keyword(thd, &(yyvsp[0].kwd))))
MYSQL_YYABORT;
}
#line 50375 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2539:
#line 15228 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.lex_str)=(yyvsp[0].ident_sys);}
#line 50383 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2540:
#line 15229 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.lex_str)=(yyvsp[0].lex_str);}
#line 50391 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2541:
#line 15230 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.lex_str)=(yyvsp[0].lex_str);}
#line 50399 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2542:
#line 15235 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(!((yyval.lex_user)=(LEX_USER*) thd->calloc(sizeof(LEX_USER)))))
MYSQL_YYABORT;
(yyval.lex_user)->user = (yyvsp[0].lex_str);
if (unlikely(check_string_char_length(&(yyval.lex_user)->user, ER_USERNAME,
username_char_length,
system_charset_info, 0)))
MYSQL_YYABORT;
}
#line 50416 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2543:
#line 15246 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(!((yyval.lex_user)=(LEX_USER*) thd->calloc(sizeof(LEX_USER)))))
MYSQL_YYABORT;
(yyval.lex_user)->user = (yyvsp[-2].lex_str); (yyval.lex_user)->host=(yyvsp[0].lex_str);
if (unlikely(check_string_char_length(&(yyval.lex_user)->user, ER_USERNAME,
username_char_length,
system_charset_info, 0)) ||
unlikely(check_host_name(&(yyval.lex_user)->host)))
MYSQL_YYABORT;
if ((yyval.lex_user)->host.str[0])
{
/*
Convert hostname part of username to lowercase.
It's OK to use in-place lowercase as long as
the character set is utf8.
*/
my_casedn_str(system_charset_info, (char*) (yyval.lex_user)->host.str);
}
else
{
/*
fix historical undocumented convention that empty host is the
same as '%'
*/
(yyval.lex_user)->host= host_not_specified;
}
}
#line 50451 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2544:
#line 15275 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(!((yyval.lex_user)=(LEX_USER*)thd->calloc(sizeof(LEX_USER)))))
MYSQL_YYABORT;
(yyval.lex_user)->user= current_user;
(yyval.lex_user)->auth= new (thd->mem_root) USER_AUTH();
}
#line 50464 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 2547:
#line 15286 "/home/buildbot/git/sql/sql_yacc.yy"
{
if ((yyvsp[0].lex_user)->user.str != current_user.str && (yyvsp[0].lex_user)->host.str == 0)
(yyvsp[0].lex_user)->host= host_not_specified;
(yyval.lex_user)= (yyvsp[0].lex_user);
}
#line 50476 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3261:
#line 16127 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex=Lex;
lex->set_stmt_init();
}
#line 50487 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3262:
#line 16132 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (Lex->check_main_unit_semantics())
MYSQL_YYABORT;
}
#line 50498 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3265:
#line 16142 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->option_type= OPT_DEFAULT;
if (sp_create_assignment_lex(thd, (yyvsp[0].kwd).pos()))
MYSQL_YYABORT;
}
#line 50510 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3266:
#line 16148 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(sp_create_assignment_instr(thd, yychar == YYEMPTY)))
MYSQL_YYABORT;
}
#line 50521 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3267:
#line 16153 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->option_type= (yyvsp[0].var_type);
}
#line 50531 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3269:
#line 16159 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
if (unlikely(lex->table_or_sp_used()))
my_yyabort_error((ER_SUBQUERIES_NOT_SUPPORTED, MYF(0), "SET STATEMENT"));
lex->stmt_var_list= lex->var_list;
lex->var_list.empty();
if (Lex->check_main_unit_semantics())
MYSQL_YYABORT;
}
#line 50547 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3275:
#line 16186 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (sp_create_assignment_lex(thd, (yyvsp[0].kwd).pos()))
MYSQL_YYABORT;
}
#line 50558 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3276:
#line 16191 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(sp_create_assignment_instr(thd, yychar == YYEMPTY)))
MYSQL_YYABORT;
}
#line 50569 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3279:
#line 16206 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->option_type= (yyvsp[0].var_type);
}
#line 50579 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3282:
#line 16214 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.var_type)=OPT_GLOBAL; }
#line 50587 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3283:
#line 16215 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.var_type)=OPT_SESSION; }
#line 50595 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3284:
#line 16216 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.var_type)=OPT_SESSION; }
#line 50603 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3285:
#line 16220 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.var_type)=OPT_SESSION; }
#line 50611 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3286:
#line 16221 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.var_type)=OPT_GLOBAL; }
#line 50619 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3287:
#line 16222 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.var_type)=OPT_SESSION; }
#line 50627 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3288:
#line 16223 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.var_type)=OPT_SESSION; }
#line 50635 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3289:
#line 16227 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.var_type)=OPT_DEFAULT; }
#line 50643 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3290:
#line 16228 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.var_type)=OPT_GLOBAL; }
#line 50651 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3291:
#line 16229 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.var_type)=OPT_SESSION; }
#line 50659 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3292:
#line 16230 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.var_type)=OPT_SESSION; }
#line 50667 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3293:
#line 16239 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (Lex->main_select_push(false))
MYSQL_YYABORT;
}
#line 50678 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3294:
#line 16244 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex_ident_sys tmp(thd, &(yyvsp[-3].ident_cli));
if (unlikely(!tmp.str) ||
unlikely(Lex->set_system_variable(Lex->option_type, &tmp, (yyvsp[0].item))))
MYSQL_YYABORT;
Lex->pop_select(); //min select
}
#line 50692 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3295:
#line 16252 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (Lex->main_select_push(false))
MYSQL_YYABORT;
}
#line 50703 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3296:
#line 16257 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex_ident_sys tmp(thd, &(yyvsp[-5].ident_cli));
if (unlikely(!tmp.str) ||
unlikely(Lex->set_system_variable(thd, Lex->option_type,
&tmp, &(yyvsp[-3].ident_sys), (yyvsp[0].item))))
MYSQL_YYABORT;
Lex->pop_select(); //min select
}
#line 50718 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3297:
#line 16266 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (Lex->main_select_push(false))
MYSQL_YYABORT;
}
#line 50729 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3298:
#line 16271 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->set_default_system_variable(Lex->option_type,
&(yyvsp[-3].ident_sys), (yyvsp[0].item))))
MYSQL_YYABORT;
Lex->pop_select(); //min select
}
#line 50742 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3299:
#line 16283 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (sp_create_assignment_lex(thd, (yyvsp[-1].ident_cli).pos()))
MYSQL_YYABORT;
}
#line 50753 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3300:
#line 16288 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex_ident_sys tmp(thd, &(yyvsp[-3].ident_cli));
if (unlikely(!tmp.str) ||
unlikely(Lex->set_system_variable(Lex->option_type, &tmp, (yyvsp[0].item))) ||
unlikely(sp_create_assignment_instr(thd, yychar == YYEMPTY)))
MYSQL_YYABORT;
}
#line 50767 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3301:
#line 16296 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (sp_create_assignment_lex(thd, (yyvsp[-3].ident_cli).pos()))
MYSQL_YYABORT;
}
#line 50778 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3302:
#line 16301 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex_ident_sys tmp(thd, &(yyvsp[-5].ident_cli));
if (unlikely(!tmp.str) ||
unlikely(Lex->set_system_variable(thd, Lex->option_type, &tmp, &(yyvsp[-3].ident_sys), (yyvsp[0].item))) ||
unlikely(sp_create_assignment_instr(thd, yychar == YYEMPTY)))
MYSQL_YYABORT;
}
#line 50792 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3303:
#line 16309 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (sp_create_assignment_lex(thd, (yyvsp[-3].kwd).pos()))
MYSQL_YYABORT;
}
#line 50803 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3304:
#line 16314 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->set_default_system_variable(Lex->option_type, &(yyvsp[-3].ident_sys), (yyvsp[0].item))) ||
unlikely(sp_create_assignment_instr(thd, yychar == YYEMPTY)))
MYSQL_YYABORT;
}
#line 50815 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3305:
#line 16324 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (sp_create_assignment_lex(thd, (yyvsp[-1].ident_cli).pos()))
MYSQL_YYABORT;
}
#line 50826 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3306:
#line 16329 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex_ident_sys tmp(thd, &(yyvsp[-3].ident_cli));
if (unlikely(!tmp.str) ||
unlikely(Lex->set_variable(&tmp, (yyvsp[0].item))) ||
unlikely(sp_create_assignment_instr(thd, yychar == YYEMPTY)))
MYSQL_YYABORT;
}
#line 50840 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3307:
#line 16337 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (sp_create_assignment_lex(thd, (yyvsp[-3].ident_cli).pos()))
MYSQL_YYABORT;
}
#line 50851 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3308:
#line 16342 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex_ident_sys tmp(thd, &(yyvsp[-5].ident_cli));
if (unlikely(!tmp.str) ||
unlikely(Lex->set_variable(&tmp, &(yyvsp[-3].ident_sys), (yyvsp[0].item))) ||
unlikely(sp_create_assignment_instr(thd, yychar == YYEMPTY)))
MYSQL_YYABORT;
}
#line 50865 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3309:
#line 16350 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (sp_create_assignment_lex(thd, (yyvsp[-3].kwd).pos()))
MYSQL_YYABORT;
}
#line 50876 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3310:
#line 16355 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->set_default_system_variable(Lex->option_type, &(yyvsp[-3].ident_sys), (yyvsp[0].item))))
MYSQL_YYABORT;
if (unlikely(sp_create_assignment_instr(thd, yychar == YYEMPTY)))
MYSQL_YYABORT;
}
#line 50889 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3311:
#line 16362 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (sp_create_assignment_lex(thd, (yyvsp[-2].lex_str).str))
MYSQL_YYABORT;
}
#line 50900 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3312:
#line 16367 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->set_user_variable(thd, &(yyvsp[-3].lex_str), (yyvsp[0].item))) ||
unlikely(sp_create_assignment_instr(thd, yychar == YYEMPTY)))
MYSQL_YYABORT;
}
#line 50912 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3313:
#line 16373 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (sp_create_assignment_lex(thd, (yyvsp[-4].lex_str).str))
MYSQL_YYABORT;
}
#line 50923 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3314:
#line 16378 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->set_system_variable((yyvsp[-4].var_type), &(yyvsp[-3].ident_sys), (yyvsp[0].item))) ||
unlikely(sp_create_assignment_instr(thd, yychar == YYEMPTY)))
MYSQL_YYABORT;
}
#line 50935 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3315:
#line 16384 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (sp_create_assignment_lex(thd, (yyvsp[-6].lex_str).str))
MYSQL_YYABORT;
}
#line 50946 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3316:
#line 16389 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->set_system_variable(thd, (yyvsp[-6].var_type), &(yyvsp[-5].ident_sys), &(yyvsp[-3].ident_sys), (yyvsp[0].item))) ||
unlikely(sp_create_assignment_instr(thd, yychar == YYEMPTY)))
MYSQL_YYABORT;
}
#line 50958 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3317:
#line 16395 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (sp_create_assignment_lex(thd, (yyvsp[-6].lex_str).str))
MYSQL_YYABORT;
}
#line 50969 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3318:
#line 16400 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->set_default_system_variable((yyvsp[-6].var_type), &(yyvsp[-3].ident_sys), (yyvsp[0].item))) ||
unlikely(sp_create_assignment_instr(thd, yychar == YYEMPTY)))
MYSQL_YYABORT;
}
#line 50981 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3319:
#line 16406 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (sp_create_assignment_lex(thd, (yyvsp[-1].kwd).pos()))
MYSQL_YYABORT;
LEX *lex= thd->lex;
CHARSET_INFO *cs2;
cs2= (yyvsp[0].charset) ? (yyvsp[0].charset): global_system_variables.character_set_client;
set_var_collation_client *var;
var= (new (thd->mem_root)
set_var_collation_client(cs2,
thd->variables.collation_database,
cs2));
if (unlikely(var == NULL))
MYSQL_YYABORT;
lex->var_list.push_back(var, thd->mem_root);
if (unlikely(sp_create_assignment_instr(thd, yychar == YYEMPTY)))
MYSQL_YYABORT;
}
#line 51005 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3320:
#line 16424 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
sp_pcontext *spc= lex->spcont;
LEX_CSTRING names= { STRING_WITH_LEN("names") };
if (unlikely(spc && spc->find_variable(&names, false)))
my_error(ER_SP_BAD_VAR_SHADOW, MYF(0), names.str);
else
thd->parse_error();
MYSQL_YYABORT;
}
#line 51022 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3321:
#line 16435 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (sp_create_assignment_lex(thd, (yyvsp[-2].kwd).pos()))
MYSQL_YYABORT;
LEX *lex= Lex;
CHARSET_INFO *cs2;
CHARSET_INFO *cs3;
cs2= (yyvsp[-1].charset) ? (yyvsp[-1].charset) : global_system_variables.character_set_client;
cs3= (yyvsp[0].charset) ? (yyvsp[0].charset) : cs2;
if (unlikely(!my_charset_same(cs2, cs3)))
{
my_error(ER_COLLATION_CHARSET_MISMATCH, MYF(0),
cs3->name, cs2->csname);
MYSQL_YYABORT;
}
set_var_collation_client *var;
var= new (thd->mem_root) set_var_collation_client(cs3, cs3, cs3);
if (unlikely(var == NULL) ||
unlikely(lex->var_list.push_back(var, thd->mem_root)) ||
unlikely(sp_create_assignment_instr(thd, yychar == YYEMPTY)))
MYSQL_YYABORT;
}
#line 51050 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3322:
#line 16457 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (sp_create_assignment_lex(thd, (yyvsp[-2].kwd).pos()))
MYSQL_YYABORT;
LEX *lex = Lex;
LEX_USER *user;
if (unlikely(!(user=(LEX_USER *) thd->calloc(sizeof(LEX_USER)))))
MYSQL_YYABORT;
user->user= current_user;
set_var_default_role *var= (new (thd->mem_root)
set_var_default_role(user,
(yyvsp[0].lex_user)->user));
if (unlikely(var == NULL) ||
unlikely(lex->var_list.push_back(var, thd->mem_root)))
MYSQL_YYABORT;
thd->lex->autocommit= TRUE;
if (lex->sphead)
lex->sphead->m_flags|= sp_head::HAS_SET_AUTOCOMMIT_STMT;
if (unlikely(sp_create_assignment_instr(thd, yychar == YYEMPTY)))
MYSQL_YYABORT;
}
#line 51078 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3323:
#line 16479 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (sp_create_assignment_lex(thd, (yyvsp[-4].kwd).pos()))
MYSQL_YYABORT;
LEX *lex = Lex;
set_var_default_role *var= (new (thd->mem_root)
set_var_default_role((yyvsp[0].lex_user), (yyvsp[-2].lex_user)->user));
if (unlikely(var == NULL) ||
unlikely(lex->var_list.push_back(var, thd->mem_root)))
MYSQL_YYABORT;
thd->lex->autocommit= TRUE;
if (lex->sphead)
lex->sphead->m_flags|= sp_head::HAS_SET_AUTOCOMMIT_STMT;
if (unlikely(sp_create_assignment_instr(thd, yychar == YYEMPTY)))
MYSQL_YYABORT;
}
#line 51100 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3324:
#line 16495 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (sp_create_assignment_lex(thd, (yyvsp[-1].kwd).pos()))
MYSQL_YYABORT;
LEX *lex = Lex;
set_var_role *var= new (thd->mem_root) set_var_role((yyvsp[0].lex_str));
if (unlikely(var == NULL) ||
unlikely(lex->var_list.push_back(var, thd->mem_root)) ||
unlikely(sp_create_assignment_instr(thd, yychar == YYEMPTY)))
MYSQL_YYABORT;
}
#line 51117 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3325:
#line 16506 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (sp_create_assignment_lex(thd, (yyvsp[-1].kwd).pos()))
MYSQL_YYABORT;
}
#line 51128 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3326:
#line 16511 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex_ident_sys tmp(thd, &(yyvsp[-3].kwd));
if (unlikely(!tmp.str) ||
unlikely(Lex->set_variable(&tmp, (yyvsp[0].item))) ||
unlikely(sp_create_assignment_instr(thd, yychar == YYEMPTY)))
MYSQL_YYABORT;
}
#line 51142 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3327:
#line 16519 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (sp_create_assignment_lex(thd, (yyvsp[-1].kwd).pos()))
MYSQL_YYABORT;
}
#line 51153 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3328:
#line 16524 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->sp_create_set_password_instr(thd, (yyvsp[0].user_auth),
yychar == YYEMPTY)))
MYSQL_YYABORT;
}
#line 51165 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3329:
#line 16530 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (sp_create_assignment_lex(thd, (yyvsp[-1].kwd).pos()))
MYSQL_YYABORT;
}
#line 51176 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3330:
#line 16535 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->sp_create_set_password_instr(thd, (yyvsp[-2].lex_user), (yyvsp[0].user_auth),
yychar == YYEMPTY)))
MYSQL_YYABORT;
}
#line 51188 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3335:
#line 16551 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex=Lex;
Item *item= new (thd->mem_root) Item_int(thd, (int32) (yyvsp[0].num));
if (unlikely(item == NULL))
MYSQL_YYABORT;
set_var *var= (new (thd->mem_root)
set_var(thd, lex->option_type,
find_sys_var(thd, "tx_read_only"),
&null_clex_str,
item));
if (unlikely(var == NULL))
MYSQL_YYABORT;
if (unlikely(lex->var_list.push_back(var, thd->mem_root)))
MYSQL_YYABORT;
}
#line 51210 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3336:
#line 16570 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex=Lex;
Item *item= new (thd->mem_root) Item_int(thd, (int32) (yyvsp[0].tx_isolation));
if (unlikely(item == NULL))
MYSQL_YYABORT;
set_var *var= (new (thd->mem_root)
set_var(thd, lex->option_type,
find_sys_var(thd, "tx_isolation"),
&null_clex_str,
item));
if (unlikely(var == NULL) ||
unlikely(lex->var_list.push_back(var, thd->mem_root)))
MYSQL_YYABORT;
}
#line 51231 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3337:
#line 16587 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.num)= true; }
#line 51239 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3338:
#line 16588 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.num)= false; }
#line 51247 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3339:
#line 16592 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.tx_isolation)= ISO_READ_UNCOMMITTED; }
#line 51255 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3340:
#line 16593 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.tx_isolation)= ISO_READ_COMMITTED; }
#line 51263 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3341:
#line 16594 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.tx_isolation)= ISO_REPEATABLE_READ; }
#line 51271 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3342:
#line 16595 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.tx_isolation)= ISO_SERIALIZABLE; }
#line 51279 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3343:
#line 16601 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.user_auth)= new (thd->mem_root) USER_AUTH();
(yyval.user_auth)->auth_str= (yyvsp[0].lex_string_with_metadata);
}
#line 51290 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3344:
#line 16606 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.user_auth)= new (thd->mem_root) USER_AUTH();
(yyval.user_auth)->pwtext= (yyvsp[-1].lex_string_with_metadata);
}
#line 51301 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3345:
#line 16611 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.user_auth)= new (thd->mem_root) USER_AUTH();
(yyval.user_auth)->pwtext= (yyvsp[-1].lex_string_with_metadata);
(yyval.user_auth)->auth_str.str= Item_func_password::alloc(thd,
(yyvsp[-1].lex_string_with_metadata).str, (yyvsp[-1].lex_string_with_metadata).length, Item_func_password::OLD);
(yyval.user_auth)->auth_str.length= SCRAMBLED_PASSWORD_CHAR_LENGTH_323;
}
#line 51315 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3346:
#line 16621 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.item)=(yyvsp[0].item); }
#line 51323 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3347:
#line 16622 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.item)=0; }
#line 51331 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3348:
#line 16624 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)=new (thd->mem_root) Item_string_sys(thd, "ON", 2);
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 51343 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3349:
#line 16630 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)=new (thd->mem_root) Item_string_sys(thd, "ALL", 3);
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 51355 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3350:
#line 16636 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.item)=new (thd->mem_root) Item_string_sys(thd, "binary", 6);
if (unlikely((yyval.item) == NULL))
MYSQL_YYABORT;
}
#line 51367 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3351:
#line 16647 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
if (unlikely(lex->sphead))
my_yyabort_error((ER_SP_BADSTATEMENT, MYF(0), "LOCK"));
lex->sql_command= SQLCOM_LOCK_TABLES;
}
#line 51381 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3352:
#line 16655 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 51389 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3353:
#line 16660 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 51397 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3354:
#line 16662 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(set_statement_var_if_exists(thd, STRING_WITH_LEN("lock_wait_timeout"), (yyvsp[0].ulong_num))) ||
unlikely(set_statement_var_if_exists(thd, STRING_WITH_LEN("innodb_lock_wait_timeout"), (yyvsp[0].ulong_num))))
MYSQL_YYABORT;
}
#line 51409 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3355:
#line 16668 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(set_statement_var_if_exists(thd, STRING_WITH_LEN("lock_wait_timeout"), 0)) ||
unlikely(set_statement_var_if_exists(thd, STRING_WITH_LEN("innodb_lock_wait_timeout"), 0)))
MYSQL_YYABORT;
}
#line 51421 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3356:
#line 16676 "/home/buildbot/git/sql/sql_yacc.yy"
{ }
#line 51429 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3357:
#line 16677 "/home/buildbot/git/sql/sql_yacc.yy"
{ }
#line 51437 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3360:
#line 16687 "/home/buildbot/git/sql/sql_yacc.yy"
{
thr_lock_type lock_type= (thr_lock_type) (yyvsp[0].num);
bool lock_for_write= (lock_type >= TL_WRITE_ALLOW_WRITE);
ulong table_options= lock_for_write ? TL_OPTION_UPDATING : 0;
enum_mdl_type mdl_type= !lock_for_write
? MDL_SHARED_READ
: lock_type == TL_WRITE_CONCURRENT_INSERT
? MDL_SHARED_WRITE
: MDL_SHARED_NO_READ_WRITE;
if (unlikely(!Lex->current_select_or_default()->
add_table_to_list(thd, (yyvsp[-2].table), (yyvsp[-1].lex_str_ptr), table_options,
lock_type, mdl_type)))
MYSQL_YYABORT;
}
#line 51459 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3361:
#line 16705 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.num)= TL_READ_NO_INSERT; }
#line 51467 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3362:
#line 16706 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.num)= TL_WRITE_DEFAULT; }
#line 51475 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3363:
#line 16708 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.num)= (Lex->sphead ? TL_WRITE_DEFAULT : TL_WRITE_CONCURRENT_INSERT);
}
#line 51485 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3364:
#line 16712 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.num)= TL_WRITE_LOW_PRIORITY; }
#line 51493 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3365:
#line 16713 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.num)= TL_READ; }
#line 51501 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3366:
#line 16718 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
if (unlikely(lex->sphead))
my_yyabort_error((ER_SP_BADSTATEMENT, MYF(0), "UNLOCK"));
lex->sql_command= SQLCOM_UNLOCK_TABLES;
}
#line 51515 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3367:
#line 16726 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 51523 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3368:
#line 16735 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (Lex->main_select_push())
MYSQL_YYABORT;
}
#line 51534 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3369:
#line 16740 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->pop_select(); //main select
}
#line 51544 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3370:
#line 16747 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
if (unlikely(lex->sphead))
my_yyabort_error((ER_SP_BADSTATEMENT, MYF(0), "HANDLER"));
lex->sql_command = SQLCOM_HA_OPEN;
if (!lex->current_select->add_table_to_list(thd, (yyvsp[-2].table), (yyvsp[0].lex_str_ptr), 0))
MYSQL_YYABORT;
}
#line 51559 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3371:
#line 16756 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
if (unlikely(lex->sphead))
my_yyabort_error((ER_SP_BADSTATEMENT, MYF(0), "HANDLER"));
lex->sql_command = SQLCOM_HA_CLOSE;
if (!lex->current_select->add_table_to_list(thd, (yyvsp[-1].table), 0, 0))
MYSQL_YYABORT;
}
#line 51574 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3372:
#line 16765 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex=Lex;
if (unlikely(lex->sphead))
my_yyabort_error((ER_SP_BADSTATEMENT, MYF(0), "HANDLER"));
lex->clause_that_disallows_subselect= "HANDLER..READ";
lex->sql_command = SQLCOM_HA_READ;
lex->ha_rkey_mode= HA_READ_KEY_EXACT; /* Avoid purify warnings */
Item *one= new (thd->mem_root) Item_int(thd, (int32) 1);
if (unlikely(one == NULL))
MYSQL_YYABORT;
lex->current_select->select_limit= one;
lex->current_select->offset_limit= 0;
lex->limit_rows_examined= 0;
if (!lex->current_select->add_table_to_list(thd, (yyvsp[-1].table), 0, 0))
MYSQL_YYABORT;
}
#line 51597 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3373:
#line 16782 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex=Lex;
lex->clause_that_disallows_subselect= NULL;
if (!lex->current_select->explicit_limit)
{
Item *one= new (thd->mem_root) Item_int(thd, (int32) 1);
if (one == NULL)
MYSQL_YYABORT;
lex->current_select->select_limit= one;
lex->current_select->offset_limit= 0;
lex->limit_rows_examined= 0;
}
/* Stored functions are not supported for HANDLER READ. */
if (lex->uses_stored_routines())
{
my_error(ER_NOT_SUPPORTED_YET, MYF(0),
"stored functions in HANDLER ... READ");
MYSQL_YYABORT;
}
}
#line 51624 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3374:
#line 16805 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->ident= null_clex_str; }
#line 51632 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3375:
#line 16806 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->ident= (yyvsp[-1].ident_sys); }
#line 51640 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3376:
#line 16810 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->ha_read_mode = RFIRST; }
#line 51648 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3377:
#line 16811 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->ha_read_mode = RNEXT; }
#line 51656 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3378:
#line 16815 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->ha_read_mode = RFIRST; }
#line 51664 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3379:
#line 16816 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->ha_read_mode = RNEXT; }
#line 51672 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3380:
#line 16817 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->ha_read_mode = RPREV; }
#line 51680 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3381:
#line 16818 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->ha_read_mode = RLAST; }
#line 51688 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3382:
#line 16820 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex=Lex;
lex->ha_read_mode = RKEY;
lex->ha_rkey_mode=(yyvsp[0].ha_rkey_mode);
if (unlikely(!(lex->insert_list= new (thd->mem_root) List_item)))
MYSQL_YYABORT;
}
#line 51702 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3383:
#line 16828 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 51710 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3384:
#line 16832 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.ha_rkey_mode)=HA_READ_KEY_EXACT; }
#line 51718 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3385:
#line 16833 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.ha_rkey_mode)=HA_READ_KEY_OR_NEXT; }
#line 51726 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3386:
#line 16834 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.ha_rkey_mode)=HA_READ_KEY_OR_PREV; }
#line 51734 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3387:
#line 16835 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.ha_rkey_mode)=HA_READ_AFTER_KEY; }
#line 51742 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3388:
#line 16836 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.ha_rkey_mode)=HA_READ_BEFORE_KEY; }
#line 51750 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3389:
#line 16843 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 51758 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3390:
#line 16848 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (Lex->stmt_revoke_table(thd, (yyvsp[-5].lex_grant), *(yyvsp[-2].lex_grant_ident)))
MYSQL_YYABORT;
}
#line 51769 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3391:
#line 16853 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (Lex->stmt_revoke_sp(thd, (yyvsp[-5].lex_grant), *(yyvsp[-2].lex_grant_ident), *(yyvsp[-3].sp_handler)))
MYSQL_YYABORT;
}
#line 51780 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3392:
#line 16858 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->sql_command = SQLCOM_REVOKE_ALL;
}
#line 51790 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3393:
#line 16862 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (Lex->stmt_revoke_proxy(thd, (yyvsp[-2].lex_user)))
MYSQL_YYABORT;
}
#line 51801 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3394:
#line 16867 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->sql_command= SQLCOM_REVOKE_ROLE;
if (unlikely(Lex->users_list.push_front((yyvsp[-2].lex_user), thd->mem_root)))
MYSQL_YYABORT;
}
#line 51813 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3395:
#line 16876 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->with_admin_option= true; (yyval.lex_user)= (yyvsp[0].lex_user); }
#line 51821 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3396:
#line 16878 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->with_admin_option= false; (yyval.lex_user)= (yyvsp[0].lex_user); }
#line 51829 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3397:
#line 16883 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 51837 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3398:
#line 16889 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (Lex->stmt_grant_table(thd, (yyvsp[-7].lex_grant), *(yyvsp[-4].lex_grant_ident), (yyvsp[0].privilege)))
MYSQL_YYABORT;
}
#line 51848 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3399:
#line 16895 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (Lex->stmt_grant_sp(thd, (yyvsp[-7].lex_grant), *(yyvsp[-4].lex_grant_ident), *(yyvsp[-5].sp_handler), (yyvsp[0].privilege)))
MYSQL_YYABORT;
}
#line 51859 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3400:
#line 16900 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (Lex->stmt_grant_proxy(thd, (yyvsp[-3].lex_user), (yyvsp[0].privilege)))
MYSQL_YYABORT;
}
#line 51870 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3401:
#line 16905 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
lex->sql_command= SQLCOM_GRANT_ROLE;
/* The first role is the one that is granted */
if (unlikely(Lex->users_list.push_front((yyvsp[-3].lex_user), thd->mem_root)))
MYSQL_YYABORT;
}
#line 51884 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3402:
#line 16916 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->definer = 0; }
#line 51892 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3403:
#line 16917 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->definer = (yyvsp[0].lex_user); }
#line 51900 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3404:
#line 16921 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->with_admin_option= false; }
#line 51908 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3405:
#line 16922 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->with_admin_option= true; }
#line 51916 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3406:
#line 16927 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->users_list.push_back((yyvsp[0].lex_user), thd->mem_root)))
MYSQL_YYABORT;
}
#line 51927 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3407:
#line 16932 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->users_list.push_back((yyvsp[0].lex_user), thd->mem_root)))
MYSQL_YYABORT;
}
#line 51938 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3408:
#line 16940 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(!((yyval.lex_user)=(LEX_USER*) thd->calloc(sizeof(LEX_USER)))))
MYSQL_YYABORT;
(yyval.lex_user)->user= current_role;
(yyval.lex_user)->auth= NULL;
}
#line 51951 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3409:
#line 16950 "/home/buildbot/git/sql/sql_yacc.yy"
{
CHARSET_INFO *cs= system_charset_info;
/* trim end spaces (as they'll be lost in mysql.user anyway) */
(yyvsp[0].lex_str).length= cs->lengthsp((yyvsp[0].lex_str).str, (yyvsp[0].lex_str).length);
((char*) (yyvsp[0].lex_str).str)[(yyvsp[0].lex_str).length] = '\0';
if (unlikely((yyvsp[0].lex_str).length == 0))
my_yyabort_error((ER_INVALID_ROLE, MYF(0), ""));
if (unlikely(!((yyval.lex_user)=(LEX_USER*) thd->alloc(sizeof(LEX_USER)))))
MYSQL_YYABORT;
(yyval.lex_user)->user= (yyvsp[0].lex_str);
(yyval.lex_user)->host= empty_clex_str;
(yyval.lex_user)->auth= NULL;
if (unlikely(check_string_char_length(&(yyval.lex_user)->user, ER_USERNAME,
username_char_length,
cs, 0)))
MYSQL_YYABORT;
}
#line 51976 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3414:
#line 16979 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (!((yyval.lex_grant)= new (thd->mem_root) Lex_grant_privilege(GLOBAL_ACLS, true)))
MYSQL_YYABORT;
}
#line 51987 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3417:
#line 16992 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (!((yyval.lex_grant)= new (thd->mem_root) Lex_grant_privilege((yyvsp[0].privilege))))
MYSQL_YYABORT;
}
#line 51998 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3418:
#line 16997 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (!((yyval.lex_grant)= new (thd->mem_root) Lex_grant_privilege()) ||
(yyval.lex_grant)->add_column_list_privilege(thd, (yyvsp[0].column_list_privilege).m_columns[0],
(yyvsp[0].column_list_privilege).m_privilege))
MYSQL_YYABORT;
}
#line 52011 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3419:
#line 17004 "/home/buildbot/git/sql/sql_yacc.yy"
{
((yyval.lex_grant)= (yyvsp[-2].lex_grant))->add_object_privilege((yyvsp[0].privilege));
}
#line 52021 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3420:
#line 17008 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (((yyval.lex_grant)= (yyvsp[-2].lex_grant))->add_column_list_privilege(thd, (yyvsp[0].column_list_privilege).m_columns[0],
(yyvsp[0].column_list_privilege).m_privilege))
MYSQL_YYABORT;
}
#line 52033 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3421:
#line 17017 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.column_list_privilege)= Lex_column_list_privilege((yyvsp[-1].ident_sys_list), (yyvsp[-3].privilege));
}
#line 52043 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3422:
#line 17023 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.privilege)= SELECT_ACL; }
#line 52051 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3423:
#line 17024 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.privilege)= INSERT_ACL; }
#line 52059 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3424:
#line 17025 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.privilege)= UPDATE_ACL; }
#line 52067 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3425:
#line 17026 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.privilege)= REFERENCES_ACL; }
#line 52075 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3426:
#line 17030 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.privilege)= SELECT_ACL; }
#line 52083 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3427:
#line 17031 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.privilege)= INSERT_ACL; }
#line 52091 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3428:
#line 17032 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.privilege)= UPDATE_ACL; }
#line 52099 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3429:
#line 17033 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.privilege)= REFERENCES_ACL; }
#line 52107 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3430:
#line 17034 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.privilege)= DELETE_ACL;}
#line 52115 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3431:
#line 17035 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.privilege)= NO_ACL; }
#line 52123 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3432:
#line 17036 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.privilege)= INDEX_ACL;}
#line 52131 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3433:
#line 17037 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.privilege)= ALTER_ACL;}
#line 52139 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3434:
#line 17038 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.privilege)= CREATE_ACL;}
#line 52147 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3435:
#line 17039 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.privilege)= DROP_ACL;}
#line 52155 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3436:
#line 17040 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.privilege)= EXECUTE_ACL;}
#line 52163 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3437:
#line 17041 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.privilege)= RELOAD_ACL;}
#line 52171 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3438:
#line 17042 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.privilege)= SHUTDOWN_ACL;}
#line 52179 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3439:
#line 17043 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.privilege)= PROCESS_ACL;}
#line 52187 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3440:
#line 17044 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.privilege)= FILE_ACL;}
#line 52195 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3441:
#line 17045 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.privilege)= GRANT_ACL;}
#line 52203 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3442:
#line 17046 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.privilege)= SHOW_DB_ACL;}
#line 52211 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3443:
#line 17047 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.privilege)= SUPER_ACL;}
#line 52219 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3444:
#line 17048 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.privilege)= CREATE_TMP_ACL;}
#line 52227 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3445:
#line 17049 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.privilege)= LOCK_TABLES_ACL; }
#line 52235 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3446:
#line 17050 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.privilege)= REPL_SLAVE_ACL; }
#line 52243 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3447:
#line 17051 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.privilege)= BINLOG_MONITOR_ACL; /*Compatibility*/ }
#line 52251 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3448:
#line 17052 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.privilege)= CREATE_VIEW_ACL; }
#line 52259 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3449:
#line 17053 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.privilege)= SHOW_VIEW_ACL; }
#line 52267 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3450:
#line 17054 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.privilege)= CREATE_PROC_ACL; }
#line 52275 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3451:
#line 17055 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.privilege)= ALTER_PROC_ACL; }
#line 52283 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3452:
#line 17056 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.privilege)= CREATE_USER_ACL; }
#line 52291 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3453:
#line 17057 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.privilege)= EVENT_ACL;}
#line 52299 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3454:
#line 17058 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.privilege)= TRIGGER_ACL; }
#line 52307 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3455:
#line 17059 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.privilege)= CREATE_TABLESPACE_ACL; }
#line 52315 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3456:
#line 17060 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.privilege)= DELETE_HISTORY_ACL; }
#line 52323 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3457:
#line 17061 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.privilege)= SET_USER_ACL; }
#line 52331 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3458:
#line 17062 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.privilege)= FEDERATED_ADMIN_ACL; }
#line 52339 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3459:
#line 17063 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.privilege)= CONNECTION_ADMIN_ACL; }
#line 52347 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3460:
#line 17064 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.privilege)= READ_ONLY_ADMIN_ACL; }
#line 52355 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3461:
#line 17065 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.privilege)= READ_ONLY_ADMIN_ACL; }
#line 52363 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3462:
#line 17066 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.privilege)= BINLOG_MONITOR_ACL; }
#line 52371 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3463:
#line 17067 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.privilege)= BINLOG_ADMIN_ACL; }
#line 52379 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3464:
#line 17068 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.privilege)= BINLOG_REPLAY_ACL; }
#line 52387 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3465:
#line 17069 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.privilege)= REPL_MASTER_ADMIN_ACL; }
#line 52395 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3466:
#line 17070 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.privilege)= REPL_SLAVE_ADMIN_ACL; }
#line 52403 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3467:
#line 17071 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.privilege)= SLAVE_MONITOR_ACL; }
#line 52411 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3468:
#line 17075 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 52419 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3469:
#line 17076 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 52427 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3472:
#line 17086 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex=Lex;
if (lex->account_options.x509_subject.str)
my_yyabort_error((ER_DUP_ARGUMENT, MYF(0), "SUBJECT"));
lex->account_options.x509_subject= (yyvsp[0].lex_string_with_metadata);
}
#line 52440 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3473:
#line 17093 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex=Lex;
if (lex->account_options.x509_issuer.str)
my_yyabort_error((ER_DUP_ARGUMENT, MYF(0), "ISSUER"));
lex->account_options.x509_issuer= (yyvsp[0].lex_string_with_metadata);
}
#line 52453 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3474:
#line 17100 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex=Lex;
if (lex->account_options.ssl_cipher.str)
my_yyabort_error((ER_DUP_ARGUMENT, MYF(0), "CIPHER"));
lex->account_options.ssl_cipher= (yyvsp[0].lex_string_with_metadata);
}
#line 52466 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3475:
#line 17110 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX_CSTRING db;
if (unlikely(Lex->copy_db_to(&db)))
MYSQL_YYABORT;
if (!((yyval.lex_grant_ident)= new (thd->mem_root) Lex_grant_object_name(db,
Lex_grant_object_name::STAR)))
MYSQL_YYABORT;
}
#line 52481 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3476:
#line 17119 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (!((yyval.lex_grant_ident)= new (thd->mem_root) Lex_grant_object_name((yyvsp[-2].ident_sys),
Lex_grant_object_name::IDENT_STAR)))
MYSQL_YYABORT;
}
#line 52493 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3477:
#line 17125 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (!((yyval.lex_grant_ident)= new (thd->mem_root) Lex_grant_object_name(
null_clex_str,
Lex_grant_object_name::STAR_STAR)))
MYSQL_YYABORT;
}
#line 52506 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3478:
#line 17132 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (!((yyval.lex_grant_ident)= new (thd->mem_root) Lex_grant_object_name((yyvsp[0].table))))
MYSQL_YYABORT;
}
#line 52517 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3479:
#line 17140 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->users_list.push_back((yyvsp[0].lex_user), thd->mem_root)))
MYSQL_YYABORT;
}
#line 52528 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3480:
#line 17145 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->users_list.push_back((yyvsp[0].lex_user), thd->mem_root)))
MYSQL_YYABORT;
}
#line 52539 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3481:
#line 17153 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->users_list.push_back((yyvsp[0].lex_user), thd->mem_root)))
MYSQL_YYABORT;
}
#line 52550 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3482:
#line 17158 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->users_list.push_back((yyvsp[0].lex_user), thd->mem_root)))
MYSQL_YYABORT;
}
#line 52561 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3483:
#line 17166 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->users_list.push_back((yyvsp[0].lex_user), thd->mem_root)))
MYSQL_YYABORT;
}
#line 52572 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3484:
#line 17171 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->users_list.push_back((yyvsp[0].lex_user), thd->mem_root)))
MYSQL_YYABORT;
}
#line 52583 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3489:
#line 17182 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.lex_user)= (yyvsp[-3].lex_user);
(yyvsp[-3].lex_user)->auth= new (thd->mem_root) USER_AUTH();
(yyvsp[-3].lex_user)->auth->pwtext= (yyvsp[0].lex_string_with_metadata);
}
#line 52595 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3490:
#line 17188 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.lex_user)= (yyvsp[-4].lex_user);
(yyvsp[-4].lex_user)->auth= new (thd->mem_root) USER_AUTH();
(yyvsp[-4].lex_user)->auth->auth_str= (yyvsp[0].lex_string_with_metadata);
}
#line 52607 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3491:
#line 17194 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.lex_user)= (yyvsp[-3].lex_user);
(yyvsp[-3].lex_user)->auth= (yyvsp[0].user_auth);
}
#line 52618 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3492:
#line 17199 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.lex_user)= (yyvsp[0].lex_user);
}
#line 52628 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3493:
#line 17206 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.user_auth)= (yyvsp[-2].user_auth);
DBUG_ASSERT((yyval.user_auth)->next == NULL);
(yyval.user_auth)->next= (yyvsp[0].user_auth);
}
#line 52640 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3494:
#line 17212 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.user_auth)= (yyvsp[0].user_auth);
}
#line 52650 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3495:
#line 17219 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.user_auth)= (yyvsp[0].user_auth);
(yyval.user_auth)->plugin= (yyvsp[-1].lex_str);
}
#line 52661 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3496:
#line 17227 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (!((yyval.user_auth)=(USER_AUTH*) thd->calloc(sizeof(USER_AUTH))))
MYSQL_YYABORT;
}
#line 52672 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3497:
#line 17232 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (!((yyval.user_auth)=(USER_AUTH*) thd->calloc(sizeof(USER_AUTH))))
MYSQL_YYABORT;
(yyval.user_auth)->auth_str= (yyvsp[0].lex_str);
}
#line 52684 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3498:
#line 17238 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (!((yyval.user_auth)=(USER_AUTH*) thd->calloc(sizeof(USER_AUTH))))
MYSQL_YYABORT;
(yyval.user_auth)->pwtext= (yyvsp[-1].lex_string_with_metadata);
}
#line 52696 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3500:
#line 17248 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->account_options.ssl_type= SSL_TYPE_SPECIFIED;
}
#line 52706 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3501:
#line 17252 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->account_options.ssl_type= SSL_TYPE_ANY;
}
#line 52716 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3502:
#line 17256 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->account_options.ssl_type= SSL_TYPE_X509;
}
#line 52726 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3503:
#line 17260 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->account_options.ssl_type= SSL_TYPE_NONE;
}
#line 52736 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3504:
#line 17267 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->account_options.questions=(yyvsp[0].ulong_num);
Lex->account_options.specified_limits|= USER_RESOURCES::QUERIES_PER_HOUR;
}
#line 52747 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3505:
#line 17272 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->account_options.updates=(yyvsp[0].ulong_num);
Lex->account_options.specified_limits|= USER_RESOURCES::UPDATES_PER_HOUR;
}
#line 52758 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3506:
#line 17277 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->account_options.conn_per_hour= (yyvsp[0].ulong_num);
Lex->account_options.specified_limits|= USER_RESOURCES::CONNECTIONS_PER_HOUR;
}
#line 52769 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3507:
#line 17282 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->account_options.user_conn= (yyvsp[0].num);
Lex->account_options.specified_limits|= USER_RESOURCES::USER_CONNECTIONS;
}
#line 52780 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3508:
#line 17287 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->account_options.max_statement_time= (yyvsp[0].item_num)->val_real();
Lex->account_options.specified_limits|= USER_RESOURCES::MAX_STATEMENT_TIME;
}
#line 52791 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3509:
#line 17294 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 52799 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3510:
#line 17295 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 52807 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3511:
#line 17299 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 52815 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3513:
#line 17305 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.privilege)= NO_ACL; }
#line 52823 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3514:
#line 17306 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.privilege)= (yyvsp[0].privilege); }
#line 52831 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3515:
#line 17310 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.privilege)= NO_ACL; }
#line 52839 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3516:
#line 17311 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.privilege)= GRANT_ACL; }
#line 52847 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3517:
#line 17315 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.privilege)= (yyvsp[-1].privilege) | (yyvsp[0].privilege); }
#line 52855 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3519:
#line 17320 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.privilege)= GRANT_ACL;}
#line 52863 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3520:
#line 17321 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.privilege)= NO_ACL; }
#line 52871 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3521:
#line 17326 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex=Lex;
lex->sql_command = SQLCOM_BEGIN;
lex->start_transaction_opt= 0;
}
#line 52883 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3522:
#line 17331 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 52891 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3523:
#line 17336 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->sql_command= SQLCOM_COMPOUND;
if (Lex->sp_body_finalize_procedure(thd))
MYSQL_YYABORT;
}
#line 52903 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3524:
#line 17344 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.num)= 0; }
#line 52911 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3525:
#line 17345 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.num)= 1; }
#line 52919 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3526:
#line 17349 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 52927 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3527:
#line 17350 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 52935 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3528:
#line 17355 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.m_yes_no_unk)= TVL_UNKNOWN; }
#line 52943 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3529:
#line 17356 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.m_yes_no_unk)= TVL_NO; }
#line 52951 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3530:
#line 17357 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.m_yes_no_unk)= TVL_YES; }
#line 52959 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3531:
#line 17362 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.m_yes_no_unk)= TVL_UNKNOWN; }
#line 52967 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3532:
#line 17363 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.m_yes_no_unk)= TVL_YES; }
#line 52975 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3533:
#line 17364 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.m_yes_no_unk)= TVL_NO; }
#line 52983 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3534:
#line 17369 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex=Lex;
lex->sql_command= SQLCOM_COMMIT;
/* Don't allow AND CHAIN RELEASE. */
MYSQL_YYABORT_UNLESS((yyvsp[-1].m_yes_no_unk) != TVL_YES || (yyvsp[0].m_yes_no_unk) != TVL_YES);
lex->tx_chain= (yyvsp[-1].m_yes_no_unk);
lex->tx_release= (yyvsp[0].m_yes_no_unk);
}
#line 52998 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3535:
#line 17381 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex=Lex;
lex->sql_command= SQLCOM_ROLLBACK;
/* Don't allow AND CHAIN RELEASE. */
MYSQL_YYABORT_UNLESS((yyvsp[-1].m_yes_no_unk) != TVL_YES || (yyvsp[0].m_yes_no_unk) != TVL_YES);
lex->tx_chain= (yyvsp[-1].m_yes_no_unk);
lex->tx_release= (yyvsp[0].m_yes_no_unk);
}
#line 53013 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3536:
#line 17390 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex=Lex;
lex->sql_command= SQLCOM_ROLLBACK_TO_SAVEPOINT;
lex->ident= (yyvsp[0].ident_sys);
}
#line 53025 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3537:
#line 17396 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex=Lex;
lex->sql_command= SQLCOM_ROLLBACK_TO_SAVEPOINT;
lex->ident= (yyvsp[0].ident_sys);
}
#line 53037 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3538:
#line 17405 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex=Lex;
lex->sql_command= SQLCOM_SAVEPOINT;
lex->ident= (yyvsp[0].ident_sys);
}
#line 53049 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3539:
#line 17414 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex=Lex;
lex->sql_command= SQLCOM_RELEASE_SAVEPOINT;
lex->ident= (yyvsp[0].ident_sys);
}
#line 53061 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3540:
#line 17427 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.unit_operation).unit_type= UNION_TYPE; (yyval.unit_operation).distinct= (yyvsp[0].num); }
#line 53069 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3541:
#line 17429 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.unit_operation).unit_type= INTERSECT_TYPE; (yyval.unit_operation).distinct= (yyvsp[0].num); }
#line 53077 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3542:
#line 17431 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.unit_operation).unit_type= EXCEPT_TYPE; (yyval.unit_operation).distinct= (yyvsp[0].num); }
#line 53085 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3543:
#line 17438 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.num)=1; }
#line 53093 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3544:
#line 17439 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.num)=1; }
#line 53101 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3545:
#line 17440 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.num)=0; }
#line 53109 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3546:
#line 17444 "/home/buildbot/git/sql/sql_yacc.yy"
{ Select->options|= SELECT_STRAIGHT_JOIN; }
#line 53117 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3547:
#line 17446 "/home/buildbot/git/sql/sql_yacc.yy"
{
YYPS->m_lock_type= TL_READ_HIGH_PRIORITY;
YYPS->m_mdl_type= MDL_SHARED_READ;
Select->options|= SELECT_HIGH_PRIORITY;
}
#line 53129 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3548:
#line 17451 "/home/buildbot/git/sql/sql_yacc.yy"
{ Select->options|= SELECT_DISTINCT; }
#line 53137 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3549:
#line 17452 "/home/buildbot/git/sql/sql_yacc.yy"
{ Select->options|= SELECT_DISTINCT; }
#line 53145 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3550:
#line 17453 "/home/buildbot/git/sql/sql_yacc.yy"
{ Select->options|= SELECT_SMALL_RESULT; }
#line 53153 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3551:
#line 17454 "/home/buildbot/git/sql/sql_yacc.yy"
{ Select->options|= SELECT_BIG_RESULT; }
#line 53161 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3552:
#line 17455 "/home/buildbot/git/sql/sql_yacc.yy"
{ Select->options|= OPTION_BUFFER_RESULT; }
#line 53169 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3553:
#line 17456 "/home/buildbot/git/sql/sql_yacc.yy"
{ Select->options|= OPTION_FOUND_ROWS; }
#line 53177 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3554:
#line 17457 "/home/buildbot/git/sql/sql_yacc.yy"
{ Select->options|= SELECT_ALL; }
#line 53185 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3557:
#line 17473 "/home/buildbot/git/sql/sql_yacc.yy"
{
/*
We have to distinguish missing DEFINER-clause from case when
CURRENT_USER specified as definer explicitly in order to properly
handle CREATE TRIGGER statements which come to replication thread
from older master servers (i.e. to create non-suid trigger in this
case).
*/
thd->lex->definer= 0;
}
#line 53202 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3558:
#line 17487 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->definer= (yyvsp[0].lex_user);
Lex->account_options.reset();
}
#line 53213 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3559:
#line 17500 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.num)= DTYPE_ALGORITHM_UNDEFINED; }
#line 53221 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3560:
#line 17501 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.num)= VIEW_ALGORITHM_MERGE; }
#line 53229 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3561:
#line 17502 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.num)= VIEW_ALGORITHM_TMPTABLE; }
#line 53237 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3562:
#line 17506 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.view_suid)= VIEW_SUID_DEFAULT; }
#line 53245 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3563:
#line 17507 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.view_suid)= (yyvsp[0].view_suid); }
#line 53253 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3564:
#line 17511 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.view_suid)= VIEW_SUID_DEFINER; }
#line 53261 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3565:
#line 17512 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.view_suid)= VIEW_SUID_INVOKER; }
#line 53269 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3566:
#line 17517 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 53277 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3567:
#line 17518 "/home/buildbot/git/sql/sql_yacc.yy"
{ }
#line 53285 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3568:
#line 17523 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->view_list.push_back((LEX_CSTRING*)
thd->memdup(&(yyvsp[0].ident_sys), sizeof(LEX_CSTRING)),
thd->mem_root);
}
#line 53297 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3569:
#line 17529 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->view_list.push_back((LEX_CSTRING*)
thd->memdup(&(yyvsp[0].ident_sys), sizeof(LEX_CSTRING)),
thd->mem_root);
}
#line 53309 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3570:
#line 17537 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
lex->parsing_options.allows_variable= FALSE;
lex->create_view->select.str= (char *) YYLIP->get_cpp_ptr();
}
#line 53321 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3571:
#line 17544 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (Lex->parsed_create_view((yyvsp[-1].select_lex_unit), (yyvsp[0].num)))
MYSQL_YYABORT;
}
#line 53332 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3572:
#line 17551 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.num)= VIEW_CHECK_NONE; }
#line 53340 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3573:
#line 17552 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.num)= VIEW_CHECK_CASCADED; }
#line 53348 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3574:
#line 17553 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.num)= VIEW_CHECK_CASCADED; }
#line 53356 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3575:
#line 17554 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.num)= VIEW_CHECK_LOCAL; }
#line 53364 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3576:
#line 17565 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.trigger_action_order_type)= TRG_ORDER_FOLLOWS; }
#line 53372 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3577:
#line 17567 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.trigger_action_order_type)= TRG_ORDER_PRECEDES; }
#line 53380 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3578:
#line 17572 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.trg_execution_order).ordering_clause= TRG_ORDER_NONE;
(yyval.trg_execution_order).anchor_trigger_name.str= NULL;
(yyval.trg_execution_order).anchor_trigger_name.length= 0;
}
#line 53392 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3579:
#line 17579 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.trg_execution_order).ordering_clause= (yyvsp[-1].trigger_action_order_type);
(yyval.trg_execution_order).anchor_trigger_name= (yyvsp[0].lex_str);
}
#line 53403 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3580:
#line 17588 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->add_create_options_with_check((yyvsp[0].object_ddl_options))))
MYSQL_YYABORT;
}
#line 53414 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3581:
#line 17597 "/home/buildbot/git/sql/sql_yacc.yy"
{ /* $9 */
Lex->raw_trg_on_table_name_begin= YYLIP->get_tok_start();
}
#line 53424 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3582:
#line 17603 "/home/buildbot/git/sql/sql_yacc.yy"
{ /* $13 */
Lex->raw_trg_on_table_name_end= YYLIP->get_tok_start();
}
#line 53434 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3583:
#line 17608 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->trg_chistics.ordering_clause_begin= YYLIP->get_cpp_ptr();
}
#line 53444 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3584:
#line 17612 "/home/buildbot/git/sql/sql_yacc.yy"
{ /* $18 */
LEX *lex= thd->lex;
Lex_input_stream *lip= YYLIP;
if (unlikely(lex->sphead))
my_yyabort_error((ER_SP_NO_RECURSIVE_CREATE, MYF(0), "TRIGGER"));
lex->stmt_definition_begin= (yyvsp[-16].simple_string);
lex->ident.str= (yyvsp[-9].simple_string);
lex->ident.length= (yyvsp[-5].simple_string) - (yyvsp[-9].simple_string);
lex->spname= (yyvsp[-13].spname);
(*static_cast(&lex->trg_chistics))= ((yyvsp[0].trg_execution_order));
lex->trg_chistics.ordering_clause_end= lip->get_cpp_ptr();
if (unlikely(!lex->make_sp_head(thd, (yyvsp[-13].spname), &sp_handler_trigger,
DEFAULT_AGGREGATE)))
MYSQL_YYABORT;
lex->sphead->set_body_start(thd, lip->get_cpp_tok_start());
}
#line 53471 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3585:
#line 17633 "/home/buildbot/git/sql/sql_yacc.yy"
{ /* $20 */
LEX *lex= Lex;
lex->sql_command= SQLCOM_CREATE_TRIGGER;
if (lex->sp_body_finalize_trigger(thd))
MYSQL_YYABORT;
/*
We have to do it after parsing trigger body, because some of
sp_proc_stmt alternatives are not saving/restoring LEX, so
lex->query_tables can be wiped out.
*/
if (!lex->first_select_lex()->
add_table_to_list(thd, (yyvsp[-9].table), (LEX_CSTRING*) 0,
TL_OPTION_UPDATING, TL_READ_NO_INSERT,
MDL_SHARED_NO_WRITE))
MYSQL_YYABORT;
}
#line 53496 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3586:
#line 17661 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
lex->init_last_field(&lex->sphead->m_return_field_def,
&empty_clex_str,
thd->variables.collation_database);
}
#line 53509 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3587:
#line 17668 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->sf_return_fill_definition((yyvsp[0].Lex_field_type))))
MYSQL_YYABORT;
}
#line 53520 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3588:
#line 17679 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->sql_command = SQLCOM_XA_START;
}
#line 53530 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3589:
#line 17683 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->sql_command = SQLCOM_XA_END;
}
#line 53540 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3590:
#line 17687 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->sql_command = SQLCOM_XA_PREPARE;
}
#line 53550 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3591:
#line 17691 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->sql_command = SQLCOM_XA_COMMIT;
}
#line 53560 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3592:
#line 17695 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->sql_command = SQLCOM_XA_ROLLBACK;
}
#line 53570 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3593:
#line 17699 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->sql_command = SQLCOM_XA_RECOVER;
Lex->verbose= (yyvsp[0].num);
}
#line 53581 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3594:
#line 17706 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.num)= false; }
#line 53589 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3595:
#line 17708 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (lex_string_eq(&(yyvsp[0].lex_str), STRING_WITH_LEN("SQL")))
(yyval.num)= true;
else if (lex_string_eq(&(yyvsp[0].lex_str), STRING_WITH_LEN("RAW")))
(yyval.num)= false;
else
{
my_yyabort_error((ER_UNKNOWN_EXPLAIN_FORMAT, MYF(0),
"XA RECOVER", (yyvsp[0].lex_str).str));
(yyval.num)= false;
}
}
#line 53608 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3596:
#line 17724 "/home/buildbot/git/sql/sql_yacc.yy"
{
MYSQL_YYABORT_UNLESS((yyvsp[0].string)->length() <= MAXGTRIDSIZE);
if (unlikely(!(Lex->xid=(XID *)thd->alloc(sizeof(XID)))))
MYSQL_YYABORT;
Lex->xid->set(1L, (yyvsp[0].string)->ptr(), (yyvsp[0].string)->length(), 0, 0);
}
#line 53621 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3597:
#line 17731 "/home/buildbot/git/sql/sql_yacc.yy"
{
MYSQL_YYABORT_UNLESS((yyvsp[-2].string)->length() <= MAXGTRIDSIZE && (yyvsp[0].string)->length() <= MAXBQUALSIZE);
if (unlikely(!(Lex->xid=(XID *)thd->alloc(sizeof(XID)))))
MYSQL_YYABORT;
Lex->xid->set(1L, (yyvsp[-2].string)->ptr(), (yyvsp[-2].string)->length(), (yyvsp[0].string)->ptr(), (yyvsp[0].string)->length());
}
#line 53634 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3598:
#line 17738 "/home/buildbot/git/sql/sql_yacc.yy"
{
MYSQL_YYABORT_UNLESS((yyvsp[-4].string)->length() <= MAXGTRIDSIZE &&
(yyvsp[-2].string)->length() <= MAXBQUALSIZE &&
(yyvsp[0].ulong_num) <= static_cast(
std::numeric_limits::max()));
if (unlikely(!(Lex->xid=(XID *)thd->alloc(sizeof(XID)))))
MYSQL_YYABORT;
Lex->xid->set((yyvsp[0].ulong_num), (yyvsp[-4].string)->ptr(), (yyvsp[-4].string)->length(), (yyvsp[-2].string)->ptr(), (yyvsp[-2].string)->length());
}
#line 53650 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3599:
#line 17750 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 53658 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3600:
#line 17751 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 53666 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3601:
#line 17752 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 53674 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3602:
#line 17756 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->xa_opt=XA_NONE; }
#line 53682 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3603:
#line 17757 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->xa_opt=XA_JOIN; }
#line 53690 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3604:
#line 17758 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->xa_opt=XA_RESUME; }
#line 53698 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3605:
#line 17762 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->xa_opt=XA_NONE; }
#line 53706 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3606:
#line 17763 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->xa_opt=XA_ONE_PHASE; }
#line 53714 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3607:
#line 17768 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->xa_opt=XA_NONE; }
#line 53722 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3608:
#line 17770 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->xa_opt=XA_SUSPEND; }
#line 53730 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3610:
#line 17775 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 53738 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3611:
#line 17776 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->xa_opt=XA_FOR_MIGRATE; }
#line 53746 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3612:
#line 17781 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (Lex->stmt_install_plugin((yyvsp[-3].object_ddl_options), (yyvsp[-2].ident_sys), (yyvsp[0].lex_str)))
MYSQL_YYABORT;
}
#line 53757 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3613:
#line 17786 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->stmt_install_plugin((yyvsp[0].lex_str));
}
#line 53767 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3614:
#line 17793 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (Lex->stmt_uninstall_plugin_by_name((yyvsp[-1].object_ddl_options), (yyvsp[0].ident_sys)))
MYSQL_YYABORT;
}
#line 53778 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3615:
#line 17798 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (Lex->stmt_uninstall_plugin_by_soname((yyvsp[-1].object_ddl_options), (yyvsp[0].lex_str)))
MYSQL_YYABORT;
}
#line 53789 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3616:
#line 17807 "/home/buildbot/git/sql/sql_yacc.yy"
{
YYERROR;
}
#line 53799 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3621:
#line 18228 "/home/buildbot/git/sql/sql_yacc.yy"
{
// Direct procedure call (without the CALL keyword)
Lex_ident_sys tmp(thd, &(yyvsp[0].ident_cli));
if (unlikely(!tmp.str) ||
unlikely(Lex->call_statement_start(thd, &tmp)))
MYSQL_YYABORT;
}
#line 53813 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3623:
#line 18237 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex_ident_sys tmp(thd, &(yyvsp[-2].ident_cli));
if (unlikely(!tmp.str) ||
unlikely(Lex->call_statement_start(thd, &tmp, &(yyvsp[0].ident_sys))))
MYSQL_YYABORT;
}
#line 53826 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3625:
#line 18247 "/home/buildbot/git/sql/sql_yacc.yy"
{ }
#line 53834 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3626:
#line 18251 "/home/buildbot/git/sql/sql_yacc.yy"
{ }
#line 53842 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3648:
#line 18299 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (!((yyval.spvar_definition)= Lex->row_field_name(thd, (yyvsp[0].ident_sys))))
MYSQL_YYABORT;
}
#line 53853 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3649:
#line 18307 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely((yyvsp[-1].expr_lex)->sp_while_loop_expression(thd)))
MYSQL_YYABORT;
}
#line 53864 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3650:
#line 18312 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->sp_while_loop_finalize(thd)))
MYSQL_YYABORT;
}
#line 53875 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3651:
#line 18320 "/home/buildbot/git/sql/sql_yacc.yy"
{ }
#line 53883 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3653:
#line 18330 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->spcont->block_label_declare(&(yyvsp[0].lex_str))))
MYSQL_YYABORT;
(yyval.lex_str)= (yyvsp[0].lex_str);
}
#line 53895 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3654:
#line 18339 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (yychar == YYEMPTY)
(yyval.simple_string)= (char*) YYLIP->get_cpp_ptr_rtrim();
else
(yyval.simple_string)= (char*) YYLIP->get_cpp_tok_end_rtrim();
}
#line 53908 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3655:
#line 18348 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.item) = NULL; }
#line 53916 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3656:
#line 18349 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.item) = (yyvsp[0].item); }
#line 53924 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3657:
#line 18350 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.item) = (yyvsp[0].item); }
#line 53932 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3658:
#line 18354 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.spvar_mode)= sp_variable::MODE_IN; }
#line 53940 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3660:
#line 18356 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.spvar_mode)= sp_variable::MODE_INOUT; }
#line 53948 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3661:
#line 18361 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyvsp[-2].spvar)->mode= (yyvsp[-1].spvar_mode);
if (unlikely(Lex->sp_param_fill_definition((yyvsp[-2].spvar), (yyvsp[0].Lex_field_type))))
MYSQL_YYABORT;
}
#line 53960 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3662:
#line 18367 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyvsp[-6].spvar)->mode= (yyvsp[-5].spvar_mode);
if (unlikely(Lex->sphead->spvar_fill_type_reference(thd, (yyvsp[-6].spvar), (yyvsp[-4].ident_sys), (yyvsp[-2].ident_sys))))
MYSQL_YYABORT;
}
#line 53972 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3663:
#line 18373 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyvsp[-8].spvar)->mode= (yyvsp[-7].spvar_mode);
if (unlikely(Lex->sphead->spvar_fill_type_reference(thd, (yyvsp[-8].spvar), (yyvsp[-6].ident_sys), (yyvsp[-4].ident_sys), (yyvsp[-2].ident_sys))))
MYSQL_YYABORT;
}
#line 53984 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3664:
#line 18379 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyvsp[-4].spvar)->mode= (yyvsp[-3].spvar_mode);
if (unlikely(Lex->sphead->spvar_fill_table_rowtype_reference(thd, (yyvsp[-4].spvar), (yyvsp[-2].ident_sys))))
MYSQL_YYABORT;
}
#line 53996 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3665:
#line 18385 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyvsp[-6].spvar)->mode= (yyvsp[-5].spvar_mode);
if (unlikely(Lex->sphead->spvar_fill_table_rowtype_reference(thd, (yyvsp[-6].spvar), (yyvsp[-4].ident_sys), (yyvsp[-2].ident_sys))))
MYSQL_YYABORT;
}
#line 54008 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3666:
#line 18391 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyvsp[-3].spvar)->mode= (yyvsp[-2].spvar_mode);
if (unlikely(Lex->sphead->spvar_fill_row(thd, (yyvsp[-3].spvar), (yyvsp[0].spvar_definition_list))))
MYSQL_YYABORT;
}
#line 54020 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3667:
#line 18400 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->sp_block_init(thd);
}
#line 54030 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3668:
#line 18404 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->sp_block_finalize(thd)))
MYSQL_YYABORT;
}
#line 54041 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3669:
#line 18412 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.lex)= thd->lex;
}
#line 54051 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3679:
#line 18431 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely((yyval.ident_sys).copy_keyword(thd, &(yyvsp[0].kwd))))
MYSQL_YYABORT;
}
#line 54062 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3681:
#line 18439 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.ident_cli)= (yyvsp[0].kwd); }
#line 54070 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3682:
#line 18445 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex=Lex;
lex->set_stmt_init();
if (sp_create_assignment_lex(thd, (yyvsp[-1].ident_cli).pos()))
MYSQL_YYABORT;
}
#line 54083 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3683:
#line 18452 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex_ident_sys tmp(thd, &(yyvsp[-3].ident_cli));
if (unlikely(!tmp.str) ||
unlikely(Lex->set_variable(&tmp, (yyvsp[0].item))) ||
unlikely(sp_create_assignment_instr(thd, yychar == YYEMPTY,
false)))
MYSQL_YYABORT;
}
#line 54098 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3684:
#line 18461 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex=Lex;
lex->set_stmt_init();
if (sp_create_assignment_lex(thd, (yyvsp[-3].ident_cli).pos()))
MYSQL_YYABORT;
}
#line 54111 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3685:
#line 18468 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
DBUG_ASSERT(lex->var_list.is_empty());
Lex_ident_sys tmp(thd, &(yyvsp[-5].ident_cli));
if (unlikely(!tmp.str) ||
unlikely(lex->set_variable(&tmp, &(yyvsp[-3].ident_sys), (yyvsp[0].item))) ||
unlikely(sp_create_assignment_instr(thd, yychar == YYEMPTY,
false)))
MYSQL_YYABORT;
}
#line 54128 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3686:
#line 18479 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
if (unlikely(!lex->is_trigger_new_or_old_reference(&(yyvsp[-3].ident_sys))))
{
thd->parse_error(ER_SYNTAX_ERROR, (yyvsp[-4].kwd).pos());
MYSQL_YYABORT;
}
lex->set_stmt_init();
if (sp_create_assignment_lex(thd, (yyvsp[-4].kwd).pos()))
MYSQL_YYABORT;
}
#line 54146 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3687:
#line 18491 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX_CSTRING tmp= { (yyvsp[-5].ident_sys).str, (yyvsp[-5].ident_sys).length };
if (unlikely(Lex->set_trigger_field(&tmp, &(yyvsp[-3].ident_sys), (yyvsp[0].item))) ||
unlikely(sp_create_assignment_instr(thd, yychar == YYEMPTY,
false)))
MYSQL_YYABORT;
}
#line 54160 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3688:
#line 18502 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.lex_str)= (yyvsp[0].lex_str); }
#line 54168 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3689:
#line 18503 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.lex_str)= (yyvsp[0].lex_str); }
#line 54176 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3690:
#line 18508 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->sp_push_goto_label(thd, &(yyvsp[-1].ident_sys))))
MYSQL_YYABORT;
(yyval.lex_str)= (yyvsp[-1].ident_sys);
}
#line 54188 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3691:
#line 18516 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.num)= 0; }
#line 54196 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3692:
#line 18517 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.num)= (yyvsp[0].num); }
#line 54204 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3693:
#line 18521 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.num)= 1; }
#line 54212 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3694:
#line 18522 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.num)= (yyvsp[-1].num) + 1; }
#line 54220 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3695:
#line 18527 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->sp_handler_declaration_init(thd, sp_handler::EXIT)))
MYSQL_YYABORT;
}
#line 54231 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3696:
#line 18534 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->sp_handler_declaration_finalize(thd, sp_handler::EXIT)))
MYSQL_YYABORT;
}
#line 54242 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3697:
#line 18542 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->sphead->m_param_begin= Lex->sphead->m_param_end=
YYLIP->get_cpp_tok_start() + 1;
}
#line 54253 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3702:
#line 18560 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.spname)= NULL; }
#line 54261 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3703:
#line 18561 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.spname)= (yyvsp[0].spname); }
#line 54269 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3704:
#line 18566 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.lex_str)= null_clex_str; }
#line 54277 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3705:
#line 18567 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.lex_str)= (yyvsp[0].ident_sys); }
#line 54285 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3708:
#line 18576 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.sp_instr_addr)= Lex->sphead->instructions(); }
#line 54293 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3709:
#line 18580 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->sp_block_init(thd);
}
#line 54303 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3710:
#line 18584 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->sp_block_with_exceptions_finalize_declarations(thd)))
MYSQL_YYABORT;
}
#line 54314 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3711:
#line 18590 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyvsp[-3].spblock).hndlrs+= (yyvsp[0].spblock_handlers).hndlrs;
if (unlikely(Lex->sp_block_finalize(thd, (yyvsp[-3].spblock))))
MYSQL_YYABORT;
}
#line 54326 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3713:
#line 18600 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->sp_chistics.comment= (yyvsp[0].lex_str); }
#line 54334 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3714:
#line 18602 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->sp_chistics.suid= (yyvsp[0].sp_suid); }
#line 54342 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3715:
#line 18606 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 54350 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3716:
#line 18607 "/home/buildbot/git/sql/sql_yacc.yy"
{ }
#line 54358 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3718:
#line 18612 "/home/buildbot/git/sql/sql_yacc.yy"
{ }
#line 54366 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3719:
#line 18616 "/home/buildbot/git/sql/sql_yacc.yy"
{ Lex->sp_chistics.init(); }
#line 54374 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3721:
#line 18623 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->sp_block_with_exceptions_add_empty(thd)))
MYSQL_YYABORT;
(yyval.spblock_handlers).init(0);
}
#line 54386 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3722:
#line 18628 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.spblock_handlers)= (yyvsp[-1].spblock_handlers); }
#line 54394 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3725:
#line 18640 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.spblock).join((yyvsp[-1].spblock), (yyvsp[0].spblock)); }
#line 54402 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3727:
#line 18647 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.spblock).join((yyvsp[-1].spblock), (yyvsp[0].spblock)); }
#line 54410 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3729:
#line 18654 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.spblock).join((yyvsp[-1].spblock), (yyvsp[0].spblock)); }
#line 54418 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3730:
#line 18658 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(!((yyval.lex)= new (thd->mem_root)
sp_lex_local(thd, thd->lex))))
MYSQL_YYABORT;
thd->m_parser_state->m_yacc.reset_before_substatement();
}
#line 54431 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3731:
#line 18669 "/home/buildbot/git/sql/sql_yacc.yy"
{
DBUG_ASSERT((yyvsp[-2].lex)->sphead->get_package());
(yyvsp[-1].lex)->sql_command= SQLCOM_CREATE_FUNCTION;
sp_name *spname= (yyvsp[-2].lex)->make_sp_name_package_routine(thd, &(yyvsp[0].ident_sys));
if (unlikely(!spname))
MYSQL_YYABORT;
thd->lex= (yyvsp[-1].lex);
if (unlikely(!(yyvsp[-1].lex)->make_sp_head_no_recursive(thd, spname,
&sp_handler_package_function,
NOT_AGGREGATE)))
MYSQL_YYABORT;
(yyvsp[-2].lex)->sphead->get_package()->m_current_routine= (yyvsp[-1].lex);
(void) is_native_function_with_warn(thd, &(yyvsp[0].ident_sys));
}
#line 54452 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3732:
#line 18686 "/home/buildbot/git/sql/sql_yacc.yy"
{
sp_head *sp= thd->lex->sphead;
sp->restore_thd_mem_root(thd);
thd->lex= (yyvsp[-7].lex);
(yyval.lex)= (yyvsp[-6].lex);
}
#line 54465 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3733:
#line 18696 "/home/buildbot/git/sql/sql_yacc.yy"
{
DBUG_ASSERT((yyvsp[-2].lex)->sphead->get_package());
(yyvsp[-1].lex)->sql_command= SQLCOM_CREATE_PROCEDURE;
sp_name *spname= (yyvsp[-2].lex)->make_sp_name_package_routine(thd, &(yyvsp[0].ident_sys));
if (unlikely(!spname))
MYSQL_YYABORT;
thd->lex= (yyvsp[-1].lex);
if (unlikely(!(yyvsp[-1].lex)->make_sp_head_no_recursive(thd, spname,
&sp_handler_package_procedure,
DEFAULT_AGGREGATE)))
MYSQL_YYABORT;
(yyvsp[-2].lex)->sphead->get_package()->m_current_routine= (yyvsp[-1].lex);
}
#line 54485 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3734:
#line 18711 "/home/buildbot/git/sql/sql_yacc.yy"
{
sp_head *sp= thd->lex->sphead;
sp->restore_thd_mem_root(thd);
thd->lex= (yyvsp[-5].lex);
(yyval.lex)= (yyvsp[-4].lex);
}
#line 54498 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3735:
#line 18723 "/home/buildbot/git/sql/sql_yacc.yy"
{
sp_package *pkg= Lex->get_sp_package();
if (unlikely(pkg->add_routine_implementation((yyvsp[-2].lex))))
MYSQL_YYABORT;
pkg->m_current_routine= NULL;
(yyval.spblock).init();
}
#line 54512 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3736:
#line 18732 "/home/buildbot/git/sql/sql_yacc.yy"
{
sp_package *pkg= Lex->get_sp_package();
if (unlikely(pkg->add_routine_implementation((yyvsp[-2].lex))))
MYSQL_YYABORT;
pkg->m_current_routine= NULL;
(yyval.spblock).init();
}
#line 54526 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3737:
#line 18739 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.spblock).init(); }
#line 54534 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3738:
#line 18745 "/home/buildbot/git/sql/sql_yacc.yy"
{
sp_package *pkg= Lex->get_sp_package();
sp_head *sp= pkg->m_current_routine->sphead;
thd->lex= pkg->m_current_routine;
sp->reset_thd_mem_root(thd);
sp->set_body_start(thd, YYLIP->get_cpp_tok_start());
}
#line 54548 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3739:
#line 18753 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(thd->lex->sp_body_finalize_function(thd) ||
thd->lex->sphead->check_package_routine_end_name((yyvsp[0].lex_str))))
MYSQL_YYABORT;
thd->lex= (yyvsp[-3].lex);
}
#line 54561 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3740:
#line 18763 "/home/buildbot/git/sql/sql_yacc.yy"
{
sp_package *pkg= Lex->get_sp_package();
sp_head *sp= pkg->m_current_routine->sphead;
thd->lex= pkg->m_current_routine;
sp->reset_thd_mem_root(thd);
sp->set_body_start(thd, YYLIP->get_cpp_tok_start());
}
#line 54575 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3741:
#line 18771 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(thd->lex->sp_body_finalize_procedure(thd) ||
thd->lex->sphead->check_package_routine_end_name((yyvsp[0].lex_str))))
MYSQL_YYABORT;
thd->lex= (yyvsp[-3].lex);
}
#line 54588 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3747:
#line 18796 "/home/buildbot/git/sql/sql_yacc.yy"
{
sp_package *pkg= Lex->get_sp_package();
if (unlikely(pkg->add_routine_declaration((yyvsp[-1].lex))))
MYSQL_YYABORT;
pkg->m_current_routine= NULL;
}
#line 54601 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3748:
#line 18803 "/home/buildbot/git/sql/sql_yacc.yy"
{
sp_package *pkg= Lex->get_sp_package();
if (unlikely(pkg->add_routine_declaration((yyvsp[-1].lex))))
MYSQL_YYABORT;
pkg->m_current_routine= NULL;
}
#line 54614 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3749:
#line 18815 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->sp_variable_declarations_with_ref_finalize(thd, (yyvsp[-4].num), (yyvsp[-3].qualified_column_ident), (yyvsp[0].item))))
MYSQL_YYABORT;
(yyval.spblock).init_using_vars((yyvsp[-4].num));
}
#line 54626 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3750:
#line 18823 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->sp_variable_declarations_rowtype_finalize(thd, (yyvsp[-4].num), (yyvsp[-3].qualified_column_ident), (yyvsp[0].item))))
MYSQL_YYABORT;
(yyval.spblock).init_using_vars((yyvsp[-4].num));
}
#line 54638 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3751:
#line 18832 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->sphead->spvar_fill_type_reference(thd, (yyval.spvar)= (yyvsp[-5].spvar), (yyvsp[-4].ident_sys), (yyvsp[-2].ident_sys))))
MYSQL_YYABORT;
}
#line 54649 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3752:
#line 18837 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->sphead->spvar_fill_type_reference(thd, (yyval.spvar)= (yyvsp[-7].spvar), (yyvsp[-6].ident_sys), (yyvsp[-4].ident_sys), (yyvsp[-2].ident_sys))))
MYSQL_YYABORT;
}
#line 54660 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3753:
#line 18842 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->sphead->spvar_fill_table_rowtype_reference(thd, (yyval.spvar)= (yyvsp[-3].spvar), (yyvsp[-2].ident_sys))))
MYSQL_YYABORT;
}
#line 54671 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3754:
#line 18847 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->sphead->spvar_fill_table_rowtype_reference(thd, (yyval.spvar)= (yyvsp[-5].spvar), (yyvsp[-4].ident_sys), (yyvsp[-2].ident_sys))))
MYSQL_YYABORT;
}
#line 54682 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3755:
#line 18856 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= thd->lex;
lex->sphead->set_c_chistics(lex->sp_chistics);
lex->sphead->set_body_start(thd, YYLIP->get_cpp_tok_start());
}
#line 54694 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3756:
#line 18863 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->sp_body_finalize_function(thd)))
MYSQL_YYABORT;
}
#line 54705 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3757:
#line 18871 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(!Lex->make_sp_head_no_recursive(thd, (yyvsp[0].spname),
&sp_handler_procedure,
DEFAULT_AGGREGATE)))
MYSQL_YYABORT;
}
#line 54718 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3758:
#line 18879 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->sphead->set_c_chistics(Lex->sp_chistics);
Lex->sphead->set_body_start(thd, YYLIP->get_cpp_tok_start());
}
#line 54729 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3759:
#line 18886 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->sp_body_finalize_procedure_standalone(thd, (yyvsp[0].spname))))
MYSQL_YYABORT;
}
#line 54740 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3760:
#line 18894 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (Lex->stmt_drop_function((yyvsp[-3].object_ddl_options), (yyvsp[-2].ident_sys), (yyvsp[0].ident_sys)))
MYSQL_YYABORT;
}
#line 54751 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3761:
#line 18899 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (Lex->stmt_drop_function((yyvsp[-1].object_ddl_options), (yyvsp[0].ident_sys)))
MYSQL_YYABORT;
}
#line 54762 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3762:
#line 18904 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (Lex->stmt_drop_procedure((yyvsp[-1].object_ddl_options), (yyvsp[0].spname)))
MYSQL_YYABORT;
}
#line 54773 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3763:
#line 18909 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
lex->set_command(SQLCOM_DROP_PACKAGE, (yyvsp[-1].object_ddl_options));
if (unlikely(lex->sphead))
my_yyabort_error((ER_SP_NO_DROP_SP, MYF(0), "PACKAGE"));
lex->spname= (yyvsp[0].spname);
}
#line 54787 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3764:
#line 18917 "/home/buildbot/git/sql/sql_yacc.yy"
{
LEX *lex= Lex;
lex->set_command(SQLCOM_DROP_PACKAGE_BODY, (yyvsp[-1].object_ddl_options));
if (unlikely(lex->sphead))
my_yyabort_error((ER_SP_NO_DROP_SP, MYF(0), "PACKAGE BODY"));
lex->spname= (yyvsp[0].spname);
}
#line 54801 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3765:
#line 18929 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (Lex->stmt_create_procedure_start((yyvsp[-3].object_ddl_options) | (yyvsp[0].object_ddl_options)))
MYSQL_YYABORT;
}
#line 54812 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3766:
#line 18934 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->stmt_create_routine_finalize();
}
#line 54822 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3767:
#line 18939 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (Lex->stmt_create_stored_function_start((yyvsp[-5].object_ddl_options) | (yyvsp[-1].object_ddl_options), (yyvsp[-3].sp_aggregate_type), (yyvsp[0].spname)))
MYSQL_YYABORT;
}
#line 54833 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3768:
#line 18947 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (Lex->stmt_create_stored_function_finalize_standalone((yyvsp[0].spname)))
MYSQL_YYABORT;
}
#line 54844 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3769:
#line 18953 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (Lex->stmt_create_stored_function_start((yyvsp[-5].object_ddl_options) | (yyvsp[-1].object_ddl_options), (yyvsp[-3].sp_aggregate_type), (yyvsp[0].spname)))
MYSQL_YYABORT;
}
#line 54855 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3770:
#line 18961 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (Lex->stmt_create_stored_function_finalize_standalone((yyvsp[0].spname)))
MYSQL_YYABORT;
}
#line 54866 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3771:
#line 18967 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (Lex->stmt_create_udf_function((yyvsp[-9].object_ddl_options) | (yyvsp[-5].object_ddl_options), (yyvsp[-7].sp_aggregate_type), (yyvsp[-4].ident_sys),
(Item_result) (yyvsp[-2].num), (yyvsp[0].lex_str)))
MYSQL_YYABORT;
}
#line 54878 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3772:
#line 18976 "/home/buildbot/git/sql/sql_yacc.yy"
{
sp_package *pkg;
if (unlikely(!(pkg= Lex->
create_package_start(thd,
SQLCOM_CREATE_PACKAGE,
&sp_handler_package_spec,
(yyvsp[-3].spname), (yyvsp[-7].object_ddl_options) | (yyvsp[-4].object_ddl_options)))))
MYSQL_YYABORT;
pkg->set_c_chistics(Lex->sp_chistics);
}
#line 54895 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3773:
#line 18988 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->create_package_finalize(thd, (yyvsp[-8].spname), (yyvsp[0].spname), (yyvsp[-5].simple_string), (yyvsp[-1].simple_string))))
MYSQL_YYABORT;
}
#line 54906 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3774:
#line 18996 "/home/buildbot/git/sql/sql_yacc.yy"
{
sp_package *pkg;
if (unlikely(!(pkg= Lex->
create_package_start(thd,
SQLCOM_CREATE_PACKAGE_BODY,
&sp_handler_package_body,
(yyvsp[-3].spname), (yyvsp[-8].object_ddl_options) | (yyvsp[-4].object_ddl_options)))))
MYSQL_YYABORT;
pkg->set_c_chistics(Lex->sp_chistics);
Lex->sp_block_init(thd);
}
#line 54924 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3775:
#line 19008 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->sp_block_with_exceptions_finalize_declarations(thd)))
MYSQL_YYABORT;
}
#line 54935 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3776:
#line 19013 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyvsp[-2].spblock).hndlrs+= (yyvsp[0].spblock_handlers).hndlrs;
if (unlikely(Lex->sp_block_finalize(thd, (yyvsp[-2].spblock))))
MYSQL_YYABORT;
}
#line 54947 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3777:
#line 19019 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->create_package_finalize(thd, (yyvsp[-10].spname), (yyvsp[0].spname), (yyvsp[-7].simple_string), (yyvsp[-1].simple_string))))
MYSQL_YYABORT;
}
#line 54958 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3778:
#line 19027 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.spblock).init();
}
#line 54968 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3779:
#line 19030 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.spblock)= (yyvsp[0].spblock); }
#line 54976 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3780:
#line 19035 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->sphead->sp_add_instr_cpush_for_cursors(thd, Lex->spcont)))
MYSQL_YYABORT;
}
#line 54987 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3781:
#line 19040 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.spblock).join((yyvsp[-2].spblock), (yyvsp[0].spblock));
}
#line 54997 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3783:
#line 19047 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.spblock)= (yyvsp[-1].spblock); }
#line 55005 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3784:
#line 19049 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.spblock).join((yyvsp[-2].spblock), (yyvsp[-1].spblock));
}
#line 55015 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3785:
#line 19055 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.spblock)= (yyvsp[-1].spblock); }
#line 55023 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3786:
#line 19057 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyval.spblock).join((yyvsp[-2].spblock), (yyvsp[-1].spblock));
}
#line 55033 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3787:
#line 19063 "/home/buildbot/git/sql/sql_yacc.yy"
{ (yyval.spblock).init(); }
#line 55041 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3790:
#line 19070 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->spcont->declare_condition(thd, &(yyvsp[-3].ident_sys), (yyvsp[0].spcondvalue))))
MYSQL_YYABORT;
(yyval.spblock).vars= (yyval.spblock).hndlrs= (yyval.spblock).curs= 0;
(yyval.spblock).conds= 1;
}
#line 55054 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3791:
#line 19077 "/home/buildbot/git/sql/sql_yacc.yy"
{
sp_condition_value *spcond= new (thd->mem_root)
sp_condition_value_user_defined();
if (unlikely(!spcond) ||
unlikely(Lex->spcont->declare_condition(thd, &(yyvsp[-1].ident_sys), spcond)))
MYSQL_YYABORT;
(yyval.spblock).vars= (yyval.spblock).hndlrs= (yyval.spblock).curs= 0;
(yyval.spblock).conds= 1;
}
#line 55070 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3792:
#line 19087 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->sp_block_init(thd);
}
#line 55080 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3793:
#line 19092 "/home/buildbot/git/sql/sql_yacc.yy"
{
sp_pcontext *param_ctx= Lex->spcont;
if (unlikely(Lex->sp_block_finalize(thd)))
MYSQL_YYABORT;
if (unlikely(Lex->sp_declare_cursor(thd, &(yyvsp[-4].ident_sys), (yyvsp[0].sp_cursor_stmt), param_ctx, false)))
MYSQL_YYABORT;
(yyval.spblock).vars= (yyval.spblock).conds= (yyval.spblock).hndlrs= 0;
(yyval.spblock).curs= 1;
}
#line 55096 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3799:
#line 19110 "/home/buildbot/git/sql/sql_yacc.yy"
{}
#line 55104 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3810:
#line 19124 "/home/buildbot/git/sql/sql_yacc.yy"
{ }
#line 55112 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3815:
#line 19138 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->sp_block_init(thd, &(yyvsp[-1].lex_str));
if (unlikely(Lex->sp_block_with_exceptions_finalize_declarations(thd)))
MYSQL_YYABORT;
}
#line 55124 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3816:
#line 19146 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->sp_block_finalize(thd, Lex_spblock((yyvsp[-2].spblock_handlers)), &(yyvsp[0].lex_str))))
MYSQL_YYABORT;
}
#line 55135 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3817:
#line 19152 "/home/buildbot/git/sql/sql_yacc.yy"
{
Lex->sp_block_init(thd, &(yyvsp[-1].lex_str));
}
#line 55145 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3818:
#line 19156 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->sp_block_with_exceptions_finalize_declarations(thd)))
MYSQL_YYABORT;
}
#line 55156 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3819:
#line 19164 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyvsp[-5].spblock).hndlrs+= (yyvsp[-2].spblock_handlers).hndlrs;
if (unlikely(Lex->sp_block_finalize(thd, (yyvsp[-5].spblock), &(yyvsp[0].lex_str))))
MYSQL_YYABORT;
}
#line 55168 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3822:
#line 19178 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->maybe_start_compound_statement(thd)))
MYSQL_YYABORT;
Lex->sp_block_init(thd);
if (unlikely(Lex->sp_block_with_exceptions_finalize_declarations(thd)))
MYSQL_YYABORT;
}
#line 55182 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3823:
#line 19187 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->sp_block_finalize(thd, Lex_spblock((yyvsp[-1].spblock_handlers)))))
MYSQL_YYABORT;
}
#line 55193 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3824:
#line 19192 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->maybe_start_compound_statement(thd)))
MYSQL_YYABORT;
Lex->sp_block_init(thd);
}
#line 55205 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3825:
#line 19198 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->sp_block_with_exceptions_finalize_declarations(thd)))
MYSQL_YYABORT;
}
#line 55216 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3826:
#line 19205 "/home/buildbot/git/sql/sql_yacc.yy"
{
(yyvsp[-4].spblock).hndlrs+= (yyvsp[-1].spblock_handlers).hndlrs;
if (unlikely(Lex->sp_block_finalize(thd, (yyvsp[-4].spblock))))
MYSQL_YYABORT;
}
#line 55228 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3827:
#line 19215 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->sp_block_with_exceptions_finalize_executable_section(thd, (yyvsp[-1].sp_instr_addr))))
MYSQL_YYABORT;
}
#line 55239 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
case 3828:
#line 19220 "/home/buildbot/git/sql/sql_yacc.yy"
{
if (unlikely(Lex->sp_block_with_exceptions_finalize_exceptions(thd, (yyvsp[-3].sp_instr_addr), (yyvsp[0].num))))
MYSQL_YYABORT;
(yyval.spblock_handlers).init((yyvsp[0].num));
}
#line 55251 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
break;
#line 55256 "/home/buildbot/git/mkdist/sql/yy_oracle.cc"
default: break;
}
/* User semantic actions sometimes alter yychar, and that requires
that yytoken be updated with the new translation. We take the
approach of translating immediately before every use of yytoken.
One alternative is translating here after every semantic action,
but that translation would be missed if the semantic action invokes
YYABORT, YYACCEPT, or YYERROR immediately after altering yychar or
if it invokes YYBACKUP. In the case of YYABORT or YYACCEPT, an
incorrect destructor might then be invoked immediately. In the
case of YYERROR or YYBACKUP, subsequent parser actions might lead
to an incorrect destructor call or verbose syntax error message
before the lookahead is translated. */
YY_SYMBOL_PRINT ("-> $$ =", yyr1[yyn], &yyval, &yyloc);
YYPOPSTACK (yylen);
yylen = 0;
YY_STACK_PRINT (yyss, yyssp);
*++yyvsp = yyval;
/* Now 'shift' the result of the reduction. Determine what state
that goes to, based on the state we popped back to and the rule
number reduced by. */
yyn = yyr1[yyn];
yystate = yypgoto[yyn - YYNTOKENS] + *yyssp;
if (0 <= yystate && yystate <= YYLAST && yycheck[yystate] == *yyssp)
yystate = yytable[yystate];
else
yystate = yydefgoto[yyn - YYNTOKENS];
goto yynewstate;
/*--------------------------------------.
| yyerrlab -- here on detecting error. |
`--------------------------------------*/
yyerrlab:
/* Make sure we have latest lookahead translation. See comments at
user semantic actions for why this is necessary. */
yytoken = yychar == YYEMPTY ? YYEMPTY : YYTRANSLATE (yychar);
/* If not already recovering from an error, report this error. */
if (!yyerrstatus)
{
++yynerrs;
#if ! YYERROR_VERBOSE
yyerror (thd, YY_("syntax error"));
#else
# define YYSYNTAX_ERROR yysyntax_error (&yymsg_alloc, &yymsg, \
yyssp, yytoken)
{
char const *yymsgp = YY_("syntax error");
int yysyntax_error_status;
yysyntax_error_status = YYSYNTAX_ERROR;
if (yysyntax_error_status == 0)
yymsgp = yymsg;
else if (yysyntax_error_status == 1)
{
if (yymsg != yymsgbuf)
YYSTACK_FREE (yymsg);
yymsg = (char *) YYSTACK_ALLOC (yymsg_alloc);
if (!yymsg)
{
yymsg = yymsgbuf;
yymsg_alloc = sizeof yymsgbuf;
yysyntax_error_status = 2;
}
else
{
yysyntax_error_status = YYSYNTAX_ERROR;
yymsgp = yymsg;
}
}
yyerror (thd, yymsgp);
if (yysyntax_error_status == 2)
goto yyexhaustedlab;
}
# undef YYSYNTAX_ERROR
#endif
}
if (yyerrstatus == 3)
{
/* If just tried and failed to reuse lookahead token after an
error, discard it. */
if (yychar <= YYEOF)
{
/* Return failure if at end of input. */
if (yychar == YYEOF)
YYABORT;
}
else
{
yydestruct ("Error: discarding",
yytoken, &yylval, thd);
yychar = YYEMPTY;
}
}
/* Else will try to reuse lookahead token after shifting the error
token. */
goto yyerrlab1;
/*---------------------------------------------------.
| yyerrorlab -- error raised explicitly by YYERROR. |
`---------------------------------------------------*/
yyerrorlab:
/* Pacify compilers like GCC when the user code never invokes
YYERROR and the label yyerrorlab therefore never appears in user
code. */
if (/*CONSTCOND*/ 0)
goto yyerrorlab;
/* Do not reclaim the symbols of the rule whose action triggered
this YYERROR. */
YYPOPSTACK (yylen);
yylen = 0;
YY_STACK_PRINT (yyss, yyssp);
yystate = *yyssp;
goto yyerrlab1;
/*-------------------------------------------------------------.
| yyerrlab1 -- common code for both syntax error and YYERROR. |
`-------------------------------------------------------------*/
yyerrlab1:
yyerrstatus = 3; /* Each real token shifted decrements this. */
for (;;)
{
yyn = yypact[yystate];
if (!yypact_value_is_default (yyn))
{
yyn += YYTERROR;
if (0 <= yyn && yyn <= YYLAST && yycheck[yyn] == YYTERROR)
{
yyn = yytable[yyn];
if (0 < yyn)
break;
}
}
/* Pop the current state because it cannot handle the error token. */
if (yyssp == yyss)
YYABORT;
yydestruct ("Error: popping",
yystos[yystate], yyvsp, thd);
YYPOPSTACK (1);
yystate = *yyssp;
YY_STACK_PRINT (yyss, yyssp);
}
YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN
*++yyvsp = yylval;
YY_IGNORE_MAYBE_UNINITIALIZED_END
/* Shift the error token. */
YY_SYMBOL_PRINT ("Shifting", yystos[yyn], yyvsp, yylsp);
yystate = yyn;
goto yynewstate;
/*-------------------------------------.
| yyacceptlab -- YYACCEPT comes here. |
`-------------------------------------*/
yyacceptlab:
yyresult = 0;
goto yyreturn;
/*-----------------------------------.
| yyabortlab -- YYABORT comes here. |
`-----------------------------------*/
yyabortlab:
yyresult = 1;
goto yyreturn;
#if !defined yyoverflow || YYERROR_VERBOSE
/*-------------------------------------------------.
| yyexhaustedlab -- memory exhaustion comes here. |
`-------------------------------------------------*/
yyexhaustedlab:
yyerror (thd, YY_("memory exhausted"));
yyresult = 2;
/* Fall through. */
#endif
yyreturn:
if (yychar != YYEMPTY)
{
/* Make sure we have latest lookahead translation. See comments at
user semantic actions for why this is necessary. */
yytoken = YYTRANSLATE (yychar);
yydestruct ("Cleanup: discarding lookahead",
yytoken, &yylval, thd);
}
/* Do not reclaim the symbols of the rule whose action triggered
this YYABORT or YYACCEPT. */
YYPOPSTACK (yylen);
YY_STACK_PRINT (yyss, yyssp);
while (yyssp != yyss)
{
yydestruct ("Cleanup: popping",
yystos[*yyssp], yyvsp, thd);
YYPOPSTACK (1);
}
#ifndef yyoverflow
if (yyss != yyssa)
YYSTACK_FREE (yyss);
#endif
#if YYERROR_VERBOSE
if (yymsg != yymsgbuf)
YYSTACK_FREE (yymsg);
#endif
return yyresult;
}