MySQL  8.0.18
Source Code Documentation
sql_tablespace.h File Reference
#include <sys/types.h>
#include "handler.h"
#include "lex_string.h"
#include "my_inttypes.h"
#include "my_sqlcommand.h"
#include "sql_cmd.h"

Go to the source code of this file.

Classes

struct  Tablespace_options
 Structure used by parser to store options for tablespace statements and pass them on to Excution classes. More...
 
class  Sql_cmd_tablespace
 Base class for tablespace execution classes including CREATE/ALTER/DROP TABLESPACE and LOGFILE GROUP commands. More...
 
class  Sql_cmd_create_tablespace
 Execution class for CREATE TABLESPACE ... More...
 
class  Sql_cmd_drop_tablespace
 Execution class for DROP TABLESPACE ... More...
 
class  Sql_cmd_alter_tablespace
 Execution class for ALTER TABLESPACE ... More...
 
class  Sql_cmd_alter_tablespace_add_datafile
 Execution class for ALTER TABLESPACE ... More...
 
class  Sql_cmd_alter_tablespace_drop_datafile
 Execution class for ALTER TABLESPACE ... More...
 
class  Sql_cmd_alter_tablespace_rename
 Execution class for ALTER TABLESPACE ... More...
 
class  Sql_cmd_create_undo_tablespace
 Execution class for CREATE UNDO TABLESPACE. More...
 
class  Sql_cmd_alter_undo_tablespace
 Execution class for ALTER UNDO TABLESPACE. More...
 
class  Sql_cmd_drop_undo_tablespace
 Execution class for DROP UNDO TABLESPACE. More...
 
class  Sql_cmd_logfile_group
 Execution class for CREATE/DROP/ALTER LOGFILE GROUP ... More...
 

Functions

bool validate_tablespace_name_length (const char *tablespace_name)
 Check if tablespace name has valid length. More...
 
bool validate_tablespace_name (ts_command_type ts_cmd, const char *tablespace_name, const handlerton *engine)
 Check if a tablespace name is valid. More...
 

Function Documentation

◆ validate_tablespace_name()

bool validate_tablespace_name ( ts_command_type  ts_cmd,
const char *  tablespace_name,
const handlerton engine 
)

Check if a tablespace name is valid.

SE specific validation is done by the SE by invoking a handlerton method.

Parameters
ts_cmdWhether this is tablespace DDL or not.
tablespace_nameName of the tablespace
engineHandlerton for the tablespace.
Return values
falseNo error encountered while checking the name.
trueError encountered and reported.

◆ validate_tablespace_name_length()

bool validate_tablespace_name_length ( const char *  tablespace_name)

Check if tablespace name has valid length.

Parameters
tablespace_nameName of the tablespace
Note
Tablespace names are not reflected in the file system, so character case conversion or consideration is not relevant.
Checking for path characters or ending space is not done. The checks are for identifier length, both in terms of number of characters and number of bytes.
Return values
falseNo error encountered while checking length.
trueError encountered and reported.