• unknown's avatar
    Made stored FUNCTION invokation work almost always. Still buggy and unstable, and · 76b037dc
    unknown authored
    various known problems, but good enough for a checkpoint commit.
    
    
    mysql-test/r/sp.result:
      New tests for invoking simple FUNCTIONs.
    mysql-test/t/sp.test:
      New tests for invoking simple FUNCTIONs.
    sql/item_func.cc:
      New Item_func_sp for stored FUNCTIONs.
    sql/item_func.h:
      New Item_func_sp for stored FUNCTIONs.
    sql/sp.cc:
      Close mysql.proc table earlier so recursive find_function calls work.
      Added temporary sp_function_exists() function for checking without parsing.
    sql/sp.h:
      Added temporary sp_function_exists() function for checking without parsing.
    sql/sp_head.cc:
      New code for executing a FUNCTION. (And reworked some of the old code in the process.)
    sql/sp_head.h:
      New code for executing a FUNCTION.
    sql/sp_rcontext.h:
      Added result slot for FUNCTIONs.
    sql/sql_lex.cc:
      Added check for stored FUNCTION, analogous to UDFs.
    sql/sql_parse.cc:
      sp_head::execute was renamed into execute_procedure.
    sql/sql_yacc.yy:
      Added parsing of stored FUNCTION invocation and code generation for RETURN statement.
    76b037dc
sql_parse.cc 120 KB