do_mysql 0.10.3-x86-mswin32-60 → 0.10.4.rc1-x86-mswin32-60
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/LICENSE +1 -1
- data/README.markdown +2 -9
- data/Rakefile +12 -45
- data/ext/do_mysql/do_common.c +526 -0
- data/ext/do_mysql/do_common.h +170 -0
- data/ext/do_mysql/do_mysql.c +200 -700
- data/ext/do_mysql/error.h +139 -263
- data/ext/do_mysql/extconf.rb +12 -14
- data/lib/do_mysql.rb +8 -3
- data/lib/do_mysql/1.8/do_mysql.so +0 -0
- data/lib/do_mysql/1.9/do_mysql.so +0 -0
- data/lib/do_mysql/version.rb +1 -1
- data/spec/command_spec.rb +3 -3
- data/spec/connection_spec.rb +17 -17
- data/spec/encoding_spec.rb +4 -4
- data/spec/error/sql_error_spec.rb +2 -2
- data/spec/reader_spec.rb +28 -2
- data/spec/result_spec.rb +5 -5
- data/spec/spec_helper.rb +14 -5
- data/spec/typecast/array_spec.rb +2 -2
- data/spec/typecast/bigdecimal_spec.rb +3 -3
- data/spec/typecast/boolean_spec.rb +3 -3
- data/spec/typecast/byte_array_spec.rb +2 -2
- data/spec/typecast/class_spec.rb +2 -2
- data/spec/typecast/date_spec.rb +3 -3
- data/spec/typecast/datetime_spec.rb +3 -3
- data/spec/typecast/float_spec.rb +3 -3
- data/spec/typecast/integer_spec.rb +2 -2
- data/spec/typecast/nil_spec.rb +4 -4
- data/spec/typecast/other_spec.rb +2 -2
- data/spec/typecast/range_spec.rb +2 -2
- data/spec/typecast/string_spec.rb +2 -2
- data/spec/typecast/time_spec.rb +2 -2
- data/tasks/compile.rake +30 -31
- data/tasks/spec.rake +8 -19
- metadata +49 -46
data/ext/do_mysql/error.h
CHANGED
@@ -1,527 +1,403 @@
|
|
1
|
-
|
2
|
-
|
3
|
-
|
4
|
-
|
5
|
-
|
1
|
+
#ifndef _DO_MYSQL_ERROR_H_
|
2
|
+
#define _DO_MYSQL_ERROR_H_
|
3
|
+
|
4
|
+
#include "do_common.h"
|
5
|
+
|
6
|
+
static struct errcodes errors[] = {
|
6
7
|
#ifdef ER_ABORTING_CONNECTION
|
7
|
-
|
8
|
-
"ER_ABORTING_CONNECTION", "ConnectionError"},
|
8
|
+
ERRCODE(ER_ABORTING_CONNECTION, "ConnectionError"),
|
9
9
|
#endif
|
10
10
|
#ifdef ER_NET_PACKET_TOO_LARGE
|
11
|
-
|
12
|
-
"ER_NET_PACKET_TOO_LARGE", "ConnectionError"},
|
11
|
+
ERRCODE(ER_NET_PACKET_TOO_LARGE, "ConnectionError"),
|
13
12
|
#endif
|
14
13
|
#ifdef ER_NET_READ_ERROR_FROM_PIPE
|
15
|
-
|
16
|
-
"ER_NET_READ_ERROR_FROM_PIPE", "ConnectionError"},
|
14
|
+
ERRCODE(ER_NET_READ_ERROR_FROM_PIPE, "ConnectionError"),
|
17
15
|
#endif
|
18
16
|
#ifdef ER_NET_FCNTL_ERROR
|
19
|
-
|
20
|
-
"ER_NET_FCNTL_ERROR", "ConnectionError"},
|
17
|
+
ERRCODE(ER_NET_FCNTL_ERROR, "ConnectionError"),
|
21
18
|
#endif
|
22
19
|
#ifdef ER_NET_PACKETS_OUT_OF_ORDER
|
23
|
-
|
24
|
-
"ER_NET_PACKETS_OUT_OF_ORDER", "ConnectionError"},
|
20
|
+
ERRCODE(ER_NET_PACKETS_OUT_OF_ORDER, "ConnectionError"),
|
25
21
|
#endif
|
26
22
|
#ifdef ER_NET_UNCOMPRESS_ERROR
|
27
|
-
|
28
|
-
"ER_NET_UNCOMPRESS_ERROR", "ConnectionError"},
|
23
|
+
ERRCODE(ER_NET_UNCOMPRESS_ERROR, "ConnectionError"),
|
29
24
|
#endif
|
30
25
|
#ifdef ER_NET_READ_ERROR
|
31
|
-
|
32
|
-
"ER_NET_READ_ERROR", "ConnectionError"},
|
26
|
+
ERRCODE(ER_NET_READ_ERROR, "ConnectionError"),
|
33
27
|
#endif
|
34
28
|
#ifdef ER_NET_READ_INTERRUPTED
|
35
|
-
|
36
|
-
"ER_NET_READ_INTERRUPTED", "ConnectionError"},
|
29
|
+
ERRCODE(ER_NET_READ_INTERRUPTED, "ConnectionError"),
|
37
30
|
#endif
|
38
31
|
#ifdef ER_NET_WRITE_INTERRUPTED
|
39
|
-
|
40
|
-
"ER_NET_WRITE_INTERRUPTED", "ConnectionError"},
|
32
|
+
ERRCODE(ER_NET_WRITE_INTERRUPTED, "ConnectionError"),
|
41
33
|
#endif
|
42
34
|
#ifdef ER_CON_COUNT_ERROR
|
43
|
-
|
44
|
-
"ER_CON_COUNT_ERROR", "ConnectionError"},
|
35
|
+
ERRCODE(ER_CON_COUNT_ERROR, "ConnectionError"),
|
45
36
|
#endif
|
46
37
|
#ifdef ER_BAD_HOST_ERROR
|
47
|
-
|
48
|
-
"ER_BAD_HOST_ERROR", "ConnectionError"},
|
38
|
+
ERRCODE(ER_BAD_HOST_ERROR, "ConnectionError"),
|
49
39
|
#endif
|
50
40
|
#ifdef ER_HANDSHAKE_ERROR
|
51
|
-
|
52
|
-
"ER_HANDSHAKE_ERROR", "ConnectionError"},
|
41
|
+
ERRCODE(ER_HANDSHAKE_ERROR, "ConnectionError"),
|
53
42
|
#endif
|
54
43
|
#ifdef ER_DBACCESS_DENIED_ERROR
|
55
|
-
|
56
|
-
"ER_DBACCESS_DENIED_ERROR", "ConnectionError"},
|
44
|
+
ERRCODE(ER_DBACCESS_DENIED_ERROR, "ConnectionError"),
|
57
45
|
#endif
|
58
46
|
#ifdef ER_ACCESS_DENIED_ERROR
|
59
|
-
|
60
|
-
"ER_ACCESS_DENIED_ERROR", "ConnectionError"},
|
47
|
+
ERRCODE(ER_ACCESS_DENIED_ERROR, "ConnectionError"),
|
61
48
|
#endif
|
62
49
|
#ifdef ER_UNKNOWN_COM_ERROR
|
63
|
-
|
64
|
-
"ER_UNKNOWN_COM_ERROR", "ConnectionError"},
|
50
|
+
ERRCODE(ER_UNKNOWN_COM_ERROR, "ConnectionError"),
|
65
51
|
#endif
|
66
52
|
#ifdef ER_SERVER_SHUTDOWN
|
67
|
-
|
68
|
-
"ER_SERVER_SHUTDOWN", "ConnectionError"},
|
53
|
+
ERRCODE(ER_SERVER_SHUTDOWN, "ConnectionError"),
|
69
54
|
#endif
|
70
55
|
#ifdef ER_FORCING_CLOSE
|
71
|
-
|
72
|
-
"ER_FORCING_CLOSE", "ConnectionError"},
|
56
|
+
ERRCODE(ER_FORCING_CLOSE, "ConnectionError"),
|
73
57
|
#endif
|
74
58
|
#ifdef ER_IPSOCK_ERROR
|
75
|
-
|
76
|
-
"ER_IPSOCK_ERROR", "ConnectionError"},
|
59
|
+
ERRCODE(ER_IPSOCK_ERROR, "ConnectionError"),
|
77
60
|
#endif
|
78
61
|
|
79
62
|
#ifdef ER_INVALID_USE_OF_NULL
|
80
|
-
|
81
|
-
"ER_INVALID_USE_OF_NULL", "DataError"},
|
63
|
+
ERRCODE(ER_INVALID_USE_OF_NULL, "DataError"),
|
82
64
|
#endif
|
83
65
|
#ifdef ER_DIVISION_BY_ZERO
|
84
|
-
|
85
|
-
"ER_DIVISION_BY_ZERO", "DataError"},
|
66
|
+
ERRCODE(ER_DIVISION_BY_ZERO, "DataError"),
|
86
67
|
#endif
|
87
68
|
#ifdef ER_ILLEGAL_VALUE_FOR_TYPE
|
88
|
-
|
89
|
-
"ER_ILLEGAL_VALUE_FOR_TYPE", "DataError"},
|
69
|
+
ERRCODE(ER_ILLEGAL_VALUE_FOR_TYPE, "DataError"),
|
90
70
|
#endif
|
91
71
|
#ifdef ER_WARN_NULL_TO_NOTNULL
|
92
|
-
|
93
|
-
"ER_WARN_NULL_TO_NOTNULL", "DataError"},
|
72
|
+
ERRCODE(ER_WARN_NULL_TO_NOTNULL, "DataError"),
|
94
73
|
#endif
|
95
74
|
#ifdef ER_WARN_DATA_OUT_OF_RANGE
|
96
|
-
|
97
|
-
"ER_WARN_DATA_OUT_OF_RANGE", "DataError"},
|
75
|
+
ERRCODE(ER_WARN_DATA_OUT_OF_RANGE, "DataError"),
|
98
76
|
#endif
|
99
77
|
#ifdef ER_WARN_TOO_MANY_RECORDS
|
100
|
-
|
101
|
-
"ER_WARN_TOO_MANY_RECORDS", "DataError"},
|
78
|
+
ERRCODE(ER_WARN_TOO_MANY_RECORDS, "DataError"),
|
102
79
|
#endif
|
103
80
|
#ifdef ER_WARN_TOO_FEW_RECORDS
|
104
|
-
|
105
|
-
"ER_WARN_TOO_FEW_RECORDS", "DataError"},
|
81
|
+
ERRCODE(ER_WARN_TOO_FEW_RECORDS, "DataError"),
|
106
82
|
#endif
|
107
83
|
#ifdef ER_TRUNCATED_WRONG_VALUE
|
108
|
-
|
109
|
-
"ER_TRUNCATED_WRONG_VALUE", "DataError"},
|
84
|
+
ERRCODE(ER_TRUNCATED_WRONG_VALUE, "DataError"),
|
110
85
|
#endif
|
111
86
|
#ifdef ER_DATETIME_FUNCTION_OVERFLOW
|
112
|
-
|
113
|
-
"ER_DATETIME_FUNCTION_OVERFLOW", "DataError"},
|
87
|
+
ERRCODE(ER_DATETIME_FUNCTION_OVERFLOW, "DataError"),
|
114
88
|
#endif
|
115
89
|
#ifdef ER_DATA_TOO_LONG
|
116
|
-
|
117
|
-
"ER_DATA_TOO_LONG", "DataError"},
|
90
|
+
ERRCODE(ER_DATA_TOO_LONG, "DataError"),
|
118
91
|
#endif
|
119
92
|
#ifdef ER_UNKNOWN_TIME_ZONE
|
120
|
-
|
121
|
-
"ER_UNKNOWN_TIME_ZONE", "DataError"},
|
93
|
+
ERRCODE(ER_UNKNOWN_TIME_ZONE, "DataError"),
|
122
94
|
#endif
|
123
95
|
#ifdef ER_INVALID_CHARACTER_STRING
|
124
|
-
|
125
|
-
"ER_INVALID_CHARACTER_STRING", "DataError"},
|
96
|
+
ERRCODE(ER_INVALID_CHARACTER_STRING, "DataError"),
|
126
97
|
#endif
|
127
98
|
#ifdef ER_WARN_INVALID_TIMESTAMP
|
128
|
-
|
129
|
-
"ER_WARN_INVALID_TIMESTAMP", "DataError"},
|
99
|
+
ERRCODE(ER_WARN_INVALID_TIMESTAMP, "DataError"),
|
130
100
|
#endif
|
131
101
|
#ifdef ER_CANT_CREATE_GEOMETRY_OBJECT
|
132
|
-
|
133
|
-
"ER_CANT_CREATE_GEOMETRY_OBJECT", "DataError"},
|
102
|
+
ERRCODE(ER_CANT_CREATE_GEOMETRY_OBJECT, "DataError"),
|
134
103
|
#endif
|
135
104
|
|
136
105
|
#ifdef ER_BAD_NULL_ERROR
|
137
|
-
|
138
|
-
"ER_BAD_NULL_ERROR", "IntegrityError"},
|
106
|
+
ERRCODE(ER_BAD_NULL_ERROR, "IntegrityError"),
|
139
107
|
#endif
|
140
108
|
#ifdef ER_NON_UNIQ_ERROR
|
141
|
-
|
142
|
-
"ER_NON_UNIQ_ERROR", "IntegrityError"},
|
109
|
+
ERRCODE(ER_NON_UNIQ_ERROR, "IntegrityError"),
|
143
110
|
#endif
|
144
111
|
#ifdef ER_DUP_KEY
|
145
|
-
|
146
|
-
"ER_DUP_KEY", "IntegrityError"},
|
112
|
+
ERRCODE(ER_DUP_KEY, "IntegrityError"),
|
147
113
|
#endif
|
148
114
|
#ifdef ER_DUP_ENTRY
|
149
|
-
|
150
|
-
"ER_DUP_ENTRY", "IntegrityError"},
|
115
|
+
ERRCODE(ER_DUP_ENTRY, "IntegrityError"),
|
151
116
|
#endif
|
152
117
|
#ifdef ER_DUP_UNIQUE
|
153
|
-
|
154
|
-
"ER_DUP_UNIQUE", "IntegrityError"},
|
118
|
+
ERRCODE(ER_DUP_UNIQUE, "IntegrityError"),
|
155
119
|
#endif
|
156
120
|
#ifdef ER_NO_REFERENCED_ROW
|
157
|
-
|
158
|
-
"ER_NO_REFERENCED_ROW", "IntegrityError"},
|
121
|
+
ERRCODE(ER_NO_REFERENCED_ROW, "IntegrityError"),
|
159
122
|
#endif
|
160
123
|
#ifdef ER_NO_REFERENCED_ROW_2
|
161
|
-
|
162
|
-
"ER_NO_REFERENCED_ROW_2", "IntegrityError"},
|
124
|
+
ERRCODE(ER_NO_REFERENCED_ROW_2, "IntegrityError"),
|
163
125
|
#endif
|
164
126
|
#ifdef ER_ROW_IS_REFERENCED
|
165
|
-
|
166
|
-
"ER_ROW_IS_REFERENCED", "IntegrityError"},
|
127
|
+
ERRCODE(ER_ROW_IS_REFERENCED, "IntegrityError"),
|
167
128
|
#endif
|
168
129
|
#ifdef ER_ROW_IS_REFERENCED_2
|
169
|
-
|
170
|
-
"ER_ROW_IS_REFERENCED_2", "IntegrityError"},
|
130
|
+
ERRCODE(ER_ROW_IS_REFERENCED_2, "IntegrityError"),
|
171
131
|
#endif
|
172
132
|
|
173
133
|
#ifdef ER_BLOB_KEY_WITHOUT_LENGTH
|
174
|
-
|
175
|
-
"ER_BLOB_KEY_WITHOUT_LENGTH", "SyntaxError"},
|
134
|
+
ERRCODE(ER_BLOB_KEY_WITHOUT_LENGTH, "SyntaxError"),
|
176
135
|
#endif
|
177
136
|
#ifdef ER_PRIMARY_CANT_HAVE_NULL
|
178
|
-
|
179
|
-
"ER_PRIMARY_CANT_HAVE_NULL", "SyntaxError"},
|
137
|
+
ERRCODE(ER_PRIMARY_CANT_HAVE_NULL, "SyntaxError"),
|
180
138
|
#endif
|
181
139
|
#ifdef ER_TOO_MANY_ROWS
|
182
|
-
|
183
|
-
"ER_TOO_MANY_ROWS", "SyntaxError"},
|
140
|
+
ERRCODE(ER_TOO_MANY_ROWS, "SyntaxError"),
|
184
141
|
#endif
|
185
142
|
#ifdef ER_REQUIRES_PRIMARY_KEY
|
186
|
-
|
187
|
-
"ER_REQUIRES_PRIMARY_KEY", "SyntaxError"},
|
143
|
+
ERRCODE(ER_REQUIRES_PRIMARY_KEY, "SyntaxError"),
|
188
144
|
#endif
|
189
145
|
#ifdef ER_CHECK_NO_SUCH_TABLE
|
190
|
-
|
191
|
-
"ER_CHECK_NO_SUCH_TABLE", "SyntaxError"},
|
146
|
+
ERRCODE(ER_CHECK_NO_SUCH_TABLE, "SyntaxError"),
|
192
147
|
#endif
|
193
148
|
#ifdef ER_CHECK_NOT_IMPLEMENTED
|
194
|
-
|
195
|
-
"ER_CHECK_NOT_IMPLEMENTED", "SyntaxError"},
|
149
|
+
ERRCODE(ER_CHECK_NOT_IMPLEMENTED, "SyntaxError"),
|
196
150
|
#endif
|
197
151
|
#ifdef ER_TOO_MANY_USER_CONNECTIONS
|
198
|
-
|
199
|
-
"ER_TOO_MANY_USER_CONNECTIONS", "SyntaxError"},
|
152
|
+
ERRCODE(ER_TOO_MANY_USER_CONNECTIONS, "SyntaxError"),
|
200
153
|
#endif
|
201
154
|
#ifdef ER_NO_PERMISSION_TO_CREATE_USER
|
202
|
-
|
203
|
-
"ER_NO_PERMISSION_TO_CREATE_USER", "SyntaxError"},
|
155
|
+
ERRCODE(ER_NO_PERMISSION_TO_CREATE_USER, "SyntaxError"),
|
204
156
|
#endif
|
205
157
|
#ifdef ER_USER_LIMIT_REACHED
|
206
|
-
|
207
|
-
"ER_USER_LIMIT_REACHED", "SyntaxError"},
|
158
|
+
ERRCODE(ER_USER_LIMIT_REACHED, "SyntaxError"),
|
208
159
|
#endif
|
209
160
|
#ifdef ER_SPECIFIC_ACCESS_DENIED_ERROR
|
210
|
-
|
211
|
-
"ER_SPECIFIC_ACCESS_DENIED_ERROR", "SyntaxError"},
|
161
|
+
ERRCODE(ER_SPECIFIC_ACCESS_DENIED_ERROR, "SyntaxError"),
|
212
162
|
#endif
|
213
163
|
#ifdef ER_NO_DEFAULT
|
214
|
-
|
215
|
-
"ER_NO_DEFAULT", "SyntaxError"},
|
164
|
+
ERRCODE(ER_NO_DEFAULT, "SyntaxError"),
|
216
165
|
#endif
|
217
166
|
#ifdef ER_WRONG_VALUE_FOR_VAR
|
218
|
-
|
219
|
-
"ER_WRONG_VALUE_FOR_VAR", "SyntaxError"},
|
167
|
+
ERRCODE(ER_WRONG_VALUE_FOR_VAR, "SyntaxError"),
|
220
168
|
#endif
|
221
169
|
#ifdef ER_WRONG_TYPE_FOR_VAR
|
222
|
-
|
223
|
-
"ER_WRONG_TYPE_FOR_VAR", "SyntaxError"},
|
170
|
+
ERRCODE(ER_WRONG_TYPE_FOR_VAR, "SyntaxError"),
|
224
171
|
#endif
|
225
172
|
#ifdef ER_CANT_USE_OPTION_HERE
|
226
|
-
|
227
|
-
"ER_CANT_USE_OPTION_HERE", "SyntaxError"},
|
173
|
+
ERRCODE(ER_CANT_USE_OPTION_HERE, "SyntaxError"),
|
228
174
|
#endif
|
229
175
|
#ifdef ER_NOT_SUPPORTED_YET
|
230
|
-
|
231
|
-
"ER_NOT_SUPPORTED_YET", "SyntaxError"},
|
176
|
+
ERRCODE(ER_NOT_SUPPORTED_YET, "SyntaxError"),
|
232
177
|
#endif
|
233
178
|
#ifdef ER_WRONG_FK_DEF
|
234
|
-
|
235
|
-
"ER_WRONG_FK_DEF", "SyntaxError"},
|
179
|
+
ERRCODE(ER_WRONG_FK_DEF, "SyntaxError"),
|
236
180
|
#endif
|
237
181
|
#ifdef ER_ILLEGAL_REFERENCE
|
238
|
-
|
239
|
-
"ER_ILLEGAL_REFERENCE", "SyntaxError"},
|
182
|
+
ERRCODE(ER_ILLEGAL_REFERENCE, "SyntaxError"),
|
240
183
|
#endif
|
241
184
|
#ifdef ER_DERIVED_MUST_HAVE_ALIAS
|
242
|
-
|
243
|
-
"ER_DERIVED_MUST_HAVE_ALIAS", "SyntaxError"},
|
185
|
+
ERRCODE(ER_DERIVED_MUST_HAVE_ALIAS, "SyntaxError"),
|
244
186
|
#endif
|
245
187
|
#ifdef ER_TABLENAME_NOT_ALLOWED_HERE
|
246
|
-
|
247
|
-
"ER_TABLENAME_NOT_ALLOWED_HERE", "SyntaxError"},
|
188
|
+
ERRCODE(ER_TABLENAME_NOT_ALLOWED_HERE, "SyntaxError"),
|
248
189
|
#endif
|
249
190
|
#ifdef ER_SPATIAL_CANT_HAVE_NULL
|
250
|
-
|
251
|
-
"ER_SPATIAL_CANT_HAVE_NULL", "SyntaxError"},
|
191
|
+
ERRCODE(ER_SPATIAL_CANT_HAVE_NULL, "SyntaxError"),
|
252
192
|
#endif
|
253
193
|
#ifdef ER_COLLATION_CHARSET_MISMATCH
|
254
|
-
|
255
|
-
"ER_COLLATION_CHARSET_MISMATCH", "SyntaxError"},
|
194
|
+
ERRCODE(ER_COLLATION_CHARSET_MISMATCH, "SyntaxError"),
|
256
195
|
#endif
|
257
196
|
#ifdef ER_WRONG_NAME_FOR_INDEX
|
258
|
-
|
259
|
-
"ER_WRONG_NAME_FOR_INDEX", "SyntaxError"},
|
197
|
+
ERRCODE(ER_WRONG_NAME_FOR_INDEX, "SyntaxError"),
|
260
198
|
#endif
|
261
199
|
#ifdef ER_WRONG_NAME_FOR_CATALOG
|
262
|
-
|
263
|
-
"ER_WRONG_NAME_FOR_CATALOG", "SyntaxError"},
|
200
|
+
ERRCODE(ER_WRONG_NAME_FOR_CATALOG, "SyntaxError"),
|
264
201
|
#endif
|
265
202
|
#ifdef ER_UNKNOWN_STORAGE_ENGINE
|
266
|
-
|
267
|
-
"ER_UNKNOWN_STORAGE_ENGINE", "SyntaxError"},
|
203
|
+
ERRCODE(ER_UNKNOWN_STORAGE_ENGINE, "SyntaxError"),
|
268
204
|
#endif
|
269
205
|
#ifdef ER_SP_ALREADY_EXISTS
|
270
|
-
|
271
|
-
"ER_SP_ALREADY_EXISTS", "SyntaxError"},
|
206
|
+
ERRCODE(ER_SP_ALREADY_EXISTS, "SyntaxError"),
|
272
207
|
#endif
|
273
208
|
#ifdef ER_SP_DOES_NOT_EXIST
|
274
|
-
|
275
|
-
"ER_SP_DOES_NOT_EXIST", "SyntaxError"},
|
209
|
+
ERRCODE(ER_SP_DOES_NOT_EXIST, "SyntaxError"),
|
276
210
|
#endif
|
277
211
|
#ifdef ER_SP_LILABEL_MISMATCH
|
278
|
-
|
279
|
-
"ER_SP_LILABEL_MISMATCH", "SyntaxError"},
|
212
|
+
ERRCODE(ER_SP_LILABEL_MISMATCH, "SyntaxError"),
|
280
213
|
#endif
|
281
214
|
#ifdef ER_SP_LABEL_REDEFINE
|
282
|
-
|
283
|
-
"ER_SP_LABEL_REDEFINE", "SyntaxError"},
|
215
|
+
ERRCODE(ER_SP_LABEL_REDEFINE, "SyntaxError"),
|
284
216
|
#endif
|
285
217
|
#ifdef ER_SP_LABEL_MISMATCH
|
286
|
-
|
287
|
-
"ER_SP_LABEL_MISMATCH", "SyntaxError"},
|
218
|
+
ERRCODE(ER_SP_LABEL_MISMATCH, "SyntaxError"),
|
288
219
|
#endif
|
289
220
|
#ifdef ER_SP_BADRETURN
|
290
|
-
|
291
|
-
"ER_SP_BADRETURN", "SyntaxError"},
|
221
|
+
ERRCODE(ER_SP_BADRETURN, "SyntaxError"),
|
292
222
|
#endif
|
293
223
|
#ifdef ER_SP_WRONG_NO_OF_ARGS
|
294
|
-
|
295
|
-
"ER_SP_WRONG_NO_OF_ARGS", "SyntaxError"},
|
224
|
+
ERRCODE(ER_SP_WRONG_NO_OF_ARGS, "SyntaxError"),
|
296
225
|
#endif
|
297
226
|
#ifdef ER_SP_COND_MISMATCH
|
298
|
-
|
299
|
-
"ER_SP_COND_MISMATCH", "SyntaxError"},
|
227
|
+
ERRCODE(ER_SP_COND_MISMATCH, "SyntaxError"),
|
300
228
|
#endif
|
301
229
|
#ifdef ER_SP_NORETURN
|
302
|
-
|
303
|
-
"ER_SP_NORETURN", "SyntaxError"},
|
230
|
+
ERRCODE(ER_SP_NORETURN, "SyntaxError"),
|
304
231
|
#endif
|
305
232
|
#ifdef ER_SP_BAD_CURSOR_QUERY
|
306
|
-
|
307
|
-
"ER_SP_BAD_CURSOR_QUERY", "SyntaxError"},
|
233
|
+
ERRCODE(ER_SP_BAD_CURSOR_QUERY, "SyntaxError"),
|
308
234
|
#endif
|
309
235
|
#ifdef ER_SP_BAD_CURSOR_SELECT
|
310
|
-
|
311
|
-
"ER_SP_BAD_CURSOR_SELECT", "SyntaxError"},
|
236
|
+
ERRCODE(ER_SP_BAD_CURSOR_SELECT, "SyntaxError"),
|
312
237
|
#endif
|
313
238
|
#ifdef ER_SP_CURSOR_MISMATCH
|
314
|
-
|
315
|
-
"ER_SP_CURSOR_MISMATCH", "SyntaxError"},
|
239
|
+
ERRCODE(ER_SP_CURSOR_MISMATCH, "SyntaxError"),
|
316
240
|
#endif
|
317
241
|
#ifdef ER_SP_UNDECLARED_VAR
|
318
|
-
|
319
|
-
"ER_SP_UNDECLARED_VAR", "SyntaxError"},
|
242
|
+
ERRCODE(ER_SP_UNDECLARED_VAR, "SyntaxError"),
|
320
243
|
#endif
|
321
244
|
#ifdef ER_SP_DUP_PARAM
|
322
|
-
|
323
|
-
"ER_SP_DUP_PARAM", "SyntaxError"},
|
245
|
+
ERRCODE(ER_SP_DUP_PARAM, "SyntaxError"),
|
324
246
|
#endif
|
325
247
|
#ifdef ER_SP_DUP_VAR
|
326
|
-
|
327
|
-
"ER_SP_DUP_VAR", "SyntaxError"},
|
248
|
+
ERRCODE(ER_SP_DUP_VAR, "SyntaxError"),
|
328
249
|
#endif
|
329
250
|
#ifdef ER_SP_DUP_COND
|
330
|
-
|
331
|
-
"ER_SP_DUP_COND", "SyntaxError"},
|
251
|
+
ERRCODE(ER_SP_DUP_COND, "SyntaxError"),
|
332
252
|
#endif
|
333
253
|
#ifdef ER_SP_DUP_CURS
|
334
|
-
|
335
|
-
"ER_SP_DUP_CURS", "SyntaxError"},
|
254
|
+
ERRCODE(ER_SP_DUP_CURS, "SyntaxError"),
|
336
255
|
#endif
|
337
256
|
#ifdef ER_SP_VARCOND_AFTER_CURSHNDLR
|
338
|
-
|
339
|
-
"ER_SP_VARCOND_AFTER_CURSHNDLR", "SyntaxError"},
|
257
|
+
ERRCODE(ER_SP_VARCOND_AFTER_CURSHNDLR, "SyntaxError"),
|
340
258
|
#endif
|
341
259
|
#ifdef ER_SP_CURSOR_AFTER_HANDLER
|
342
|
-
|
343
|
-
"ER_SP_CURSOR_AFTER_HANDLER", "SyntaxError"},
|
260
|
+
ERRCODE(ER_SP_CURSOR_AFTER_HANDLER, "SyntaxError"),
|
344
261
|
#endif
|
345
262
|
#ifdef ER_SP_CASE_NOT_FOUND
|
346
|
-
|
347
|
-
"ER_SP_CASE_NOT_FOUND", "SyntaxError"},
|
263
|
+
ERRCODE(ER_SP_CASE_NOT_FOUND, "SyntaxError"),
|
348
264
|
#endif
|
349
265
|
#ifdef ER_PROCACCESS_DENIED_ERROR
|
350
|
-
|
351
|
-
"ER_PROCACCESS_DENIED_ERROR", "SyntaxError"},
|
266
|
+
ERRCODE(ER_PROCACCESS_DENIED_ERROR, "SyntaxError"),
|
352
267
|
#endif
|
353
268
|
#ifdef ER_NONEXISTING_PROC_GRANT
|
354
|
-
|
355
|
-
"ER_NONEXISTING_PROC_GRANT", "SyntaxError"},
|
269
|
+
ERRCODE(ER_NONEXISTING_PROC_GRANT, "SyntaxError"),
|
356
270
|
#endif
|
357
271
|
#ifdef ER_SP_BAD_SQLSTATE
|
358
|
-
|
359
|
-
"ER_SP_BAD_SQLSTATE", "SyntaxError"},
|
272
|
+
ERRCODE(ER_SP_BAD_SQLSTATE, "SyntaxError"),
|
360
273
|
#endif
|
361
274
|
#ifdef ER_CANT_CREATE_USER_WITH_GRANT
|
362
|
-
|
363
|
-
"ER_CANT_CREATE_USER_WITH_GRANT", "SyntaxError"},
|
275
|
+
ERRCODE(ER_CANT_CREATE_USER_WITH_GRANT, "SyntaxError"),
|
364
276
|
#endif
|
365
277
|
#ifdef ER_SP_DUP_HANDLER
|
366
|
-
|
367
|
-
"ER_SP_DUP_HANDLER", "SyntaxError"},
|
278
|
+
ERRCODE(ER_SP_DUP_HANDLER, "SyntaxError"),
|
368
279
|
#endif
|
369
280
|
#ifdef ER_SP_NOT_VAR_ARG
|
370
|
-
|
371
|
-
"ER_SP_NOT_VAR_ARG", "SyntaxError"},
|
281
|
+
ERRCODE(ER_SP_NOT_VAR_ARG, "SyntaxError"),
|
372
282
|
#endif
|
373
283
|
#ifdef ER_TOO_BIG_SCALE
|
374
|
-
|
375
|
-
"ER_TOO_BIG_SCALE", "SyntaxError"},
|
284
|
+
ERRCODE(ER_TOO_BIG_SCALE, "SyntaxError"),
|
376
285
|
#endif
|
377
286
|
#ifdef ER_TOO_BIG_PRECISION
|
378
|
-
|
379
|
-
"ER_TOO_BIG_PRECISION", "SyntaxError"},
|
287
|
+
ERRCODE(ER_TOO_BIG_PRECISION, "SyntaxError"),
|
380
288
|
#endif
|
381
289
|
#ifdef ER_M_BIGGER_THAN_D
|
382
|
-
|
383
|
-
"ER_M_BIGGER_THAN_D", "SyntaxError"},
|
290
|
+
ERRCODE(ER_M_BIGGER_THAN_D, "SyntaxError"),
|
384
291
|
#endif
|
385
292
|
#ifdef ER_TOO_LONG_BODY
|
386
|
-
|
387
|
-
"ER_TOO_LONG_BODY", "SyntaxError"},
|
293
|
+
ERRCODE(ER_TOO_LONG_BODY, "SyntaxError"),
|
388
294
|
#endif
|
389
295
|
#ifdef ER_TOO_BIG_DISPLAYWIDTH
|
390
|
-
|
391
|
-
"ER_TOO_BIG_DISPLAYWIDTH", "SyntaxError"},
|
296
|
+
ERRCODE(ER_TOO_BIG_DISPLAYWIDTH, "SyntaxError"),
|
392
297
|
#endif
|
393
298
|
#ifdef ER_SP_BAD_VAR_SHADOW
|
394
|
-
|
395
|
-
"ER_SP_BAD_VAR_SHADOW", "SyntaxError"},
|
299
|
+
ERRCODE(ER_SP_BAD_VAR_SHADOW, "SyntaxError"),
|
396
300
|
#endif
|
397
301
|
#ifdef ER_SP_WRONG_NAME
|
398
|
-
|
399
|
-
"ER_SP_WRONG_NAME", "SyntaxError"},
|
302
|
+
ERRCODE(ER_SP_WRONG_NAME, "SyntaxError"),
|
400
303
|
#endif
|
401
304
|
#ifdef ER_SP_NO_AGGREGATE
|
402
|
-
|
403
|
-
"ER_SP_NO_AGGREGATE", "SyntaxError"},
|
305
|
+
ERRCODE(ER_SP_NO_AGGREGATE, "SyntaxError"),
|
404
306
|
#endif
|
405
307
|
#ifdef ER_MAX_PREPARED_STMT_COUNT_REACHED
|
406
|
-
|
407
|
-
"ER_MAX_PREPARED_STMT_COUNT_REACHED", "SyntaxError"},
|
308
|
+
ERRCODE(ER_MAX_PREPARED_STMT_COUNT_REACHED, "SyntaxError"),
|
408
309
|
#endif
|
409
310
|
#ifdef ER_NON_GROUPING_FIELD_USED
|
410
|
-
|
411
|
-
"ER_NON_GROUPING_FIELD_USED", "SyntaxError"},
|
311
|
+
ERRCODE(ER_NON_GROUPING_FIELD_USED, "SyntaxError"),
|
412
312
|
#endif
|
413
313
|
#ifdef ER_BAD_DB_ERROR
|
414
|
-
|
415
|
-
"ER_BAD_DB_ERROR", "SyntaxError"},
|
314
|
+
ERRCODE(ER_BAD_DB_ERROR, "SyntaxError"),
|
416
315
|
#endif
|
417
316
|
#ifdef ER_TABLE_EXISTS_ERROR
|
418
|
-
|
419
|
-
"ER_TABLE_EXISTS_ERROR", "SyntaxError"},
|
317
|
+
ERRCODE(ER_TABLE_EXISTS_ERROR, "SyntaxError"),
|
420
318
|
#endif
|
421
319
|
#ifdef ER_BAD_TABLE_ERROR
|
422
|
-
|
423
|
-
"ER_BAD_TABLE_ERROR", "SyntaxError"},
|
320
|
+
ERRCODE(ER_BAD_TABLE_ERROR, "SyntaxError"),
|
424
321
|
#endif
|
425
322
|
#ifdef ER_NO_SUCH_TABLE
|
426
|
-
|
427
|
-
"ER_NO_SUCH_TABLE", "SyntaxError"},
|
323
|
+
ERRCODE(ER_NO_SUCH_TABLE, "SyntaxError"),
|
428
324
|
#endif
|
429
325
|
#ifdef ER_NONEXISTING_TABLE_GRANT
|
430
|
-
|
431
|
-
"ER_NONEXISTING_TABLE_GRANT", "SyntaxError"},
|
326
|
+
ERRCODE(ER_NONEXISTING_TABLE_GRANT, "SyntaxError"),
|
432
327
|
#endif
|
433
328
|
#ifdef ER_GRANT_WRONG_HOST_OR_USER
|
434
|
-
|
435
|
-
"ER_GRANT_WRONG_HOST_OR_USER", "SyntaxError"},
|
329
|
+
ERRCODE(ER_GRANT_WRONG_HOST_OR_USER, "SyntaxError"),
|
436
330
|
#endif
|
437
331
|
#ifdef ER_ILLEGAL_GRANT_FOR_TABLE
|
438
|
-
|
439
|
-
"ER_ILLEGAL_GRANT_FOR_TABLE", "SyntaxError"},
|
332
|
+
ERRCODE(ER_ILLEGAL_GRANT_FOR_TABLE, "SyntaxError"),
|
440
333
|
#endif
|
441
334
|
#ifdef ER_COLUMNACCESS_DENIED_ERROR
|
442
|
-
|
443
|
-
"ER_COLUMNACCESS_DENIED_ERROR", "SyntaxError"},
|
335
|
+
ERRCODE(ER_COLUMNACCESS_DENIED_ERROR, "SyntaxError"),
|
444
336
|
#endif
|
445
337
|
#ifdef ER_TABLEACCESS_DENIED_ERROR
|
446
|
-
|
447
|
-
"ER_TABLEACCESS_DENIED_ERROR", "SyntaxError"},
|
338
|
+
ERRCODE(ER_TABLEACCESS_DENIED_ERROR, "SyntaxError"),
|
448
339
|
#endif
|
449
340
|
#ifdef ER_NONEXISTING_GRANT
|
450
|
-
|
451
|
-
"ER_NONEXISTING_GRANT", "SyntaxError"},
|
341
|
+
ERRCODE(ER_NONEXISTING_GRANT, "SyntaxError"),
|
452
342
|
#endif
|
453
343
|
#ifdef ER_MIX_OF_GROUP_FUNC_AND_FIELDS
|
454
|
-
|
455
|
-
"ER_MIX_OF_GROUP_FUNC_AND_FIELDS", "SyntaxError"},
|
344
|
+
ERRCODE(ER_MIX_OF_GROUP_FUNC_AND_FIELDS, "SyntaxError"),
|
456
345
|
#endif
|
457
346
|
#ifdef ER_REGEXP_ERROR
|
458
|
-
|
459
|
-
"ER_REGEXP_ERROR", "SyntaxError"},
|
347
|
+
ERRCODE(ER_REGEXP_ERROR, "SyntaxError"),
|
460
348
|
#endif
|
461
349
|
#ifdef ER_NOT_ALLOWED_COMMAND
|
462
|
-
|
463
|
-
"ER_NOT_ALLOWED_COMMAND", "SyntaxError"},
|
350
|
+
ERRCODE(ER_NOT_ALLOWED_COMMAND, "SyntaxError"),
|
464
351
|
#endif
|
465
352
|
#ifdef ER_SYNTAX_ERROR
|
466
|
-
|
467
|
-
"ER_SYNTAX_ERROR", "SyntaxError"},
|
353
|
+
ERRCODE(ER_SYNTAX_ERROR, "SyntaxError"),
|
468
354
|
#endif
|
469
355
|
#ifdef ER_WRONG_NUMBER_OF_COLUMNS_IN_SELECT
|
470
|
-
|
471
|
-
"ER_WRONG_NUMBER_OF_COLUMNS_IN_SELECT", "SyntaxError"},
|
356
|
+
ERRCODE(ER_WRONG_NUMBER_OF_COLUMNS_IN_SELECT, "SyntaxError"),
|
472
357
|
#endif
|
473
358
|
|
474
359
|
#ifdef ER_CANT_DO_THIS_DURING_AN_TRANSACTION
|
475
|
-
|
476
|
-
"ER_CANT_DO_THIS_DURING_AN_TRANSACTION", "TransactionError"},
|
360
|
+
ERRCODE(ER_CANT_DO_THIS_DURING_AN_TRANSACTION, "TransactionError"),
|
477
361
|
#endif
|
478
362
|
#ifdef ER_ERROR_DURING_COMMIT
|
479
|
-
|
480
|
-
"ER_ERROR_DURING_COMMIT", "TransactionError"},
|
363
|
+
ERRCODE(ER_ERROR_DURING_COMMIT, "TransactionError"),
|
481
364
|
#endif
|
482
365
|
#ifdef ER_ERROR_DURING_ROLLBACK
|
483
|
-
|
484
|
-
"ER_ERROR_DURING_ROLLBACK", "TransactionError"},
|
366
|
+
ERRCODE(ER_ERROR_DURING_ROLLBACK, "TransactionError"),
|
485
367
|
#endif
|
486
368
|
#ifdef ER_ERROR_DURING_CHECKPOINT
|
487
|
-
|
488
|
-
"ER_ERROR_DURING_CHECKPOINT", "TransactionError"},
|
369
|
+
ERRCODE(ER_ERROR_DURING_CHECKPOINT, "TransactionError"),
|
489
370
|
#endif
|
490
371
|
#ifdef ER_LOCK_DEADLOCK
|
491
|
-
|
492
|
-
"ER_LOCK_DEADLOCK", "TransactionError"},
|
372
|
+
ERRCODE(ER_LOCK_DEADLOCK, "TransactionError"),
|
493
373
|
#endif
|
494
374
|
#ifdef ER_XAER_NOTA
|
495
|
-
|
496
|
-
|
375
|
+
ERRCODE(ER_XAER_NOTA,
|
376
|
+
"TransactionError"),
|
497
377
|
#endif
|
498
378
|
#ifdef ER_XAER_INVAL
|
499
|
-
|
500
|
-
|
379
|
+
ERRCODE(ER_XAER_INVAL,
|
380
|
+
"TransactionError"),
|
501
381
|
#endif
|
502
382
|
#ifdef ER_XAER_RMFAIL
|
503
|
-
|
504
|
-
"ER_XAER_RMFAIL", "TransactionError"},
|
383
|
+
ERRCODE(ER_XAER_RMFAIL, "TransactionError"),
|
505
384
|
#endif
|
506
385
|
#ifdef ER_XAER_OUTSIDE
|
507
|
-
|
508
|
-
"ER_XAER_OUTSIDE", "TransactionError"},
|
386
|
+
ERRCODE(ER_XAER_OUTSIDE, "TransactionError"),
|
509
387
|
#endif
|
510
388
|
#ifdef ER_XAER_RMERR
|
511
|
-
|
512
|
-
"ER_XAER_RMERR", "TransactionError"},
|
389
|
+
ERRCODE(ER_XAER_RMERR, "TransactionError"),
|
513
390
|
#endif
|
514
391
|
#ifdef ER_XA_RBROLLBACK
|
515
|
-
|
516
|
-
"ER_XA_RBROLLBACK", "TransactionError"},
|
392
|
+
ERRCODE(ER_XA_RBROLLBACK, "TransactionError"),
|
517
393
|
#endif
|
518
394
|
#ifdef ER_XA_RBTIMEOUT
|
519
|
-
|
520
|
-
"ER_XA_RBTIMEOUT", "TransactionError"},
|
395
|
+
ERRCODE(ER_XA_RBTIMEOUT, "TransactionError"),
|
521
396
|
#endif
|
522
397
|
#ifdef ER_XA_RBDEADLOCK
|
523
|
-
|
524
|
-
"ER_XA_RBDEADLOCK", "TransactionError"},
|
398
|
+
ERRCODE(ER_XA_RBDEADLOCK, "TransactionError"),
|
525
399
|
#endif
|
526
400
|
{0, NULL, NULL}
|
527
401
|
};
|
402
|
+
|
403
|
+
#endif
|