MySQL  8.0.23
Source Code Documentation
ha_prototypes.h
Go to the documentation of this file.
1 /*****************************************************************************
2 
3 Copyright (c) 2006, 2020, Oracle and/or its affiliates. All Rights Reserved.
4 
5 This program is free software; you can redistribute it and/or modify it under
6 the terms of the GNU General Public License, version 2.0, as published by the
7 Free Software Foundation.
8 
9 This program is also distributed with certain software (including but not
10 limited to OpenSSL) that is licensed under separate terms, as designated in a
11 particular file or component or in included license documentation. The authors
12 of MySQL hereby grant you an additional permission to link the program and
13 your derivative works with the separately licensed software that they have
14 included with MySQL.
15 
16 This program is distributed in the hope that it will be useful, but WITHOUT
17 ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
18 FOR A PARTICULAR PURPOSE. See the GNU General Public License, version 2.0,
19 for more details.
20 
21 You should have received a copy of the GNU General Public License along with
22 this program; if not, write to the Free Software Foundation, Inc.,
23 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
24 
25 *****************************************************************************/
26 
27 /** @file include/ha_prototypes.h
28  Prototypes for global functions in ha_innodb.cc that are called by
29  InnoDB C code.
30 
31  NOTE: This header is intended to insulate InnoDB from SQL names and functions.
32  Do not include any headers other than univ.i into this unless they are very
33  simple headers.
34  ************************************************************************/
35 
36 #ifndef HA_INNODB_PROTOTYPES_H
37 #define HA_INNODB_PROTOTYPES_H
38 
39 #include "univ.i"
40 
41 /* Forward declarations */
42 class ha_innobase;
43 class THD;
44 class MDL_ticket;
45 struct CHARSET_INFO;
46 struct dict_table_t;
47 
48 /** Formats the raw data in "data" (in InnoDB on-disk format) that is of
49  type DATA_(CHAR|VARCHAR|MYSQL|VARMYSQL) using "charset_coll" and writes
50  the result to "buf". The result is converted to "system_charset_info".
51  Not more than "buf_size" bytes are written to "buf".
52  The result is always NUL-terminated (provided buf_size > 0) and the
53  number of bytes that were written to "buf" is returned (including the
54  terminating NUL).
55  @return number of bytes that were written */
56 ulint innobase_raw_format(const char *data, /*!< in: raw data */
57  ulint data_len, /*!< in: raw data length
58  in bytes */
59  ulint charset_coll, /*!< in: charset collation */
60  char *buf, /*!< out: output buffer */
61  ulint buf_size); /*!< in: output buffer size
62  in bytes */
63 
64 /** Quote a standard SQL identifier like tablespace, index or column name.
65 @param[in] file output stream
66 @param[in] trx InnoDB transaction, or NULL
67 @param[in] id identifier to quote */
68 void innobase_quote_identifier(FILE *file, trx_t *trx, const char *id);
69 
70 /** Quote an standard SQL identifier like tablespace, index or column name.
71 Return the string as an std:string object.
72 @param[in] trx InnoDB transaction, or NULL
73 @param[in] id identifier to quote
74 @return a std::string with id properly quoted. */
75 std::string innobase_quote_identifier(trx_t *trx, const char *id);
76 
77 /** Convert a table name to the MySQL system_charset_info (UTF-8).
78  @return pointer to the end of buf */
80  char *buf, /*!< out: buffer for converted identifier */
81  ulint buflen, /*!< in: length of buf, in bytes */
82  const char *id, /*!< in: table name to convert */
83  ulint idlen, /*!< in: length of id, in bytes */
84  THD *thd); /*!< in: MySQL connection thread, or NULL */
85 
86 /** Returns true if the thread is the replication thread on the slave
87  server. Used in srv_conc_enter_innodb() to determine if the thread
88  should be allowed to enter InnoDB - the replication thread is treated
89  differently than other threads. Also used in
90  srv_conc_force_exit_innodb().
91  @return true if thd is the replication thread */
92 ibool thd_is_replication_slave_thread(THD *thd); /*!< in: thread handle */
93 
94 /** Returns true if the transaction this thread is processing has edited
95  non-transactional tables. Used by the deadlock detector when deciding
96  which transaction to rollback in case of a deadlock - we try to avoid
97  rolling back transactions that have edited non-transactional tables.
98  @return true if non-transactional tables have been edited */
99 ibool thd_has_edited_nontrans_tables(THD *thd); /*!< in: thread handle */
100 
101 /** Prints info of a THD object (== user session thread) to the given file.
102 @param[in] f Output stream
103 @param[in] thd Pointer to a mysql thd object
104 @param[in] max_query_len Max query length to print, or 0 to use the default max
105 length */
106 void innobase_mysql_print_thd(FILE *f, THD *thd, uint max_query_len);
107 
108 /** Converts a MySQL type to an InnoDB type. Note that this function returns
109 the 'mtype' of InnoDB. InnoDB differentiates between MySQL's old <= 4.1
110 VARCHAR and the new true VARCHAR in >= 5.0.3 by the 'prtype'.
111 @param[out] unsigned_flag DATA_UNSIGNED if an 'unsigned type';
112 at least ENUM and SET, and unsigned integer types are 'unsigned types'
113 @param[in] f MySQL Field
114 @return DATA_BINARY, DATA_VARCHAR, ... */
115 ulint get_innobase_type_from_mysql_type(ulint *unsigned_flag, const void *f);
116 
117 /** Get the variable length bounds of the given character set.
118 @param[in] cset Mysql charset-collation code
119 @param[out] mbminlen Minimum length of a char (in bytes)
120 @param[out] mbmaxlen Maximum length of a char (in bytes) */
121 void innobase_get_cset_width(ulint cset, ulint *mbminlen, ulint *mbmaxlen);
122 
123 /** Compares NUL-terminated UTF-8 strings case insensitively.
124  @return 0 if a=b, < 0 if a < b, > 1 if a > b */
125 int innobase_strcasecmp(const char *a, /*!< in: first string to compare */
126  const char *b); /*!< in: second string to compare */
127 
128 /** Strip dir name from a full path name and return only the file name
129 @param[in] path_name full path name
130 @return file name or "null" if no file name */
131 const char *innobase_basename(const char *path_name);
132 
133 /** Returns true if the thread is executing a SELECT statement.
134  @return true if thd is executing SELECT */
135 ibool thd_is_select(const THD *thd); /*!< in: thread handle */
136 
137 /** Makes all characters in a NUL-terminated UTF-8 string lower case. */
138 void innobase_casedn_str(char *a); /*!< in/out: string to put in lower case */
139 
140 /** Makes all characters in a NUL-terminated UTF-8 path string lower case. */
141 void innobase_casedn_path(char *a); /*!< in/out: string to put in lower case */
142 
143 /** Determines the connection character set.
144  @return connection character set */
146  THD *thd); /*!< in: MySQL thread handle */
147 
148 /** Determines the current SQL statement.
149 Thread unsafe, can only be called from the thread owning the THD.
150 @param[in] thd MySQL thread handle
151 @param[out] length Length of the SQL statement
152 @return SQL statement string */
153 const char *innobase_get_stmt_unsafe(THD *thd, size_t *length);
154 
155 /** Determines the current SQL statement.
156 Thread safe, can be called from any thread as the string is copied
157 into the provided buffer.
158 @param[in] thd MySQL thread handle
159 @param[out] buf Buffer containing SQL statement
160 @param[in] buflen Length of provided buffer
161 @return Length of the SQL statement */
162 size_t innobase_get_stmt_safe(THD *thd, char *buf, size_t buflen);
163 
164 /** This function is used to find the storage length in bytes of the first n
165  characters for prefix indexes using a multibyte character set. The function
166  finds charset information and returns length of prefix_len characters in the
167  index field in bytes.
168  @return number of bytes occupied by the first n characters */
170  ulint charset_id, /*!< in: character set id */
171  ulint prefix_len, /*!< in: prefix length in bytes of the index
172  (this has to be divided by mbmaxlen to get the
173  number of CHARACTERS n in the prefix) */
174  ulint data_len, /*!< in: length of the string in bytes */
175  const char *str); /*!< in: character string */
176 
177 /** Checks sys_vars and determines if allocator should mark
178 large memory segments with MADV_DONTDUMP
179 @return true iff @@global.core_file AND
180 NOT @@global.innodb_buffer_pool_in_core_file */
182 
183 /** Make sure that core file will not be generated, as generating a core file
184 might violate our promise to not dump buffer pool data, and/or might dump not
185 the expected memory pages due to failure in using madvise */
187 
188 /** Returns the lock wait timeout for the current connection.
189  @return the lock wait timeout, in seconds */
190 ulong thd_lock_wait_timeout(THD *thd); /*!< in: thread handle, or NULL to query
191  the global innodb_lock_wait_timeout */
192 /** Add up the time waited for the lock for the current query. */
193 void thd_set_lock_wait_time(THD *thd, /*!< in/out: thread handle */
194  ulint value); /*!< in: time waited for the lock */
195 
196 /** Get the value of innodb_tmpdir.
197 @param[in] thd thread handle, or NULL to query
198  the global innodb_tmpdir.
199 @retval NULL if innodb_tmpdir="" */
200 const char *thd_innodb_tmpdir(THD *thd);
201 
202 #ifdef UNIV_DEBUG
203 /** Obtain the value of the latest output from InnoDB Interpreter/Tester
204 module (ib::Tester).
205 @param[in] thd thread handle
206 @return pointer to the output string. */
208 
209 /** Obtain the latest command executed by InnoDB Interpreter/Tester
210 module (ib::Tester).
211 @param[in] thd thread handle
212 @return pointer to the output string. */
213 char **thd_innodb_interpreter(THD *thd);
214 #endif /* UNIV_DEBUG */
215 
216 /** Get the current setting of the table_cache_size global parameter. We do
217  a dirty read because for one there is no synchronization object and
218  secondly there is little harm in doing so even if we get a torn read.
219  @return SQL statement string */
221 
222 /** Get the current setting of the lower_case_table_names global parameter from
223  mysqld.cc. We do a dirty read because for one there is no synchronization
224  object and secondly there is little harm in doing so even if we get a torn
225  read.
226  @return value of lower_case_table_names */
228 
229 /** Compare two character strings case insensitively according to their
230 charset.
231 @param[in] cs character set
232 @param[in] s1 string 1
233 @param[in] s2 string 2
234 @return 0 if the two strings are equal */
235 int innobase_nocase_compare(const void *cs, const char *s1, const char *s2);
236 
237 /** Returns true if transaction should be flagged as read-only.
238  @return true if the thd is marked as read-only */
239 bool thd_trx_is_read_only(THD *thd); /*!< in/out: thread handle */
240 
241 /**
242 Check if the transaction can be rolled back
243 @param[in] requestor Session requesting the lock
244 @param[in] holder Session that holds the lock
245 @return the session that will be rolled back, null don't care */
246 
247 THD *thd_trx_arbitrate(THD *requestor, THD *holder);
248 
249 /**
250 @param[in] thd Session to check
251 @return the priority */
252 
253 int thd_trx_priority(THD *thd);
254 
255 /** Check if the transaction is an auto-commit transaction. TRUE also
256  implies that it is a SELECT (read-only) transaction.
257  @return true if the transaction is an auto commit read-only transaction. */
258 ibool thd_trx_is_auto_commit(THD *thd); /*!< in: thread handle, or NULL */
259 
260 /** Get the thread start time.
261  @return the thread start time in seconds since the epoch. */
262 ulint thd_start_time_in_secs(THD *thd); /*!< in: thread handle, or NULL */
263 
264 /** A wrapper function of innobase_convert_name(), convert a table name
265 to the MySQL system_charset_info (UTF-8) and quote it if needed.
266 @param[out] buf Buffer for converted identifier
267 @param[in] buflen Length of buf, in bytes
268 @param[in] name Table name to format */
269 void innobase_format_name(char *buf, ulint buflen, const char *name);
270 
271 /** Corresponds to Sql_condition:enum_warning_level. */
277 };
278 
279 /** Use this when the args are first converted to a formatted string and then
280  passed to the format string from messages_to_clients.txt. The error message
281  format must be: "Some string ... %s".
282 
283  Push a warning message to the client, it is a wrapper around:
284 
285  void push_warning_printf(
286  THD *thd, Sql_condition::enum_warning_level level,
287  uint code, const char *format, ...);
288  */
289 void ib_errf(THD *thd, /*!< in/out: session */
290  ib_log_level_t level, /*!< in: warning level */
291  ib_uint32_t code, /*!< MySQL error code */
292  const char *format, /*!< printf format */
293  ...) /*!< Args */
294  MY_ATTRIBUTE((format(printf, 4, 5)));
295 
296 /** Use this when the args are passed to the format string from
297  messages_to_clients.txt directly as is.
298 
299  Push a warning message to the client, it is a wrapper around:
300 
301  void push_warning_printf(
302  THD *thd, Sql_condition::enum_warning_level level,
303  uint code, const char *format, ...);
304  */
305 void ib_senderrf(THD *thd, /*!< in/out: session */
306  ib_log_level_t level, /*!< in: warning level */
307  ib_uint32_t code, /*!< MySQL error code */
308  ...); /*!< Args */
309 
310 extern const char *TROUBLESHOOTING_MSG;
311 extern const char *TROUBLESHOOT_DATADICT_MSG;
312 extern const char *BUG_REPORT_MSG;
313 extern const char *FORCE_RECOVERY_MSG;
314 extern const char *ERROR_CREATING_MSG;
315 extern const char *OPERATING_SYSTEM_ERROR_MSG;
316 extern const char *FOREIGN_KEY_CONSTRAINTS_MSG;
317 extern const char *INNODB_PARAMETERS_MSG;
318 
319 /** Returns the NUL terminated value of glob_hostname.
320  @return pointer to glob_hostname. */
321 const char *server_get_hostname();
322 
323 /** Get the error message format string.
324  @return the format string or 0 if not found. */
325 const char *innobase_get_err_msg(int error_code); /*!< in: MySQL error code */
326 
327 /** Compute the next autoinc value.
328 
329  For MySQL replication the autoincrement values can be partitioned among
330  the nodes. The offset is the start or origin of the autoincrement value
331  for a particular node. For n nodes the increment will be n and the offset
332  will be in the interval [1, n]. The formula tries to allocate the next
333  value for a particular node.
334 
335  Note: This function is also called with increment set to the number of
336  values we want to reserve for multi-value inserts e.g.,
337 
338  INSERT INTO T VALUES(), (), ();
339 
340  innobase_next_autoinc() will be called with increment set to 3 where
341  autoinc_lock_mode != TRADITIONAL because we want to reserve 3 values for
342  the multi-value INSERT above.
343  @return the next value */
345  ulonglong current, /*!< in: Current value */
346  ulonglong need, /*!< in: count of values needed */
347  ulonglong step, /*!< in: AUTOINC increment step */
348  ulonglong offset, /*!< in: AUTOINC offset */
349  ulonglong max_value) /*!< in: max value for type */
350  MY_ATTRIBUTE((warn_unused_result));
351 
352 /**********************************************************************
353 Check if the length of the identifier exceeds the maximum allowed.
354 The input to this function is an identifier in charset my_charset_filename.
355 return true when length of identifier is too long. */
357  const char *id); /* in: identifier to check. it must belong
358  to charset my_charset_filename */
359 
360 /**********************************************************************
361 Converts an identifier from my_charset_filename to UTF-8 charset. */
363  char *to, /* out: converted identifier */
364  const char *from, /* in: identifier to convert */
365  ulint len, /* in: length of 'to', in bytes */
366  uint *errors); /* out: error return */
367 
368 /**********************************************************************
369 Converts an identifier from my_charset_filename to UTF-8 charset. */
371  char *to, /* out: converted identifier */
372  const char *from, /* in: identifier to convert */
373  ulint len); /* in: length of 'to', in bytes */
374 
375 /**********************************************************************
376 Issue a warning that the row is too big. */
377 void ib_warn_row_too_big(const dict_table_t *table);
378 
379 /** InnoDB index push-down condition check defined in ha_innodb.cc
380  @return ICP_NO_MATCH, ICP_MATCH, or ICP_OUT_OF_RANGE */
381 
382 #include <my_icp.h>
383 
385 innobase_index_cond(ha_innobase *h) /*!< in/out: pointer to ha_innobase */
386  MY_ATTRIBUTE((warn_unused_result));
387 
388 /** Gets information on the durability property requested by thread.
389  Used when writing either a prepare or commit record to the log
390  buffer.
391  @return the durability property. */
392 
393 #include <dur_prop.h>
394 
396  const THD *thd) /*!< in: thread handle */
397  MY_ATTRIBUTE((warn_unused_result));
398 
399 /** Update the system variable with the given value of the InnoDB
400 buffer pool size.
401 @param[in] buf_pool_size given value of buffer pool size.*/
402 void innodb_set_buf_pool_size(long long buf_pool_size);
403 
404 /** Gets the InnoDB transaction handle for a MySQL handler object, creates
405 an InnoDB transaction struct if the corresponding MySQL thread struct still
406 lacks one.
407 @param[in] thd MySQL thd (connection) object
408 @return InnoDB transaction handle */
409 trx_t *check_trx_exists(THD *thd);
410 
411 /** Commits a transaction in an InnoDB database.
412 @param[in] trx Transaction handle. */
413 void innobase_commit_low(trx_t *trx);
414 
415 #endif /* HA_INNODB_PROTOTYPES_H */
innobase_basename
const char * innobase_basename(const char *path_name)
Strip dir name from a full path name and return only the file name.
Definition: ha_innodb.cc:2141
THD
Definition: sql_class.h:807
INNODB_PARAMETERS_MSG
const char * INNODB_PARAMETERS_MSG
Definition: ha_innodb.cc:23352
durability_properties
durability_properties
Definition: dur_prop.h:30
innobase_convert_to_system_charset
uint innobase_convert_to_system_charset(char *to, const char *from, ulint len, uint *errors)
Definition: ha_innodb.cc:23375
innobase_quote_identifier
void innobase_quote_identifier(FILE *file, trx_t *trx, const char *id)
Quote a standard SQL identifier like tablespace, index or column name.
Definition: ha_innodb.cc:2787
thd_innodb_interpreter_output
char ** thd_innodb_interpreter_output(THD *thd)
Obtain the value of the latest output from InnoDB Interpreter/Tester module (ib::Tester).
Definition: ha_innodb.cc:22424
innobase_convert_to_filename_charset
uint innobase_convert_to_filename_charset(char *to, const char *from, ulint len)
Definition: ha_innodb.cc:23359
thd_is_replication_slave_thread
ibool thd_is_replication_slave_thread(THD *thd)
Returns true if the thread is the replication thread on the slave server.
Definition: ha_innodb.cc:1514
thd_trx_arbitrate
THD * thd_trx_arbitrate(THD *requestor, THD *holder)
Check if the transaction can be rolled back.
Definition: ha_innodb.cc:1541
ib_warn_row_too_big
void ib_warn_row_too_big(const dict_table_t *table)
Definition: ha_innodb.cc:23390
check_trx_exists
trx_t * check_trx_exists(THD *thd)
Gets the InnoDB transaction handle for a MySQL handler object, creates an InnoDB transaction struct i...
Definition: ha_innodb.cc:2551
CHARSET_INFO
Definition: m_ctype.h:354
thd_set_lock_wait_time
void thd_set_lock_wait_time(THD *thd, ulint value)
Add up the time waited for the lock for the current query.
Definition: ha_innodb.cc:1720
innobase_get_table_cache_size
ulint innobase_get_table_cache_size(void)
Get the current setting of the table_cache_size global parameter.
Definition: ha_innodb.cc:2197
thd_has_edited_nontrans_tables
ibool thd_has_edited_nontrans_tables(THD *thd)
Returns true if the transaction this thread is processing has edited non-transactional tables.
Definition: ha_innodb.cc:1669
FORCE_RECOVERY_MSG
const char * FORCE_RECOVERY_MSG
Definition: ha_innodb.cc:23336
thd_trx_is_auto_commit
ibool thd_trx_is_auto_commit(THD *thd)
Check if the transaction is an auto-commit transaction.
Definition: ha_innodb.cc:1567
TROUBLESHOOTING_MSG
const char * TROUBLESHOOTING_MSG
Definition: ha_innodb.cc:23325
thd_trx_is_read_only
bool thd_trx_is_read_only(THD *thd)
Returns true if transaction should be flagged as read-only.
Definition: ha_innodb.cc:1530
value
const string value("\"Value\"")
dict_table_t
Data structure for a database table.
Definition: dict0mem.h:1525
ERROR_CREATING_MSG
const char * ERROR_CREATING_MSG
Definition: ha_innodb.cc:23340
name
case opt name
Definition: sslopt-case.h:32
innobase_strcasecmp
int innobase_strcasecmp(const char *a, const char *b)
Compares NUL-terminated UTF-8 strings case insensitively.
Definition: ha_innodb.cc:2110
innobase_convert_name
char * innobase_convert_name(char *buf, ulint buflen, const char *id, ulint idlen, THD *thd)
Convert a table name to the MySQL system_charset_info (UTF-8).
Definition: ha_innodb.cc:2844
innobase_get_stmt_unsafe
const char * innobase_get_stmt_unsafe(THD *thd, size_t *length)
Determines the current SQL statement.
Definition: ha_innodb.cc:2174
thd_innodb_interpreter
char ** thd_innodb_interpreter(THD *thd)
Obtain the latest command executed by InnoDB Interpreter/Tester module (ib::Tester).
Definition: ha_innodb.cc:22429
IB_LOG_LEVEL_WARN
@ IB_LOG_LEVEL_WARN
Definition: ha_prototypes.h:274
innobase_format_name
void innobase_format_name(char *buf, ulint buflen, const char *name)
A wrapper function of innobase_convert_name(), convert a table name to the MySQL system_charset_info ...
Definition: ha_innodb.cc:2876
innobase_mysql_print_thd
void innobase_mysql_print_thd(FILE *f, THD *thd, uint max_query_len)
Prints info of a THD object (== user session thread) to the given file.
Definition: ha_innodb.cc:2034
innobase_casedn_str
void innobase_casedn_str(char *a)
Makes all characters in a NUL-terminated UTF-8 string lower case.
Definition: ha_innodb.cc:2150
innobase_get_charset
const CHARSET_INFO * innobase_get_charset(THD *thd)
Determines the connection character set.
Definition: ha_innodb.cc:2163
dur_prop.h
cs
Definition: commit_order_queue.h:33
innobase_disable_core_dump
void innobase_disable_core_dump()
Make sure that core file will not be generated, as generating a core file might violate our promise t...
Definition: ha_innodb.cc:1692
uint
unsigned int uint
Definition: uca-dump.cc:29
OPERATING_SYSTEM_ERROR_MSG
const char * OPERATING_SYSTEM_ERROR_MSG
Definition: ha_innodb.cc:23343
innobase_get_err_msg
const char * innobase_get_err_msg(int error_code)
Get the error message format string.
Definition: ha_innodb.cc:2048
thd_innodb_tmpdir
const char * thd_innodb_tmpdir(THD *thd)
Get the value of innodb_tmpdir.
Definition: ha_innodb.cc:1732
thd_lock_wait_timeout
ulong thd_lock_wait_timeout(THD *thd)
Returns the lock wait timeout for the current connection.
Definition: ha_innodb.cc:1711
innobase_nocase_compare
int innobase_nocase_compare(const void *cs, const char *s1, const char *s2)
Compare two character strings case insensitively according to their charset.
Definition: ha_innodb.cc:7302
thd_trx_priority
int thd_trx_priority(THD *thd)
Definition: ha_innodb.cc:1560
consts::FILE
const std::string FILE("FILE")
ib_senderrf
void ib_senderrf(THD *thd, ib_log_level_t level, ib_uint32_t code,...)
Use this when the args are passed to the format string from messages_to_clients.txt directly as is.
Definition: ha_innodb.cc:23179
buf
Definition: buf0block_hint.cc:29
innobase_index_cond
ICP_RESULT innobase_index_cond(ha_innobase *h)
InnoDB index push-down condition check defined in ha_innodb.cc.
Definition: ha_innodb.cc:22739
innobase_raw_format
ulint innobase_raw_format(const char *data, ulint data_len, ulint charset_coll, char *buf, ulint buf_size)
Formats the raw data in "data" (in InnoDB on-disk format) that is of type DATA_(CHAR|VARCHAR|MYSQL|VA...
Definition: ha_innodb.cc:2296
thd_is_select
ibool thd_is_select(const THD *thd)
Returns true if the thread is executing a SELECT statement.
Definition: ha_innodb.cc:1676
ib_log_level_t
ib_log_level_t
Corresponds to Sql_condition:enum_warning_level.
Definition: ha_prototypes.h:272
get_innobase_type_from_mysql_type
ulint get_innobase_type_from_mysql_type(ulint *unsigned_flag, const void *f)
Converts a MySQL type to an InnoDB type.
Definition: ha_innodb.cc:7450
innobase_next_autoinc
ulonglong innobase_next_autoinc(ulonglong current, ulonglong need, ulonglong step, ulonglong offset, ulonglong max_value)
Compute the next autoinc value.
Definition: ha_innodb.cc:2428
IB_LOG_LEVEL_ERROR
@ IB_LOG_LEVEL_ERROR
Definition: ha_prototypes.h:275
server_get_hostname
const char * server_get_hostname()
Returns the NUL terminated value of glob_hostname.
Definition: ha_innodb.cc:1662
innobase_check_identifier_length
bool innobase_check_identifier_length(const char *id)
Definition: ha_innodb.cc:2089
file
Definition: os0file.h:85
innobase_get_lower_case_table_names
ulint innobase_get_lower_case_table_names(void)
Get the current setting of the lower_case_table_names global parameter from mysqld....
Definition: ha_innodb.cc:2204
ha_innobase
The class defining a handle to an InnoDB table.
Definition: ha_innodb.h:79
buf_size
constexpr DWORD buf_size
Definition: create_def.cc:223
gis::length
bool length(const dd::Spatial_reference_system *srs, const Geometry *g1, double *length, bool *null) noexcept
Computes the length of linestrings and multilinestrings.
Definition: length.cc:75
ICP_RESULT
enum icp_result ICP_RESULT
Values returned by index_cond_func_xxx functions.
IB_LOG_LEVEL_INFO
@ IB_LOG_LEVEL_INFO
Definition: ha_prototypes.h:273
innobase_get_stmt_safe
size_t innobase_get_stmt_safe(THD *thd, char *buf, size_t buflen)
Determines the current SQL statement.
Definition: ha_innodb.cc:2189
BUG_REPORT_MSG
const char * BUG_REPORT_MSG
Definition: ha_innodb.cc:23333
ulonglong
unsigned long long int ulonglong
Definition: my_inttypes.h:55
innobase_casedn_path
void innobase_casedn_path(char *a)
Makes all characters in a NUL-terminated UTF-8 path string lower case.
Definition: ha_innodb.cc:2156
thd_start_time_in_secs
ulint thd_start_time_in_secs(THD *thd)
Get the thread start time.
Definition: ha_innodb.cc:1578
innodb_set_buf_pool_size
void innodb_set_buf_pool_size(long long buf_pool_size)
Update the system variable with the given value of the InnoDB buffer pool size.
Definition: ha_innodb.cc:16292
innobase_commit_low
void innobase_commit_low(trx_t *trx)
Commits a transaction in an InnoDB database.
Definition: ha_innodb.cc:5247
MDL_ticket
A granted metadata lock.
Definition: mdl.h:966
TROUBLESHOOT_DATADICT_MSG
const char * TROUBLESHOOT_DATADICT_MSG
Definition: ha_innodb.cc:23329
innobase_get_cset_width
void innobase_get_cset_width(ulint cset, ulint *mbminlen, ulint *mbmaxlen)
Get the variable length bounds of the given character set.
Definition: ha_innodb.cc:2057
innobase_get_at_most_n_mbchars
ulint innobase_get_at_most_n_mbchars(ulint charset_id, ulint prefix_len, ulint data_len, const char *str)
This function is used to find the storage length in bytes of the first n characters for prefix indexe...
Definition: ha_innodb.cc:19259
FOREIGN_KEY_CONSTRAINTS_MSG
const char * FOREIGN_KEY_CONSTRAINTS_MSG
Definition: ha_innodb.cc:23347
trx_t
Definition: trx0trx.h:836
IB_LOG_LEVEL_FATAL
@ IB_LOG_LEVEL_FATAL
Definition: ha_prototypes.h:276
innobase_should_madvise_buf_pool
bool innobase_should_madvise_buf_pool()
Checks sys_vars and determines if allocator should mark large memory segments with MADV_DONTDUMP.
Definition: ha_innodb.cc:1685
thd_requested_durability
enum durability_properties thd_requested_durability(const THD *thd)
Gets information on the durability property requested by thread.
Definition: ha_innodb.cc:1522
ib_errf
void ib_errf(THD *thd, ib_log_level_t level, ib_uint32_t code, const char *format,...)
Use this when the args are first converted to a formatted string and then passed to the format string...
Definition: ha_innodb.cc:23271