Engine-defined New Table/Field/Index Attributes
Explains how storage engines can define and use custom attributes for tables, fields, and indexes within the MariaDB server framework.
API
example_hton->table_options= example_table_option_array;
example_hton->field_options= example_field_option_array;
example_hton->index_options= example_index_option_array;static MYSQL_THDVAR_ULONG(varopt_default, PLUGIN_VAR_RQCMDARG,
"default value of the VAROPT table option", NULL, NULL, 5, 0, 100, 0);
struct ha_table_option_struct
{
char *strparam;
ulonglong ullparam;
uint enumparam;
bool boolparam;
ulonglong varparam;
};
ha_create_table_option example_table_option_list[]=
{
HA_TOPTION_NUMBER("NUMBER", ullparam, UINT_MAX32, 0, UINT_MAX32, 10),
HA_TOPTION_STRING("STR", strparam),
HA_TOPTION_ENUM("ONE_OR_TWO", enumparam, "one,two", 0),
HA_TOPTION_BOOL("YESNO", boolparam, 1),
HA_TOPTION_SYSVAR("VAROPT", varopt, varparam),
HA_TOPTION_END
};macro name
attribure value type
corresponding C type
additional parameters of a macro
SQL
See Also
Last updated
Was this helpful?

