MySQL  8.0.19
Source Code Documentation
com_data.h
Go to the documentation of this file.
1 /* Copyright (c) 2015, 2019, Oracle and/or its affiliates. All rights reserved.
2 
3  This program is free software; you can redistribute it and/or modify
4  it under the terms of the GNU General Public License, version 2.0,
5  as published by the Free Software Foundation.
6 
7  This program is also distributed with certain software (including
8  but not limited to OpenSSL) that is licensed under separate terms,
9  as designated in a particular file or component or in included license
10  documentation. The authors of MySQL hereby grant you an additional
11  permission to link the program and your derivative works with the
12  separately licensed software that they have included with MySQL.
13 
14  This program is distributed in the hope that it will be useful,
15  but WITHOUT ANY WARRANTY; without even the implied warranty of
16  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17  GNU General Public License, version 2.0, for more details.
18 
19  You should have received a copy of the GNU General Public License
20  along with this program; if not, write to the Free Software
21  Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */
22 #ifndef PLUGIN_PROTOCOL_INCLUDED
23 #define PLUGIN_PROTOCOL_INCLUDED
24 
25 #ifndef MYSQL_ABI_CHECK
26 #include "field_types.h" /* enum_field_types */
27 #include "mysql_com.h" /* mysql_enum_shutdown_level */
28 #endif
29 
30 /**
31  @file include/mysql/com_data.h
32  Definition of COM_DATA to be used with the Command service as data input
33  structure.
34 */
35 
37  const char *db_name;
38  unsigned long length;
39 };
40 
42  unsigned char options;
43 };
44 
45 struct COM_KILL_DATA {
46  unsigned long id;
47 };
48 
50  unsigned int opt_command;
51 };
52 
53 struct PS_PARAM {
54  unsigned char null_bit;
56  unsigned char unsigned_type;
57  const unsigned char *value;
58  unsigned long length;
59 };
60 
62  unsigned long stmt_id;
63  unsigned long open_cursor;
65  unsigned long parameter_count;
66  unsigned char has_new_types;
67 };
68 
70  unsigned long stmt_id;
71  unsigned long num_rows;
72 };
73 
75  unsigned long stmt_id;
76  unsigned int param_number;
77  unsigned char *longdata;
78  unsigned long length;
79 };
80 
82  const char *query;
83  unsigned int length;
84 };
85 
87  unsigned int stmt_id;
88 };
89 
91  unsigned int stmt_id;
92 };
93 
95  const char *query;
96  unsigned int length;
97 };
98 
100  unsigned char *table_name;
101  unsigned int table_name_length;
102  const unsigned char *query;
103  unsigned int query_length;
104 };
105 
106 union COM_DATA {
119 };
120 
121 #endif /* PLUGIN_PROTOCOL_INCLUDED */
PS_PARAM
Definition: com_data.h:53
COM_REFRESH_DATA
Definition: com_data.h:41
COM_KILL_DATA::id
unsigned long id
Definition: com_data.h:46
field_types.h
This file contains the field type.
COM_FIELD_LIST_DATA::table_name
unsigned char * table_name
Definition: com_data.h:100
COM_STMT_EXECUTE_DATA::open_cursor
unsigned long open_cursor
Definition: com_data.h:63
COM_FIELD_LIST_DATA::query
const unsigned char * query
Definition: com_data.h:102
COM_STMT_RESET_DATA
Definition: com_data.h:90
PS_PARAM::length
unsigned long length
Definition: com_data.h:58
COM_STMT_PREPARE_DATA::query
const char * query
Definition: com_data.h:82
COM_KILL_DATA
Definition: com_data.h:45
COM_FIELD_LIST_DATA::query_length
unsigned int query_length
Definition: com_data.h:103
COM_STMT_SEND_LONG_DATA_DATA::stmt_id
unsigned long stmt_id
Definition: com_data.h:75
COM_DATA::com_stmt_close
COM_STMT_CLOSE_DATA com_stmt_close
Definition: com_data.h:115
COM_STMT_EXECUTE_DATA
Definition: com_data.h:61
COM_DATA::com_stmt_reset
COM_STMT_RESET_DATA com_stmt_reset
Definition: com_data.h:116
COM_STMT_SEND_LONG_DATA_DATA::longdata
unsigned char * longdata
Definition: com_data.h:77
COM_STMT_FETCH_DATA::stmt_id
unsigned long stmt_id
Definition: com_data.h:70
PS_PARAM::value
const unsigned char * value
Definition: com_data.h:57
COM_DATA::com_set_option
COM_SET_OPTION_DATA com_set_option
Definition: com_data.h:110
COM_STMT_EXECUTE_DATA::stmt_id
unsigned long stmt_id
Definition: com_data.h:62
COM_REFRESH_DATA::options
unsigned char options
Definition: com_data.h:42
COM_STMT_CLOSE_DATA
Definition: com_data.h:86
COM_DATA::com_stmt_prepare
COM_STMT_PREPARE_DATA com_stmt_prepare
Definition: com_data.h:114
PS_PARAM::unsigned_type
unsigned char unsigned_type
Definition: com_data.h:56
COM_FIELD_LIST_DATA::table_name_length
unsigned int table_name_length
Definition: com_data.h:101
COM_INIT_DB_DATA::length
unsigned long length
Definition: com_data.h:38
PS_PARAM::null_bit
unsigned char null_bit
Definition: com_data.h:54
COM_DATA
Definition: com_data.h:106
COM_STMT_EXECUTE_DATA::parameter_count
unsigned long parameter_count
Definition: com_data.h:65
enum_field_types
enum_field_types
Column types for MySQL.
Definition: field_types.h:52
mysql_com.h
COM_STMT_FETCH_DATA
Definition: com_data.h:69
COM_SET_OPTION_DATA
Definition: com_data.h:49
COM_QUERY_DATA
Definition: com_data.h:94
COM_FIELD_LIST_DATA
Definition: com_data.h:99
COM_STMT_SEND_LONG_DATA_DATA
Definition: com_data.h:74
COM_STMT_CLOSE_DATA::stmt_id
unsigned int stmt_id
Definition: com_data.h:87
COM_DATA::com_stmt_send_long_data
COM_STMT_SEND_LONG_DATA_DATA com_stmt_send_long_data
Definition: com_data.h:113
COM_STMT_PREPARE_DATA::length
unsigned int length
Definition: com_data.h:83
PS_PARAM::type
enum enum_field_types type
Definition: com_data.h:55
COM_STMT_SEND_LONG_DATA_DATA::param_number
unsigned int param_number
Definition: com_data.h:76
COM_INIT_DB_DATA
Definition: com_data.h:36
COM_DATA::com_field_list
COM_FIELD_LIST_DATA com_field_list
Definition: com_data.h:118
COM_STMT_EXECUTE_DATA::has_new_types
unsigned char has_new_types
Definition: com_data.h:66
COM_STMT_FETCH_DATA::num_rows
unsigned long num_rows
Definition: com_data.h:71
COM_QUERY_DATA::length
unsigned int length
Definition: com_data.h:96
COM_DATA::com_refresh
COM_REFRESH_DATA com_refresh
Definition: com_data.h:108
COM_DATA::com_kill
COM_KILL_DATA com_kill
Definition: com_data.h:109
COM_DATA::com_stmt_execute
COM_STMT_EXECUTE_DATA com_stmt_execute
Definition: com_data.h:111
COM_DATA::com_query
COM_QUERY_DATA com_query
Definition: com_data.h:117
COM_INIT_DB_DATA::db_name
const char * db_name
Definition: com_data.h:37
COM_DATA::com_stmt_fetch
COM_STMT_FETCH_DATA com_stmt_fetch
Definition: com_data.h:112
COM_STMT_SEND_LONG_DATA_DATA::length
unsigned long length
Definition: com_data.h:78
COM_SET_OPTION_DATA::opt_command
unsigned int opt_command
Definition: com_data.h:50
COM_STMT_PREPARE_DATA
Definition: com_data.h:81
COM_STMT_RESET_DATA::stmt_id
unsigned int stmt_id
Definition: com_data.h:91
COM_QUERY_DATA::query
const char * query
Definition: com_data.h:95
COM_DATA::com_init_db
COM_INIT_DB_DATA com_init_db
Definition: com_data.h:107
COM_STMT_EXECUTE_DATA::parameters
PS_PARAM * parameters
Definition: com_data.h:64