sql-parser-vlad 0.0.3

Sign up to get free protection for your applications and to get access to all the features.
@@ -0,0 +1,1598 @@
1
+ #
2
+ # DO NOT MODIFY!!!!
3
+ # This file is automatically generated by Racc 1.4.12
4
+ # from Racc grammer file "".
5
+ #
6
+
7
+ require 'racc/parser.rb'
8
+
9
+ require File.dirname(__FILE__) + '/parser.rex.rb'
10
+
11
+ module SQLParser
12
+ class Parser < Racc::Parser
13
+
14
+ module_eval(<<'...end parser.racc/module_eval...', 'parser.racc', 335)
15
+
16
+ def self.parse(sql)
17
+ new.scan_str(sql)
18
+ end
19
+ ...end parser.racc/module_eval...
20
+ ##### State transition tables begin ###
21
+
22
+ racc_action_table = [
23
+ 47, 224, 97, 154, 144, 97, 235, 102, 8, 76,
24
+ 109, 63, 236, 146, 135, 147, 71, 226, 47, 227,
25
+ 228, 31, 148, 103, 149, 105, 106, 161, 107, 108,
26
+ 217, 218, 73, 194, 158, 21, 47, 73, 73, 31,
27
+ 73, 150, 77, 50, 51, 73, 35, 48, 39, 41,
28
+ 42, 43, 44, 21, 52, 153, 55, 50, 51, 115,
29
+ 7, 50, 51, 8, 35, 48, 39, 41, 42, 43,
30
+ 44, 21, 52, 47, 55, 73, 31, 102, -129, 50,
31
+ 51, 8, 35, 48, 39, 41, 42, 43, 44, 174,
32
+ 52, 47, 55, 103, 31, 105, 106, 175, 107, 108,
33
+ 13, 14, 15, 17, 91, 90, 139, 140, 21, -129,
34
+ -129, -129, 74, 75, 176, 177, 50, 51, 178, 35,
35
+ 48, 39, 41, 42, 43, 44, 21, 52, 47, 55,
36
+ 179, 31, 180, 69, 50, 51, 8, 35, 48, 39,
37
+ 41, 42, 43, 44, 182, 52, 47, 55, 183, 229,
38
+ 69, 63, 63, 189, 190, 69, 194, 206, 209, 92,
39
+ 212, 213, 89, 21, 47, 21, 223, 229, 88, 123,
40
+ 87, 50, 51, -148, 35, 48, 39, 41, 42, 43,
41
+ 44, 21, 52, 231, 55, 86, 85, 84, 83, 50,
42
+ 51, 82, 35, 48, 39, 41, 42, 43, 44, 21,
43
+ 52, 81, 55, 8, -85, 70, 69, 50, 51, 246,
44
+ 35, 48, 39, 41, 42, 43, 44, 102, 52, 47,
45
+ 55, 100, 31, 194, 247, 101, 209, 63, 231, 57,
46
+ 56, 17, 251, 103, 12, 105, 106, 47, 107, 108,
47
+ 31, 253, 194, 73, 21, 258, 11, 260, 261, 17,
48
+ 262, 9, 123, 73, 21, 131, 73, 136, 137, 101,
49
+ 63, nil, 50, 51, nil, 35, 48, 39, 41, 42,
50
+ 43, 44, 21, 52, 47, 55, nil, 154, nil, nil,
51
+ 50, 51, nil, 35, 48, 39, 41, 42, 43, 44,
52
+ nil, 52, 47, 55, nil, 31, nil, nil, nil, nil,
53
+ nil, 161, nil, nil, 17, nil, nil, nil, 158, 21,
54
+ 47, nil, nil, 31, nil, nil, nil, 50, 51, nil,
55
+ 35, 48, 39, 41, 42, 43, 44, 21, 52, nil,
56
+ 55, nil, nil, nil, 47, 50, 51, 229, 35, 48,
57
+ 39, 41, 42, 43, 44, 21, 52, nil, 55, nil,
58
+ nil, nil, nil, 50, 51, nil, 35, 48, 39, 41,
59
+ 42, 43, 44, nil, 52, 47, 55, nil, 154, 21,
60
+ nil, nil, nil, nil, nil, nil, nil, 50, 51, nil,
61
+ 35, 48, 39, 41, 42, 43, 44, nil, 52, nil,
62
+ 55, 47, 161, nil, 31, nil, nil, nil, nil, 158,
63
+ 21, nil, nil, nil, nil, nil, nil, nil, 50, 51,
64
+ nil, 35, 48, 39, 41, 42, 43, 44, nil, 52,
65
+ 47, 55, nil, 31, nil, nil, 21, nil, nil, nil,
66
+ nil, nil, nil, nil, 50, 51, nil, 35, 48, 39,
67
+ 41, 42, 43, 44, nil, 52, 47, 55, nil, 31,
68
+ nil, nil, nil, nil, nil, 21, nil, nil, nil, nil,
69
+ nil, nil, nil, 50, 51, nil, 35, 48, 39, 41,
70
+ 42, 43, 44, nil, 52, 47, 55, nil, 31, nil,
71
+ nil, 21, nil, nil, nil, nil, nil, nil, nil, 50,
72
+ 51, nil, 35, 48, 39, 41, 42, 43, 44, nil,
73
+ 52, 47, 55, nil, 31, nil, nil, nil, nil, nil,
74
+ 21, nil, nil, nil, nil, nil, nil, nil, 50, 51,
75
+ nil, 35, 48, 39, 41, 42, 43, 44, nil, 52,
76
+ 47, 55, nil, 31, nil, nil, 21, nil, nil, nil,
77
+ nil, nil, nil, nil, 50, 51, nil, 35, 48, 39,
78
+ 41, 42, 43, 44, nil, 52, 47, 55, nil, 31,
79
+ nil, nil, nil, nil, nil, 21, nil, nil, nil, nil,
80
+ nil, nil, nil, 50, 51, nil, 35, 48, 39, 41,
81
+ 42, 43, 44, nil, 52, 47, 55, nil, 229, nil,
82
+ nil, 21, nil, nil, nil, nil, nil, nil, nil, 50,
83
+ 51, nil, 35, 48, 39, 41, 42, 43, 44, nil,
84
+ 52, 47, 55, nil, 31, nil, nil, nil, nil, nil,
85
+ 21, nil, nil, nil, nil, nil, nil, nil, 50, 51,
86
+ nil, 35, 48, 39, 41, 42, 43, 44, nil, 52,
87
+ 47, 55, nil, 31, nil, nil, 21, nil, nil, nil,
88
+ nil, nil, nil, nil, nil, nil, nil, 35, 48, 39,
89
+ 41, 42, 43, 44, nil, 52, 47, 55, nil, 229,
90
+ nil, nil, nil, nil, nil, 21, nil, nil, nil, nil,
91
+ nil, nil, nil, 50, 51, nil, 35, 48, 39, 41,
92
+ 42, 43, 44, nil, 52, 47, 55, nil, 229, nil,
93
+ nil, 21, nil, nil, nil, nil, nil, nil, nil, 50,
94
+ 51, nil, 35, 48, 39, 41, 42, 43, 44, nil,
95
+ 52, 47, 55, nil, 229, nil, nil, nil, nil, nil,
96
+ 21, nil, nil, nil, nil, nil, nil, nil, 50, 51,
97
+ nil, 35, 48, 39, 41, 42, 43, 44, nil, 52,
98
+ 47, 55, nil, 229, nil, nil, 21, nil, nil, nil,
99
+ nil, nil, nil, nil, 50, 51, nil, 35, 48, 39,
100
+ 41, 42, 43, 44, nil, 52, 47, 55, nil, 229,
101
+ nil, nil, nil, nil, nil, 21, nil, nil, nil, nil,
102
+ nil, nil, nil, 50, 51, nil, 35, 48, 39, 41,
103
+ 42, 43, 44, nil, 52, 47, 55, nil, 229, nil,
104
+ nil, 21, nil, nil, nil, nil, nil, nil, nil, 50,
105
+ 51, nil, 35, 48, 39, 41, 42, 43, 44, nil,
106
+ 52, 47, 55, nil, 229, nil, nil, nil, nil, nil,
107
+ 21, nil, nil, nil, nil, nil, nil, nil, 50, 51,
108
+ nil, 35, 48, 39, 41, 42, 43, 44, nil, 52,
109
+ nil, 55, 47, nil, nil, 154, 21, nil, nil, nil,
110
+ nil, nil, nil, nil, 50, 51, nil, 35, 48, 39,
111
+ 41, 42, 43, 44, nil, 52, nil, 55, 47, 161,
112
+ nil, 154, nil, nil, nil, nil, 158, 21, nil, nil,
113
+ nil, nil, nil, nil, nil, 50, 51, nil, 35, 48,
114
+ 39, 41, 42, 43, 44, 161, 52, 47, 55, nil,
115
+ 31, nil, 158, 21, nil, nil, nil, nil, nil, nil,
116
+ nil, 50, 51, nil, 35, 48, 39, 41, 42, 43,
117
+ 44, nil, 52, 47, 55, nil, 229, nil, nil, nil,
118
+ nil, nil, 21, nil, nil, nil, nil, nil, nil, nil,
119
+ 50, 51, nil, 35, 48, 39, 41, 42, 43, 44,
120
+ nil, 52, 47, 55, nil, 154, nil, nil, 21, nil,
121
+ nil, nil, nil, nil, nil, nil, 50, 51, nil, 35,
122
+ 48, 39, 41, 42, 43, 44, nil, 52, 47, 55,
123
+ nil, 31, nil, nil, nil, nil, 158, 21, nil, nil,
124
+ 125, nil, nil, nil, nil, 50, 51, nil, 35, 48,
125
+ 39, 41, 42, 43, 44, nil, 52, 47, 55, nil,
126
+ 31, nil, nil, 21, nil, nil, nil, nil, nil, nil,
127
+ nil, 50, 51, nil, 35, 48, 39, 41, 42, 43,
128
+ 44, nil, 52, 47, 55, nil, 154, nil, nil, nil,
129
+ nil, nil, 21, nil, nil, nil, nil, nil, nil, nil,
130
+ 50, 51, nil, 35, 48, 39, 41, 42, 43, 44,
131
+ 161, 52, 47, 55, nil, 31, nil, 158, 21, nil,
132
+ nil, nil, nil, nil, nil, nil, 50, 51, nil, 35,
133
+ 48, 39, 41, 42, 43, 44, nil, 52, nil, 55,
134
+ nil, nil, nil, nil, nil, nil, nil, 21, nil, nil,
135
+ nil, nil, nil, nil, nil, 50, 51, nil, 35, 48,
136
+ 39, 41, 42, 43, 44, nil, 52, nil, 55, 195,
137
+ 196, nil, 197, 198, 199, nil, nil, nil, nil, 200,
138
+ 201, 202, 203, 204, 205 ]
139
+
140
+ racc_action_check = [
141
+ 154, 192, 57, 154, 101, 137, 199, 187, 154, 25,
142
+ 59, 102, 199, 103, 89, 104, 20, 195, 83, 195,
143
+ 195, 83, 106, 187, 107, 187, 187, 154, 187, 187,
144
+ 187, 187, 59, 192, 154, 154, 84, 57, 20, 84,
145
+ 137, 108, 25, 154, 154, 109, 154, 154, 154, 154,
146
+ 154, 154, 154, 83, 154, 114, 154, 89, 89, 68,
147
+ 0, 83, 83, 0, 83, 83, 83, 83, 83, 83,
148
+ 83, 84, 83, 231, 83, 262, 231, 116, 23, 84,
149
+ 84, 231, 84, 84, 84, 84, 84, 84, 84, 125,
150
+ 84, 8, 84, 116, 8, 116, 116, 126, 116, 116,
151
+ 8, 8, 8, 8, 52, 52, 95, 95, 231, 23,
152
+ 23, 23, 24, 24, 127, 128, 231, 231, 129, 231,
153
+ 231, 231, 231, 231, 231, 231, 8, 231, 229, 231,
154
+ 130, 229, 134, 66, 8, 8, 229, 8, 8, 8,
155
+ 8, 8, 8, 8, 142, 8, 228, 8, 143, 228,
156
+ 65, 146, 147, 152, 153, 64, 155, 158, 159, 55,
157
+ 184, 185, 49, 229, 226, 190, 191, 226, 48, 193,
158
+ 47, 229, 229, 45, 229, 229, 229, 229, 229, 229,
159
+ 229, 228, 229, 197, 229, 44, 43, 42, 41, 228,
160
+ 228, 39, 228, 228, 228, 228, 228, 228, 228, 226,
161
+ 228, 36, 228, 206, 21, 19, 16, 226, 226, 218,
162
+ 226, 226, 226, 226, 226, 226, 226, 58, 226, 13,
163
+ 226, 58, 13, 219, 220, 58, 225, 12, 227, 11,
164
+ 9, 13, 230, 58, 7, 58, 58, 14, 58, 58,
165
+ 14, 235, 245, 246, 247, 248, 5, 252, 254, 14,
166
+ 255, 1, 80, 81, 13, 87, 71, 90, 93, 99,
167
+ 69, nil, 13, 13, nil, 13, 13, 13, 13, 13,
168
+ 13, 13, 14, 13, 217, 13, nil, 217, nil, nil,
169
+ 14, 14, nil, 14, 14, 14, 14, 14, 14, 14,
170
+ nil, 14, 15, 14, nil, 15, nil, nil, nil, nil,
171
+ nil, 217, nil, nil, 15, nil, nil, nil, 217, 217,
172
+ 213, nil, nil, 213, nil, nil, nil, 217, 217, nil,
173
+ 217, 217, 217, 217, 217, 217, 217, 15, 217, nil,
174
+ 217, nil, nil, nil, 258, 15, 15, 258, 15, 15,
175
+ 15, 15, 15, 15, 15, 213, 15, nil, 15, nil,
176
+ nil, nil, nil, 213, 213, nil, 213, 213, 213, 213,
177
+ 213, 213, 213, nil, 213, 209, 213, nil, 209, 258,
178
+ nil, nil, nil, nil, nil, nil, nil, 258, 258, nil,
179
+ 258, 258, 258, 258, 258, 258, 258, nil, 258, nil,
180
+ 258, 70, 209, nil, 70, nil, nil, nil, nil, 209,
181
+ 209, nil, nil, nil, nil, nil, nil, nil, 209, 209,
182
+ nil, 209, 209, 209, 209, 209, 209, 209, nil, 209,
183
+ 74, 209, nil, 74, nil, nil, 70, nil, nil, nil,
184
+ nil, nil, nil, nil, 70, 70, nil, 70, 70, 70,
185
+ 70, 70, 70, 70, nil, 70, 75, 70, nil, 75,
186
+ nil, nil, nil, nil, nil, 74, nil, nil, nil, nil,
187
+ nil, nil, nil, 74, 74, nil, 74, 74, 74, 74,
188
+ 74, 74, 74, nil, 74, 76, 74, nil, 76, nil,
189
+ nil, 75, nil, nil, nil, nil, nil, nil, nil, 75,
190
+ 75, nil, 75, 75, 75, 75, 75, 75, 75, nil,
191
+ 75, 77, 75, nil, 77, nil, nil, nil, nil, nil,
192
+ 76, nil, nil, nil, nil, nil, nil, nil, 76, 76,
193
+ nil, 76, 76, 76, 76, 76, 76, 76, nil, 76,
194
+ 86, 76, nil, 86, nil, nil, 77, nil, nil, nil,
195
+ nil, nil, nil, nil, 77, 77, nil, 77, 77, 77,
196
+ 77, 77, 77, 77, nil, 77, 85, 77, nil, 85,
197
+ nil, nil, nil, nil, nil, 86, nil, nil, nil, nil,
198
+ nil, nil, nil, 86, 86, nil, 86, 86, 86, 86,
199
+ 86, 86, 86, nil, 86, 205, 86, nil, 205, nil,
200
+ nil, 85, nil, nil, nil, nil, nil, nil, nil, 85,
201
+ 85, nil, 85, 85, 85, 85, 85, 85, 85, nil,
202
+ 85, 26, 85, nil, 26, nil, nil, nil, nil, nil,
203
+ 205, nil, nil, nil, nil, nil, nil, nil, 205, 205,
204
+ nil, 205, 205, 205, 205, 205, 205, 205, nil, 205,
205
+ 31, 205, nil, 31, nil, nil, 26, nil, nil, nil,
206
+ nil, nil, nil, nil, nil, nil, nil, 26, 26, 26,
207
+ 26, 26, 26, 26, nil, 26, 204, 26, nil, 204,
208
+ nil, nil, nil, nil, nil, 31, nil, nil, nil, nil,
209
+ nil, nil, nil, 31, 31, nil, 31, 31, 31, 31,
210
+ 31, 31, 31, nil, 31, 203, 31, nil, 203, nil,
211
+ nil, 204, nil, nil, nil, nil, nil, nil, nil, 204,
212
+ 204, nil, 204, 204, 204, 204, 204, 204, 204, nil,
213
+ 204, 202, 204, nil, 202, nil, nil, nil, nil, nil,
214
+ 203, nil, nil, nil, nil, nil, nil, nil, 203, 203,
215
+ nil, 203, 203, 203, 203, 203, 203, 203, nil, 203,
216
+ 201, 203, nil, 201, nil, nil, 202, nil, nil, nil,
217
+ nil, nil, nil, nil, 202, 202, nil, 202, 202, 202,
218
+ 202, 202, 202, 202, nil, 202, 200, 202, nil, 200,
219
+ nil, nil, nil, nil, nil, 201, nil, nil, nil, nil,
220
+ nil, nil, nil, 201, 201, nil, 201, 201, 201, 201,
221
+ 201, 201, 201, nil, 201, 198, 201, nil, 198, nil,
222
+ nil, 200, nil, nil, nil, nil, nil, nil, nil, 200,
223
+ 200, nil, 200, 200, 200, 200, 200, 200, 200, nil,
224
+ 200, 196, 200, nil, 196, nil, nil, nil, nil, nil,
225
+ 198, nil, nil, nil, nil, nil, nil, nil, 198, 198,
226
+ nil, 198, 198, 198, 198, 198, 198, 198, nil, 198,
227
+ nil, 198, 194, nil, nil, 194, 196, nil, nil, nil,
228
+ nil, nil, nil, nil, 196, 196, nil, 196, 196, 196,
229
+ 196, 196, 196, 196, nil, 196, nil, 196, 189, 194,
230
+ nil, 189, nil, nil, nil, nil, 194, 194, nil, nil,
231
+ nil, nil, nil, nil, nil, 194, 194, nil, 194, 194,
232
+ 194, 194, 194, 194, 194, 189, 194, 183, 194, nil,
233
+ 183, nil, 189, 189, nil, nil, nil, nil, nil, nil,
234
+ nil, 189, 189, nil, 189, 189, 189, 189, 189, 189,
235
+ 189, nil, 189, 251, 189, nil, 251, nil, nil, nil,
236
+ nil, nil, 183, nil, nil, nil, nil, nil, nil, nil,
237
+ 183, 183, nil, 183, 183, 183, 183, 183, 183, 183,
238
+ nil, 183, 161, 183, nil, 161, nil, nil, 251, nil,
239
+ nil, nil, nil, nil, nil, nil, 251, 251, nil, 251,
240
+ 251, 251, 251, 251, 251, 251, nil, 251, 82, 251,
241
+ nil, 82, nil, nil, nil, nil, 161, 161, nil, nil,
242
+ 82, nil, nil, nil, nil, 161, 161, nil, 161, 161,
243
+ 161, 161, 161, 161, 161, nil, 161, 144, 161, nil,
244
+ 144, nil, nil, 82, nil, nil, nil, nil, nil, nil,
245
+ nil, 82, 82, nil, 82, 82, 82, 82, 82, 82,
246
+ 82, nil, 82, 115, 82, nil, 115, nil, nil, nil,
247
+ nil, nil, 144, nil, nil, nil, nil, nil, nil, nil,
248
+ 144, 144, nil, 144, 144, 144, 144, 144, 144, 144,
249
+ 115, 144, 100, 144, nil, 100, nil, 115, 115, nil,
250
+ nil, nil, nil, nil, nil, nil, 115, 115, nil, 115,
251
+ 115, 115, 115, 115, 115, 115, nil, 115, nil, 115,
252
+ nil, nil, nil, nil, nil, nil, nil, 100, nil, nil,
253
+ nil, nil, nil, nil, nil, 100, 100, nil, 100, 100,
254
+ 100, 100, 100, 100, 100, nil, 100, nil, 100, 157,
255
+ 157, nil, 157, 157, 157, nil, nil, nil, nil, 157,
256
+ 157, 157, 157, 157, 157 ]
257
+
258
+ racc_action_pointer = [
259
+ 50, 251, nil, nil, nil, 244, nil, 223, 86, 230,
260
+ nil, 226, 187, 214, 232, 287, 187, nil, nil, 201,
261
+ -2, 152, nil, 61, 64, -8, 606, nil, nil, nil,
262
+ nil, 635, nil, nil, nil, nil, 149, nil, nil, 183,
263
+ nil, 180, 179, 178, 177, 115, nil, 118, 163, 104,
264
+ nil, nil, 45, nil, nil, 97, nil, -3, 213, -8,
265
+ nil, nil, nil, nil, 136, 131, 114, nil, 30, 220,
266
+ 386, 216, nil, nil, 415, 441, 470, 496, nil, nil,
267
+ 243, 213, 993, 13, 31, 551, 525, 250, nil, 9,
268
+ 198, nil, nil, 254, nil, 100, nil, nil, nil, 247,
269
+ 1077, -4, -29, -8, -6, nil, -2, 0, 17, 5,
270
+ nil, nil, nil, nil, 25, 1048, 73, nil, nil, nil,
271
+ nil, nil, nil, nil, nil, 80, 88, 105, 106, 109,
272
+ 121, nil, nil, nil, 127, nil, nil, 0, nil, nil,
273
+ nil, nil, 135, 144, 1022, nil, 111, 112, nil, nil,
274
+ nil, nil, 122, 151, -5, 115, nil, 1107, 149, 124,
275
+ nil, 967, nil, nil, nil, nil, nil, nil, nil, nil,
276
+ nil, nil, nil, nil, nil, nil, nil, nil, nil, nil,
277
+ nil, nil, nil, 912, 151, 157, nil, 3, nil, 883,
278
+ 125, 157, -8, 160, 857, -16, 826, 175, 800, -26,
279
+ 771, 745, 716, 690, 661, 580, 190, nil, nil, 360,
280
+ nil, nil, nil, 305, nil, nil, nil, 269, 201, 182,
281
+ 220, nil, nil, nil, nil, 192, 159, 220, 141, 123,
282
+ 198, 68, nil, nil, nil, 203, nil, nil, nil, nil,
283
+ nil, nil, nil, nil, nil, 201, 203, 204, 211, nil,
284
+ nil, 938, 238, nil, 239, 246, nil, nil, 329, nil,
285
+ nil, nil, 35, nil, nil ]
286
+
287
+ racc_action_default = [
288
+ -160, -160, -1, -2, -3, -5, -16, -160, -160, -160,
289
+ -4, -160, -160, -160, -160, -160, -30, -31, -32, -34,
290
+ -37, -154, -112, -113, -116, -119, -160, -121, -122, -123,
291
+ -124, -160, -126, -127, -128, -130, -160, -132, -133, -160,
292
+ -135, -160, -160, -160, -160, -141, -142, -146, -160, -160,
293
+ -152, -153, -160, -157, -158, -160, 265, -160, -160, -42,
294
+ -43, -45, -46, -85, -24, -26, -28, -29, -62, -160,
295
+ -160, -160, -36, -154, -160, -160, -160, -160, -120, -129,
296
+ -160, -160, -160, -160, -160, -160, -160, -144, -145, -160,
297
+ -160, -156, -159, -6, -8, -12, -10, -11, -17, -160,
298
+ -160, -160, -160, -160, -160, -50, -52, -54, -55, -160,
299
+ -41, -23, -25, -27, -64, -160, -39, -33, -35, -114,
300
+ -115, -117, -118, -125, -131, -160, -160, -160, -160, -160,
301
+ -160, -143, -147, -149, -160, -151, -155, -160, -9, -13,
302
+ -14, -18, -160, -21, -160, -47, -160, -160, -51, -53,
303
+ -56, -40, -69, -160, -160, -63, -71, -160, -160, -88,
304
+ -90, -160, -93, -94, -95, -97, -98, -99, -100, -101,
305
+ -102, -109, -110, -111, -134, -136, -137, -138, -139, -140,
306
+ -150, -7, -19, -160, -160, -79, -48, -160, -38, -160,
307
+ -160, -160, -160, -111, -160, -160, -160, -160, -160, -160,
308
+ -160, -160, -160, -160, -160, -160, -160, -44, -84, -160,
309
+ -92, -20, -22, -160, -49, -57, -58, -160, -160, -70,
310
+ -65, -67, -68, -15, -96, -89, -160, -160, -160, -160,
311
+ -160, -160, -75, -76, -81, -160, -83, -103, -104, -105,
312
+ -106, -107, -108, -91, -78, -59, -160, -160, -160, -74,
313
+ -80, -160, -160, -82, -160, -61, -87, -66, -160, -73,
314
+ -77, -60, -160, -72, -86 ]
315
+
316
+ racc_goto_table = [
317
+ 72, 20, 142, 58, 184, 59, 20, 20, 20, 155,
318
+ 94, 207, 230, 222, 234, 221, 237, 238, 239, 240,
319
+ 241, 242, 232, 98, 80, 16, 121, 122, 119, 120,
320
+ 64, 65, 66, 114, 152, 188, 93, 96, 67, 110,
321
+ 208, 214, 248, 215, 250, 216, 10, 254, 192, 79,
322
+ 207, 118, 249, 255, 220, 5, 4, 3, 1, 225,
323
+ 116, 124, 59, 20, 141, 243, 210, 259, 2, 134,
324
+ 222, 78, 257, 244, 263, 126, 127, 128, 129, 130,
325
+ 207, 132, 99, 219, 133, 211, 111, 112, 113, 151,
326
+ 181, 252, 138, 143, 117, 145, nil, 79, 79, 79,
327
+ 79, nil, nil, nil, nil, nil, nil, nil, nil, nil,
328
+ nil, 245, nil, nil, nil, nil, nil, 96, nil, nil,
329
+ nil, nil, nil, nil, nil, nil, nil, nil, nil, nil,
330
+ nil, nil, nil, nil, nil, nil, nil, 185, 187, 186,
331
+ 59, nil, nil, nil, nil, nil, nil, 193, nil, nil,
332
+ nil, nil, nil, nil, nil, nil, nil, nil, nil, nil,
333
+ nil, nil, nil, nil, nil, nil, nil, nil, nil, nil,
334
+ nil, nil, nil, nil, nil, nil, 143, nil, nil, nil,
335
+ nil, nil, nil, nil, nil, nil, nil, nil, nil, nil,
336
+ nil, nil, nil, nil, nil, nil, nil, nil, nil, nil,
337
+ nil, nil, nil, nil, nil, nil, 185, nil, nil, nil,
338
+ nil, nil, nil, nil, nil, nil, nil, nil, nil, nil,
339
+ nil, nil, 80, nil, 185, nil, 256, nil, nil, nil,
340
+ nil, nil, nil, nil, nil, nil, nil, nil, nil, nil,
341
+ nil, nil, 264 ]
342
+
343
+ racc_goto_check = [
344
+ 11, 18, 17, 14, 19, 28, 18, 18, 18, 37,
345
+ 8, 12, 45, 42, 45, 41, 45, 45, 45, 45,
346
+ 45, 45, 47, 15, 18, 20, 60, 60, 58, 58,
347
+ 20, 20, 20, 25, 26, 27, 7, 11, 21, 11,
348
+ 30, 34, 45, 35, 45, 36, 6, 38, 37, 59,
349
+ 12, 11, 47, 39, 40, 5, 4, 3, 1, 51,
350
+ 14, 11, 28, 18, 15, 52, 53, 45, 2, 62,
351
+ 42, 63, 41, 19, 45, 18, 18, 18, 18, 18,
352
+ 12, 74, 16, 37, 75, 17, 21, 21, 21, 11,
353
+ 8, 19, 10, 18, 22, 28, nil, 59, 59, 59,
354
+ 59, nil, nil, nil, nil, nil, nil, nil, nil, nil,
355
+ nil, 37, nil, nil, nil, nil, nil, 11, nil, nil,
356
+ nil, nil, nil, nil, nil, nil, nil, nil, nil, nil,
357
+ nil, nil, nil, nil, nil, nil, nil, 18, 14, 28,
358
+ 28, nil, nil, nil, nil, nil, nil, 18, nil, nil,
359
+ nil, nil, nil, nil, nil, nil, nil, nil, nil, nil,
360
+ nil, nil, nil, nil, nil, nil, nil, nil, nil, nil,
361
+ nil, nil, nil, nil, nil, nil, 18, nil, nil, nil,
362
+ nil, nil, nil, nil, nil, nil, nil, nil, nil, nil,
363
+ nil, nil, nil, nil, nil, nil, nil, nil, nil, nil,
364
+ nil, nil, nil, nil, nil, nil, 18, nil, nil, nil,
365
+ nil, nil, nil, nil, nil, nil, nil, nil, nil, nil,
366
+ nil, nil, 18, nil, 18, nil, 11, nil, nil, nil,
367
+ nil, nil, nil, nil, nil, nil, nil, nil, nil, nil,
368
+ nil, nil, 11 ]
369
+
370
+ racc_goto_pointer = [
371
+ nil, 58, 68, 57, 56, 55, 41, -21, -47, nil,
372
+ -3, -20, -147, nil, -9, -35, 24, -98, -7, -140,
373
+ 17, 22, 24, nil, nil, -35, -80, -117, -7, nil,
374
+ -118, nil, nil, nil, -146, -144, -142, -106, -199, -193,
375
+ -136, -175, -177, nil, nil, -184, nil, -175, nil, nil,
376
+ nil, -135, -144, -95, nil, nil, nil, nil, -46, 23,
377
+ -50, nil, -20, 45, nil, nil, nil, nil, nil, nil,
378
+ nil, nil, nil, nil, -8, -5, nil, nil ]
379
+
380
+ racc_goto_default = [
381
+ nil, nil, nil, nil, nil, 191, nil, nil, nil, 95,
382
+ nil, 37, 156, 6, nil, nil, nil, nil, 173, nil,
383
+ nil, nil, 18, 19, 68, nil, nil, nil, 38, 60,
384
+ 233, 61, 62, 104, nil, nil, nil, nil, nil, nil,
385
+ nil, nil, 29, 172, 166, 157, 167, nil, 168, 169,
386
+ 170, 159, 160, 162, 163, 164, 165, 171, 22, 23,
387
+ 24, 25, 26, 27, 28, 30, 32, 33, 34, 36,
388
+ 40, 45, 46, 49, nil, nil, 53, 54 ]
389
+
390
+ racc_reduce_table = [
391
+ 0, 0, :racc_error,
392
+ 1, 64, :_reduce_none,
393
+ 1, 65, :_reduce_none,
394
+ 1, 65, :_reduce_none,
395
+ 2, 66, :_reduce_4,
396
+ 0, 69, :_reduce_none,
397
+ 3, 69, :_reduce_6,
398
+ 3, 70, :_reduce_7,
399
+ 1, 70, :_reduce_none,
400
+ 2, 71, :_reduce_9,
401
+ 1, 72, :_reduce_none,
402
+ 1, 72, :_reduce_11,
403
+ 0, 73, :_reduce_12,
404
+ 1, 73, :_reduce_13,
405
+ 1, 73, :_reduce_14,
406
+ 3, 75, :_reduce_15,
407
+ 1, 68, :_reduce_none,
408
+ 4, 67, :_reduce_17,
409
+ 5, 67, :_reduce_18,
410
+ 3, 79, :_reduce_19,
411
+ 3, 80, :_reduce_20,
412
+ 1, 80, :_reduce_none,
413
+ 4, 78, :_reduce_22,
414
+ 4, 76, :_reduce_23,
415
+ 3, 76, :_reduce_24,
416
+ 4, 76, :_reduce_25,
417
+ 3, 76, :_reduce_26,
418
+ 4, 76, :_reduce_27,
419
+ 3, 76, :_reduce_28,
420
+ 3, 76, :_reduce_29,
421
+ 2, 76, :_reduce_30,
422
+ 1, 83, :_reduce_31,
423
+ 1, 83, :_reduce_32,
424
+ 3, 85, :_reduce_33,
425
+ 1, 85, :_reduce_none,
426
+ 3, 86, :_reduce_35,
427
+ 2, 86, :_reduce_36,
428
+ 1, 86, :_reduce_none,
429
+ 4, 84, :_reduce_38,
430
+ 2, 87, :_reduce_39,
431
+ 3, 77, :_reduce_40,
432
+ 2, 77, :_reduce_41,
433
+ 1, 77, :_reduce_none,
434
+ 1, 77, :_reduce_none,
435
+ 1, 93, :_reduce_none,
436
+ 1, 92, :_reduce_none,
437
+ 1, 92, :_reduce_none,
438
+ 3, 94, :_reduce_47,
439
+ 4, 94, :_reduce_48,
440
+ 5, 95, :_reduce_49,
441
+ 1, 96, :_reduce_50,
442
+ 2, 96, :_reduce_51,
443
+ 1, 96, :_reduce_52,
444
+ 2, 96, :_reduce_53,
445
+ 1, 96, :_reduce_54,
446
+ 1, 96, :_reduce_55,
447
+ 2, 96, :_reduce_56,
448
+ 1, 97, :_reduce_none,
449
+ 1, 97, :_reduce_none,
450
+ 2, 98, :_reduce_59,
451
+ 4, 99, :_reduce_60,
452
+ 1, 101, :_reduce_none,
453
+ 0, 88, :_reduce_none,
454
+ 2, 88, :_reduce_63,
455
+ 0, 89, :_reduce_none,
456
+ 3, 89, :_reduce_65,
457
+ 3, 103, :_reduce_66,
458
+ 1, 103, :_reduce_none,
459
+ 1, 104, :_reduce_none,
460
+ 0, 90, :_reduce_none,
461
+ 2, 90, :_reduce_70,
462
+ 1, 106, :_reduce_none,
463
+ 6, 107, :_reduce_72,
464
+ 5, 107, :_reduce_73,
465
+ 4, 109, :_reduce_74,
466
+ 3, 109, :_reduce_75,
467
+ 1, 110, :_reduce_none,
468
+ 3, 110, :_reduce_77,
469
+ 3, 82, :_reduce_78,
470
+ 1, 82, :_reduce_none,
471
+ 4, 111, :_reduce_80,
472
+ 3, 111, :_reduce_81,
473
+ 4, 112, :_reduce_82,
474
+ 3, 112, :_reduce_83,
475
+ 2, 113, :_reduce_84,
476
+ 1, 91, :_reduce_85,
477
+ 3, 102, :_reduce_86,
478
+ 1, 102, :_reduce_none,
479
+ 1, 100, :_reduce_none,
480
+ 3, 100, :_reduce_89,
481
+ 1, 114, :_reduce_none,
482
+ 3, 114, :_reduce_91,
483
+ 2, 115, :_reduce_92,
484
+ 1, 115, :_reduce_none,
485
+ 1, 116, :_reduce_none,
486
+ 1, 117, :_reduce_none,
487
+ 3, 117, :_reduce_96,
488
+ 1, 118, :_reduce_none,
489
+ 1, 118, :_reduce_none,
490
+ 1, 118, :_reduce_none,
491
+ 1, 118, :_reduce_none,
492
+ 1, 118, :_reduce_none,
493
+ 1, 118, :_reduce_none,
494
+ 3, 119, :_reduce_103,
495
+ 3, 119, :_reduce_104,
496
+ 3, 119, :_reduce_105,
497
+ 3, 119, :_reduce_106,
498
+ 3, 119, :_reduce_107,
499
+ 3, 119, :_reduce_108,
500
+ 1, 108, :_reduce_none,
501
+ 1, 108, :_reduce_none,
502
+ 1, 120, :_reduce_none,
503
+ 1, 81, :_reduce_none,
504
+ 1, 81, :_reduce_none,
505
+ 3, 121, :_reduce_114,
506
+ 3, 121, :_reduce_115,
507
+ 1, 121, :_reduce_none,
508
+ 3, 123, :_reduce_117,
509
+ 3, 123, :_reduce_118,
510
+ 1, 123, :_reduce_none,
511
+ 2, 124, :_reduce_120,
512
+ 1, 124, :_reduce_none,
513
+ 1, 126, :_reduce_none,
514
+ 1, 126, :_reduce_none,
515
+ 1, 126, :_reduce_none,
516
+ 3, 126, :_reduce_125,
517
+ 1, 127, :_reduce_none,
518
+ 1, 127, :_reduce_none,
519
+ 1, 129, :_reduce_none,
520
+ 1, 129, :_reduce_none,
521
+ 1, 130, :_reduce_130,
522
+ 3, 105, :_reduce_131,
523
+ 1, 105, :_reduce_none,
524
+ 1, 132, :_reduce_none,
525
+ 4, 128, :_reduce_134,
526
+ 1, 128, :_reduce_none,
527
+ 4, 133, :_reduce_136,
528
+ 4, 133, :_reduce_137,
529
+ 4, 133, :_reduce_138,
530
+ 4, 133, :_reduce_139,
531
+ 4, 133, :_reduce_140,
532
+ 1, 131, :_reduce_none,
533
+ 1, 131, :_reduce_none,
534
+ 3, 134, :_reduce_143,
535
+ 2, 134, :_reduce_144,
536
+ 2, 134, :_reduce_145,
537
+ 1, 134, :_reduce_146,
538
+ 3, 135, :_reduce_147,
539
+ 1, 136, :_reduce_none,
540
+ 1, 137, :_reduce_none,
541
+ 2, 138, :_reduce_150,
542
+ 1, 138, :_reduce_151,
543
+ 1, 125, :_reduce_152,
544
+ 1, 125, :_reduce_153,
545
+ 1, 74, :_reduce_154,
546
+ 3, 122, :_reduce_155,
547
+ 2, 122, :_reduce_156,
548
+ 1, 122, :_reduce_none,
549
+ 1, 139, :_reduce_none,
550
+ 2, 140, :_reduce_159 ]
551
+
552
+ racc_reduce_n = 160
553
+
554
+ racc_shift_n = 265
555
+
556
+ racc_token_table = {
557
+ false => 0,
558
+ :error => 1,
559
+ :ORDER => 2,
560
+ :BY => 3,
561
+ :comma => 4,
562
+ :unsigned_integer => 5,
563
+ :ASC => 6,
564
+ :DESC => 7,
565
+ :left_paren => 8,
566
+ :right_paren => 9,
567
+ :INSERT => 10,
568
+ :INTO => 11,
569
+ :VALUES => 12,
570
+ :SELECT => 13,
571
+ :DISTINCTROW => 14,
572
+ :DISTINCT => 15,
573
+ :ALL => 16,
574
+ :asterisk => 17,
575
+ :AS => 18,
576
+ :FROM => 19,
577
+ :CROSS => 20,
578
+ :JOIN => 21,
579
+ :INNER => 22,
580
+ :LEFT => 23,
581
+ :OUTER => 24,
582
+ :RIGHT => 25,
583
+ :FULL => 26,
584
+ :ON => 27,
585
+ :USING => 28,
586
+ :WHERE => 29,
587
+ :GROUP => 30,
588
+ :HAVING => 31,
589
+ :NOT => 32,
590
+ :BETWEEN => 33,
591
+ :AND => 34,
592
+ :IN => 35,
593
+ :LIKE => 36,
594
+ :IS => 37,
595
+ :NULL => 38,
596
+ :EXISTS => 39,
597
+ :identifier => 40,
598
+ :OR => 41,
599
+ :equals_operator => 42,
600
+ :not_equals_operator => 43,
601
+ :less_than_operator => 44,
602
+ :greater_than_operator => 45,
603
+ :less_than_or_equals_operator => 46,
604
+ :greater_than_or_equals_operator => 47,
605
+ :plus_sign => 48,
606
+ :minus_sign => 49,
607
+ :solidus => 50,
608
+ :CURRENT_USER => 51,
609
+ :period => 52,
610
+ :COUNT => 53,
611
+ :AVG => 54,
612
+ :MAX => 55,
613
+ :MIN => 56,
614
+ :SUM => 57,
615
+ :E => 58,
616
+ :quote => 59,
617
+ :character_string_literal => 60,
618
+ :DATE => 61,
619
+ :date_string => 62 }
620
+
621
+ racc_nt_base = 63
622
+
623
+ racc_use_result_var = true
624
+
625
+ Racc_arg = [
626
+ racc_action_table,
627
+ racc_action_check,
628
+ racc_action_default,
629
+ racc_action_pointer,
630
+ racc_goto_table,
631
+ racc_goto_check,
632
+ racc_goto_default,
633
+ racc_goto_pointer,
634
+ racc_nt_base,
635
+ racc_reduce_table,
636
+ racc_token_table,
637
+ racc_shift_n,
638
+ racc_reduce_n,
639
+ racc_use_result_var ]
640
+
641
+ Racc_token_to_s_table = [
642
+ "$end",
643
+ "error",
644
+ "ORDER",
645
+ "BY",
646
+ "comma",
647
+ "unsigned_integer",
648
+ "ASC",
649
+ "DESC",
650
+ "left_paren",
651
+ "right_paren",
652
+ "INSERT",
653
+ "INTO",
654
+ "VALUES",
655
+ "SELECT",
656
+ "DISTINCTROW",
657
+ "DISTINCT",
658
+ "ALL",
659
+ "asterisk",
660
+ "AS",
661
+ "FROM",
662
+ "CROSS",
663
+ "JOIN",
664
+ "INNER",
665
+ "LEFT",
666
+ "OUTER",
667
+ "RIGHT",
668
+ "FULL",
669
+ "ON",
670
+ "USING",
671
+ "WHERE",
672
+ "GROUP",
673
+ "HAVING",
674
+ "NOT",
675
+ "BETWEEN",
676
+ "AND",
677
+ "IN",
678
+ "LIKE",
679
+ "IS",
680
+ "NULL",
681
+ "EXISTS",
682
+ "identifier",
683
+ "OR",
684
+ "equals_operator",
685
+ "not_equals_operator",
686
+ "less_than_operator",
687
+ "greater_than_operator",
688
+ "less_than_or_equals_operator",
689
+ "greater_than_or_equals_operator",
690
+ "plus_sign",
691
+ "minus_sign",
692
+ "solidus",
693
+ "CURRENT_USER",
694
+ "period",
695
+ "COUNT",
696
+ "AVG",
697
+ "MAX",
698
+ "MIN",
699
+ "SUM",
700
+ "E",
701
+ "quote",
702
+ "character_string_literal",
703
+ "DATE",
704
+ "date_string",
705
+ "$start",
706
+ "direct_sql_statement",
707
+ "direct_sql_data_statement",
708
+ "direct_select_statement_multiple_rows",
709
+ "insert_specification",
710
+ "query_expression",
711
+ "order_by_clause",
712
+ "sort_specification_list",
713
+ "sort_specification",
714
+ "sort_key",
715
+ "ordering_specification",
716
+ "column_name",
717
+ "subquery",
718
+ "query_specification",
719
+ "table_reference",
720
+ "value_list",
721
+ "column_list",
722
+ "in_column_list",
723
+ "value_expression",
724
+ "in_value_list",
725
+ "select_list",
726
+ "table_expression",
727
+ "select_sublist",
728
+ "derived_column",
729
+ "from_clause",
730
+ "where_clause",
731
+ "group_by_clause",
732
+ "having_clause",
733
+ "table_name",
734
+ "joined_table",
735
+ "table_subquery",
736
+ "cross_join",
737
+ "qualified_join",
738
+ "join_type",
739
+ "join_specification",
740
+ "join_condition",
741
+ "named_columns_join",
742
+ "search_condition",
743
+ "join_column_list",
744
+ "column_name_list",
745
+ "grouping_column_reference_list",
746
+ "grouping_column_reference",
747
+ "column_reference",
748
+ "row_subquery",
749
+ "between_predicate",
750
+ "row_value_constructor",
751
+ "in_predicate",
752
+ "in_predicate_value",
753
+ "like_predicate",
754
+ "null_predicate",
755
+ "exists_predicate",
756
+ "boolean_term",
757
+ "boolean_factor",
758
+ "boolean_test",
759
+ "boolean_primary",
760
+ "predicate",
761
+ "comparison_predicate",
762
+ "row_value_constructor_element",
763
+ "numeric_value_expression",
764
+ "general_literal",
765
+ "term",
766
+ "factor",
767
+ "sign",
768
+ "value_expression_primary",
769
+ "unsigned_value_specification",
770
+ "set_function_specification",
771
+ "unsigned_literal",
772
+ "general_value_specification",
773
+ "unsigned_numeric_literal",
774
+ "qualifier",
775
+ "general_set_function",
776
+ "exact_numeric_literal",
777
+ "approximate_numeric_literal",
778
+ "mantissa",
779
+ "exponent",
780
+ "signed_integer",
781
+ "datetime_literal",
782
+ "date_literal" ]
783
+
784
+ Racc_debug_parser = false
785
+
786
+ ##### State transition tables end #####
787
+
788
+ # reduce 0 omitted
789
+
790
+ # reduce 1 omitted
791
+
792
+ # reduce 2 omitted
793
+
794
+ # reduce 3 omitted
795
+
796
+ module_eval(<<'.,.,', 'parser.racc', 13)
797
+ def _reduce_4(val, _values, result)
798
+ result = SQLParser::Statement::DirectSelect.new(val[0], val[1])
799
+ result
800
+ end
801
+ .,.,
802
+
803
+ # reduce 5 omitted
804
+
805
+ module_eval(<<'.,.,', 'parser.racc', 18)
806
+ def _reduce_6(val, _values, result)
807
+ result = SQLParser::Statement::OrderBy.new(val[2])
808
+ result
809
+ end
810
+ .,.,
811
+
812
+ module_eval(<<'.,.,', 'parser.racc', 21)
813
+ def _reduce_7(val, _values, result)
814
+ result = Array(val[0]) + Array(val[2])
815
+ result
816
+ end
817
+ .,.,
818
+
819
+ # reduce 8 omitted
820
+
821
+ module_eval(<<'.,.,', 'parser.racc', 25)
822
+ def _reduce_9(val, _values, result)
823
+ result = val[1].new(val[0])
824
+ result
825
+ end
826
+ .,.,
827
+
828
+ # reduce 10 omitted
829
+
830
+ module_eval(<<'.,.,', 'parser.racc', 29)
831
+ def _reduce_11(val, _values, result)
832
+ result = SQLParser::Statement::Integer.new(val[0])
833
+ result
834
+ end
835
+ .,.,
836
+
837
+ module_eval(<<'.,.,', 'parser.racc', 32)
838
+ def _reduce_12(val, _values, result)
839
+ result = SQLParser::Statement::Ascending
840
+ result
841
+ end
842
+ .,.,
843
+
844
+ module_eval(<<'.,.,', 'parser.racc', 33)
845
+ def _reduce_13(val, _values, result)
846
+ result = SQLParser::Statement::Ascending
847
+ result
848
+ end
849
+ .,.,
850
+
851
+ module_eval(<<'.,.,', 'parser.racc', 34)
852
+ def _reduce_14(val, _values, result)
853
+ result = SQLParser::Statement::Descending
854
+ result
855
+ end
856
+ .,.,
857
+
858
+ module_eval(<<'.,.,', 'parser.racc', 39)
859
+ def _reduce_15(val, _values, result)
860
+ result = SQLParser::Statement::Subquery.new(val[1])
861
+ result
862
+ end
863
+ .,.,
864
+
865
+ # reduce 16 omitted
866
+
867
+ module_eval(<<'.,.,', 'parser.racc', 45)
868
+ def _reduce_17(val, _values, result)
869
+ result = SQLParser::Statement::Insert.new(val[2], nil, val[3])
870
+ result
871
+ end
872
+ .,.,
873
+
874
+ module_eval(<<'.,.,', 'parser.racc', 46)
875
+ def _reduce_18(val, _values, result)
876
+ result = SQLParser::Statement::Insert.new(val[2], val[3], val[4])
877
+ result
878
+ end
879
+ .,.,
880
+
881
+ module_eval(<<'.,.,', 'parser.racc', 49)
882
+ def _reduce_19(val, _values, result)
883
+ result = SQLParser::Statement::InColumnList.new(val[1])
884
+ result
885
+ end
886
+ .,.,
887
+
888
+ module_eval(<<'.,.,', 'parser.racc', 52)
889
+ def _reduce_20(val, _values, result)
890
+ result = Array(val[0]) + Array(val[2])
891
+ result
892
+ end
893
+ .,.,
894
+
895
+ # reduce 21 omitted
896
+
897
+ module_eval(<<'.,.,', 'parser.racc', 56)
898
+ def _reduce_22(val, _values, result)
899
+ result = SQLParser::Statement::InValueList.new(val[2])
900
+ result
901
+ end
902
+ .,.,
903
+
904
+ module_eval(<<'.,.,', 'parser.racc', 59)
905
+ def _reduce_23(val, _values, result)
906
+ result = SQLParser::Statement::Select.new(val[2], val[3], "DISTINCTROW")
907
+ result
908
+ end
909
+ .,.,
910
+
911
+ module_eval(<<'.,.,', 'parser.racc', 60)
912
+ def _reduce_24(val, _values, result)
913
+ result = SQLParser::Statement::Select.new(val[2], nil, "DISTINCTROW")
914
+ result
915
+ end
916
+ .,.,
917
+
918
+ module_eval(<<'.,.,', 'parser.racc', 61)
919
+ def _reduce_25(val, _values, result)
920
+ result = SQLParser::Statement::Select.new(val[2], val[3], "DISTINCT")
921
+ result
922
+ end
923
+ .,.,
924
+
925
+ module_eval(<<'.,.,', 'parser.racc', 62)
926
+ def _reduce_26(val, _values, result)
927
+ result = SQLParser::Statement::Select.new(val[2], nil, "DISTINCT")
928
+ result
929
+ end
930
+ .,.,
931
+
932
+ module_eval(<<'.,.,', 'parser.racc', 63)
933
+ def _reduce_27(val, _values, result)
934
+ result = SQLParser::Statement::Select.new(val[2], val[3], "ALL")
935
+ result
936
+ end
937
+ .,.,
938
+
939
+ module_eval(<<'.,.,', 'parser.racc', 64)
940
+ def _reduce_28(val, _values, result)
941
+ result = SQLParser::Statement::Select.new(val[2], nil, "ALL")
942
+ result
943
+ end
944
+ .,.,
945
+
946
+ module_eval(<<'.,.,', 'parser.racc', 65)
947
+ def _reduce_29(val, _values, result)
948
+ result = SQLParser::Statement::Select.new(val[1], val[2])
949
+ result
950
+ end
951
+ .,.,
952
+
953
+ module_eval(<<'.,.,', 'parser.racc', 66)
954
+ def _reduce_30(val, _values, result)
955
+ result = SQLParser::Statement::Select.new(val[1])
956
+ result
957
+ end
958
+ .,.,
959
+
960
+ module_eval(<<'.,.,', 'parser.racc', 69)
961
+ def _reduce_31(val, _values, result)
962
+ result = SQLParser::Statement::All.new
963
+ result
964
+ end
965
+ .,.,
966
+
967
+ module_eval(<<'.,.,', 'parser.racc', 70)
968
+ def _reduce_32(val, _values, result)
969
+ result = SQLParser::Statement::SelectList.new(val[0])
970
+ result
971
+ end
972
+ .,.,
973
+
974
+ module_eval(<<'.,.,', 'parser.racc', 73)
975
+ def _reduce_33(val, _values, result)
976
+ result = Array(val[0]) + Array(val[2])
977
+ result
978
+ end
979
+ .,.,
980
+
981
+ # reduce 34 omitted
982
+
983
+ module_eval(<<'.,.,', 'parser.racc', 77)
984
+ def _reduce_35(val, _values, result)
985
+ result = SQLParser::Statement::As.new(val[0], val[2])
986
+ result
987
+ end
988
+ .,.,
989
+
990
+ module_eval(<<'.,.,', 'parser.racc', 78)
991
+ def _reduce_36(val, _values, result)
992
+ result = SQLParser::Statement::As.new(val[0], val[1])
993
+ result
994
+ end
995
+ .,.,
996
+
997
+ # reduce 37 omitted
998
+
999
+ module_eval(<<'.,.,', 'parser.racc', 82)
1000
+ def _reduce_38(val, _values, result)
1001
+ result = SQLParser::Statement::TableExpression.new(val[0], val[1], val[2], val[3])
1002
+ result
1003
+ end
1004
+ .,.,
1005
+
1006
+ module_eval(<<'.,.,', 'parser.racc', 85)
1007
+ def _reduce_39(val, _values, result)
1008
+ result = SQLParser::Statement::FromClause.new(val[1])
1009
+ result
1010
+ end
1011
+ .,.,
1012
+
1013
+ module_eval(<<'.,.,', 'parser.racc', 88)
1014
+ def _reduce_40(val, _values, result)
1015
+ result = SQLParser::Statement::As.new(val[0], val[2])
1016
+ result
1017
+ end
1018
+ .,.,
1019
+
1020
+ module_eval(<<'.,.,', 'parser.racc', 89)
1021
+ def _reduce_41(val, _values, result)
1022
+ result = SQLParser::Statement::As.new(val[0], val[1])
1023
+ result
1024
+ end
1025
+ .,.,
1026
+
1027
+ # reduce 42 omitted
1028
+
1029
+ # reduce 43 omitted
1030
+
1031
+ # reduce 44 omitted
1032
+
1033
+ # reduce 45 omitted
1034
+
1035
+ # reduce 46 omitted
1036
+
1037
+ module_eval(<<'.,.,', 'parser.racc', 101)
1038
+ def _reduce_47(val, _values, result)
1039
+ result = SQLParser::Statement::CrossJoin.new(val[0], val[2])
1040
+ result
1041
+ end
1042
+ .,.,
1043
+
1044
+ module_eval(<<'.,.,', 'parser.racc', 102)
1045
+ def _reduce_48(val, _values, result)
1046
+ result = SQLParser::Statement::CrossJoin.new(val[0], val[3])
1047
+ result
1048
+ end
1049
+ .,.,
1050
+
1051
+ module_eval(<<'.,.,', 'parser.racc', 105)
1052
+ def _reduce_49(val, _values, result)
1053
+ result = val[1].new(val[0], val[3], val[4])
1054
+ result
1055
+ end
1056
+ .,.,
1057
+
1058
+ module_eval(<<'.,.,', 'parser.racc', 108)
1059
+ def _reduce_50(val, _values, result)
1060
+ result = SQLParser::Statement::InnerJoin
1061
+ result
1062
+ end
1063
+ .,.,
1064
+
1065
+ module_eval(<<'.,.,', 'parser.racc', 109)
1066
+ def _reduce_51(val, _values, result)
1067
+ result = SQLParser::Statement::LeftOuterJoin
1068
+ result
1069
+ end
1070
+ .,.,
1071
+
1072
+ module_eval(<<'.,.,', 'parser.racc', 110)
1073
+ def _reduce_52(val, _values, result)
1074
+ result = SQLParser::Statement::LeftJoin
1075
+ result
1076
+ end
1077
+ .,.,
1078
+
1079
+ module_eval(<<'.,.,', 'parser.racc', 111)
1080
+ def _reduce_53(val, _values, result)
1081
+ result = SQLParser::Statement::RightOuterJoin
1082
+ result
1083
+ end
1084
+ .,.,
1085
+
1086
+ module_eval(<<'.,.,', 'parser.racc', 112)
1087
+ def _reduce_54(val, _values, result)
1088
+ result = SQLParser::Statement::RightJoin
1089
+ result
1090
+ end
1091
+ .,.,
1092
+
1093
+ module_eval(<<'.,.,', 'parser.racc', 113)
1094
+ def _reduce_55(val, _values, result)
1095
+ result = SQLParser::Statement::FullJoin
1096
+ result
1097
+ end
1098
+ .,.,
1099
+
1100
+ module_eval(<<'.,.,', 'parser.racc', 114)
1101
+ def _reduce_56(val, _values, result)
1102
+ result = SQLParser::Statement::FullOuterJoin
1103
+ result
1104
+ end
1105
+ .,.,
1106
+
1107
+ # reduce 57 omitted
1108
+
1109
+ # reduce 58 omitted
1110
+
1111
+ module_eval(<<'.,.,', 'parser.racc', 121)
1112
+ def _reduce_59(val, _values, result)
1113
+ result = SQLParser::Statement::On.new(val[1])
1114
+ result
1115
+ end
1116
+ .,.,
1117
+
1118
+ module_eval(<<'.,.,', 'parser.racc', 124)
1119
+ def _reduce_60(val, _values, result)
1120
+ result = SQLParser::Statement::Using.new(val[2])
1121
+ result
1122
+ end
1123
+ .,.,
1124
+
1125
+ # reduce 61 omitted
1126
+
1127
+ # reduce 62 omitted
1128
+
1129
+ module_eval(<<'.,.,', 'parser.racc', 131)
1130
+ def _reduce_63(val, _values, result)
1131
+ result = SQLParser::Statement::WhereClause.new(val[1])
1132
+ result
1133
+ end
1134
+ .,.,
1135
+
1136
+ # reduce 64 omitted
1137
+
1138
+ module_eval(<<'.,.,', 'parser.racc', 135)
1139
+ def _reduce_65(val, _values, result)
1140
+ result = SQLParser::Statement::GroupByClause.new(val[2])
1141
+ result
1142
+ end
1143
+ .,.,
1144
+
1145
+ module_eval(<<'.,.,', 'parser.racc', 138)
1146
+ def _reduce_66(val, _values, result)
1147
+ result = Array(val[0]) + Array(val[2])
1148
+ result
1149
+ end
1150
+ .,.,
1151
+
1152
+ # reduce 67 omitted
1153
+
1154
+ # reduce 68 omitted
1155
+
1156
+ # reduce 69 omitted
1157
+
1158
+ module_eval(<<'.,.,', 'parser.racc', 146)
1159
+ def _reduce_70(val, _values, result)
1160
+ result = SQLParser::Statement::HavingClause.new(val[1])
1161
+ result
1162
+ end
1163
+ .,.,
1164
+
1165
+ # reduce 71 omitted
1166
+
1167
+ module_eval(<<'.,.,', 'parser.racc', 153)
1168
+ def _reduce_72(val, _values, result)
1169
+ result = SQLParser::Statement::Not.new(SQLParser::Statement::Between.new(val[0], val[3], val[5]))
1170
+ result
1171
+ end
1172
+ .,.,
1173
+
1174
+ module_eval(<<'.,.,', 'parser.racc', 154)
1175
+ def _reduce_73(val, _values, result)
1176
+ result = SQLParser::Statement::Between.new(val[0], val[2], val[4])
1177
+ result
1178
+ end
1179
+ .,.,
1180
+
1181
+ module_eval(<<'.,.,', 'parser.racc', 157)
1182
+ def _reduce_74(val, _values, result)
1183
+ result = SQLParser::Statement::Not.new(SQLParser::Statement::In.new(val[0], val[3]))
1184
+ result
1185
+ end
1186
+ .,.,
1187
+
1188
+ module_eval(<<'.,.,', 'parser.racc', 158)
1189
+ def _reduce_75(val, _values, result)
1190
+ result = SQLParser::Statement::In.new(val[0], val[2])
1191
+ result
1192
+ end
1193
+ .,.,
1194
+
1195
+ # reduce 76 omitted
1196
+
1197
+ module_eval(<<'.,.,', 'parser.racc', 162)
1198
+ def _reduce_77(val, _values, result)
1199
+ result = SQLParser::Statement::InValueList.new(val[1])
1200
+ result
1201
+ end
1202
+ .,.,
1203
+
1204
+ module_eval(<<'.,.,', 'parser.racc', 165)
1205
+ def _reduce_78(val, _values, result)
1206
+ result = Array(val[0]) + Array(val[2])
1207
+ result
1208
+ end
1209
+ .,.,
1210
+
1211
+ # reduce 79 omitted
1212
+
1213
+ module_eval(<<'.,.,', 'parser.racc', 172)
1214
+ def _reduce_80(val, _values, result)
1215
+ result = SQLParser::Statement::Not.new(SQLParser::Statement::Like.new(val[0], val[3]))
1216
+ result
1217
+ end
1218
+ .,.,
1219
+
1220
+ module_eval(<<'.,.,', 'parser.racc', 173)
1221
+ def _reduce_81(val, _values, result)
1222
+ result = SQLParser::Statement::Like.new(val[0], val[2])
1223
+ result
1224
+ end
1225
+ .,.,
1226
+
1227
+ module_eval(<<'.,.,', 'parser.racc', 176)
1228
+ def _reduce_82(val, _values, result)
1229
+ result = SQLParser::Statement::Not.new(SQLParser::Statement::Is.new(val[0], SQLParser::Statement::Null.new))
1230
+ result
1231
+ end
1232
+ .,.,
1233
+
1234
+ module_eval(<<'.,.,', 'parser.racc', 177)
1235
+ def _reduce_83(val, _values, result)
1236
+ result = SQLParser::Statement::Is.new(val[0], SQLParser::Statement::Null.new)
1237
+ result
1238
+ end
1239
+ .,.,
1240
+
1241
+ module_eval(<<'.,.,', 'parser.racc', 180)
1242
+ def _reduce_84(val, _values, result)
1243
+ result = SQLParser::Statement::Exists.new(val[1])
1244
+ result
1245
+ end
1246
+ .,.,
1247
+
1248
+ module_eval(<<'.,.,', 'parser.racc', 184)
1249
+ def _reduce_85(val, _values, result)
1250
+ result = SQLParser::Statement::Table.new(val[0])
1251
+ result
1252
+ end
1253
+ .,.,
1254
+
1255
+ module_eval(<<'.,.,', 'parser.racc', 187)
1256
+ def _reduce_86(val, _values, result)
1257
+ result = Array(val[0]) + Array(val[2])
1258
+ result
1259
+ end
1260
+ .,.,
1261
+
1262
+ # reduce 87 omitted
1263
+
1264
+ # reduce 88 omitted
1265
+
1266
+ module_eval(<<'.,.,', 'parser.racc', 193)
1267
+ def _reduce_89(val, _values, result)
1268
+ result = SQLParser::Statement::Or.new(val[0], val[2])
1269
+ result
1270
+ end
1271
+ .,.,
1272
+
1273
+ # reduce 90 omitted
1274
+
1275
+ module_eval(<<'.,.,', 'parser.racc', 197)
1276
+ def _reduce_91(val, _values, result)
1277
+ result = SQLParser::Statement::And.new(val[0], val[2])
1278
+ result
1279
+ end
1280
+ .,.,
1281
+
1282
+ module_eval(<<'.,.,', 'parser.racc', 200)
1283
+ def _reduce_92(val, _values, result)
1284
+ result = SQLParser::Statement::Not.new(val[1])
1285
+ result
1286
+ end
1287
+ .,.,
1288
+
1289
+ # reduce 93 omitted
1290
+
1291
+ # reduce 94 omitted
1292
+
1293
+ # reduce 95 omitted
1294
+
1295
+ module_eval(<<'.,.,', 'parser.racc', 208)
1296
+ def _reduce_96(val, _values, result)
1297
+ result = val[1]
1298
+ result
1299
+ end
1300
+ .,.,
1301
+
1302
+ # reduce 97 omitted
1303
+
1304
+ # reduce 98 omitted
1305
+
1306
+ # reduce 99 omitted
1307
+
1308
+ # reduce 100 omitted
1309
+
1310
+ # reduce 101 omitted
1311
+
1312
+ # reduce 102 omitted
1313
+
1314
+ module_eval(<<'.,.,', 'parser.racc', 219)
1315
+ def _reduce_103(val, _values, result)
1316
+ result = SQLParser::Statement::Equals.new(val[0], val[2])
1317
+ result
1318
+ end
1319
+ .,.,
1320
+
1321
+ module_eval(<<'.,.,', 'parser.racc', 220)
1322
+ def _reduce_104(val, _values, result)
1323
+ result = SQLParser::Statement::Not.new(SQLParser::Statement::Equals.new(val[0], val[2]))
1324
+ result
1325
+ end
1326
+ .,.,
1327
+
1328
+ module_eval(<<'.,.,', 'parser.racc', 221)
1329
+ def _reduce_105(val, _values, result)
1330
+ result = SQLParser::Statement::Less.new(val[0], val[2])
1331
+ result
1332
+ end
1333
+ .,.,
1334
+
1335
+ module_eval(<<'.,.,', 'parser.racc', 222)
1336
+ def _reduce_106(val, _values, result)
1337
+ result = SQLParser::Statement::Greater.new(val[0], val[2])
1338
+ result
1339
+ end
1340
+ .,.,
1341
+
1342
+ module_eval(<<'.,.,', 'parser.racc', 223)
1343
+ def _reduce_107(val, _values, result)
1344
+ result = SQLParser::Statement::LessOrEquals.new(val[0], val[2])
1345
+ result
1346
+ end
1347
+ .,.,
1348
+
1349
+ module_eval(<<'.,.,', 'parser.racc', 224)
1350
+ def _reduce_108(val, _values, result)
1351
+ result = SQLParser::Statement::GreaterOrEquals.new(val[0], val[2])
1352
+ result
1353
+ end
1354
+ .,.,
1355
+
1356
+ # reduce 109 omitted
1357
+
1358
+ # reduce 110 omitted
1359
+
1360
+ # reduce 111 omitted
1361
+
1362
+ # reduce 112 omitted
1363
+
1364
+ # reduce 113 omitted
1365
+
1366
+ module_eval(<<'.,.,', 'parser.racc', 238)
1367
+ def _reduce_114(val, _values, result)
1368
+ result = SQLParser::Statement::Add.new(val[0], val[2])
1369
+ result
1370
+ end
1371
+ .,.,
1372
+
1373
+ module_eval(<<'.,.,', 'parser.racc', 239)
1374
+ def _reduce_115(val, _values, result)
1375
+ result = SQLParser::Statement::Subtract.new(val[0], val[2])
1376
+ result
1377
+ end
1378
+ .,.,
1379
+
1380
+ # reduce 116 omitted
1381
+
1382
+ module_eval(<<'.,.,', 'parser.racc', 243)
1383
+ def _reduce_117(val, _values, result)
1384
+ result = SQLParser::Statement::Multiply.new(val[0], val[2])
1385
+ result
1386
+ end
1387
+ .,.,
1388
+
1389
+ module_eval(<<'.,.,', 'parser.racc', 244)
1390
+ def _reduce_118(val, _values, result)
1391
+ result = SQLParser::Statement::Divide.new(val[0], val[2])
1392
+ result
1393
+ end
1394
+ .,.,
1395
+
1396
+ # reduce 119 omitted
1397
+
1398
+ module_eval(<<'.,.,', 'parser.racc', 248)
1399
+ def _reduce_120(val, _values, result)
1400
+ result = val[0].new(val[1])
1401
+ result
1402
+ end
1403
+ .,.,
1404
+
1405
+ # reduce 121 omitted
1406
+
1407
+ # reduce 122 omitted
1408
+
1409
+ # reduce 123 omitted
1410
+
1411
+ # reduce 124 omitted
1412
+
1413
+ module_eval(<<'.,.,', 'parser.racc', 255)
1414
+ def _reduce_125(val, _values, result)
1415
+ result = val[1]
1416
+ result
1417
+ end
1418
+ .,.,
1419
+
1420
+ # reduce 126 omitted
1421
+
1422
+ # reduce 127 omitted
1423
+
1424
+ # reduce 128 omitted
1425
+
1426
+ # reduce 129 omitted
1427
+
1428
+ module_eval(<<'.,.,', 'parser.racc', 266)
1429
+ def _reduce_130(val, _values, result)
1430
+ result = SQLParser::Statement::CurrentUser.new
1431
+ result
1432
+ end
1433
+ .,.,
1434
+
1435
+ module_eval(<<'.,.,', 'parser.racc', 269)
1436
+ def _reduce_131(val, _values, result)
1437
+ result = SQLParser::Statement::QualifiedColumn.new(val[0], val[2])
1438
+ result
1439
+ end
1440
+ .,.,
1441
+
1442
+ # reduce 132 omitted
1443
+
1444
+ # reduce 133 omitted
1445
+
1446
+ module_eval(<<'.,.,', 'parser.racc', 276)
1447
+ def _reduce_134(val, _values, result)
1448
+ result = SQLParser::Statement::Count.new(SQLParser::Statement::All.new)
1449
+ result
1450
+ end
1451
+ .,.,
1452
+
1453
+ # reduce 135 omitted
1454
+
1455
+ module_eval(<<'.,.,', 'parser.racc', 280)
1456
+ def _reduce_136(val, _values, result)
1457
+ result = SQLParser::Statement::Count.new(val[2])
1458
+ result
1459
+ end
1460
+ .,.,
1461
+
1462
+ module_eval(<<'.,.,', 'parser.racc', 281)
1463
+ def _reduce_137(val, _values, result)
1464
+ result = SQLParser::Statement::Average.new(val[2])
1465
+ result
1466
+ end
1467
+ .,.,
1468
+
1469
+ module_eval(<<'.,.,', 'parser.racc', 282)
1470
+ def _reduce_138(val, _values, result)
1471
+ result = SQLParser::Statement::Maximum.new(val[2])
1472
+ result
1473
+ end
1474
+ .,.,
1475
+
1476
+ module_eval(<<'.,.,', 'parser.racc', 283)
1477
+ def _reduce_139(val, _values, result)
1478
+ result = SQLParser::Statement::Minimum.new(val[2])
1479
+ result
1480
+ end
1481
+ .,.,
1482
+
1483
+ module_eval(<<'.,.,', 'parser.racc', 284)
1484
+ def _reduce_140(val, _values, result)
1485
+ result = SQLParser::Statement::Sum.new(val[2])
1486
+ result
1487
+ end
1488
+ .,.,
1489
+
1490
+ # reduce 141 omitted
1491
+
1492
+ # reduce 142 omitted
1493
+
1494
+ module_eval(<<'.,.,', 'parser.racc', 292)
1495
+ def _reduce_143(val, _values, result)
1496
+ result = SQLParser::Statement::Float.new("#{val[0]}.#{val[2]}".to_f)
1497
+ result
1498
+ end
1499
+ .,.,
1500
+
1501
+ module_eval(<<'.,.,', 'parser.racc', 293)
1502
+ def _reduce_144(val, _values, result)
1503
+ result = SQLParser::Statement::Float.new(val[0])
1504
+ result
1505
+ end
1506
+ .,.,
1507
+
1508
+ module_eval(<<'.,.,', 'parser.racc', 294)
1509
+ def _reduce_145(val, _values, result)
1510
+ result = SQLParser::Statement::Float.new("0.#{val[1]}".to_f)
1511
+ result
1512
+ end
1513
+ .,.,
1514
+
1515
+ module_eval(<<'.,.,', 'parser.racc', 295)
1516
+ def _reduce_146(val, _values, result)
1517
+ result = SQLParser::Statement::Integer.new(val[0])
1518
+ result
1519
+ end
1520
+ .,.,
1521
+
1522
+ module_eval(<<'.,.,', 'parser.racc', 298)
1523
+ def _reduce_147(val, _values, result)
1524
+ result = SQLParser::Statement::ApproximateFloat.new(val[0], val[2])
1525
+ result
1526
+ end
1527
+ .,.,
1528
+
1529
+ # reduce 148 omitted
1530
+
1531
+ # reduce 149 omitted
1532
+
1533
+ module_eval(<<'.,.,', 'parser.racc', 307)
1534
+ def _reduce_150(val, _values, result)
1535
+ result = val[0].new(SQLParser::Statement::Integer.new(val[1]))
1536
+ result
1537
+ end
1538
+ .,.,
1539
+
1540
+ module_eval(<<'.,.,', 'parser.racc', 308)
1541
+ def _reduce_151(val, _values, result)
1542
+ result = SQLParser::Statement::Integer.new(val[0])
1543
+ result
1544
+ end
1545
+ .,.,
1546
+
1547
+ module_eval(<<'.,.,', 'parser.racc', 311)
1548
+ def _reduce_152(val, _values, result)
1549
+ result = SQLParser::Statement::UnaryPlus
1550
+ result
1551
+ end
1552
+ .,.,
1553
+
1554
+ module_eval(<<'.,.,', 'parser.racc', 312)
1555
+ def _reduce_153(val, _values, result)
1556
+ result = SQLParser::Statement::UnaryMinus
1557
+ result
1558
+ end
1559
+ .,.,
1560
+
1561
+ module_eval(<<'.,.,', 'parser.racc', 316)
1562
+ def _reduce_154(val, _values, result)
1563
+ result = SQLParser::Statement::Column.new(val[0])
1564
+ result
1565
+ end
1566
+ .,.,
1567
+
1568
+ module_eval(<<'.,.,', 'parser.racc', 320)
1569
+ def _reduce_155(val, _values, result)
1570
+ result = SQLParser::Statement::String.new(val[1])
1571
+ result
1572
+ end
1573
+ .,.,
1574
+
1575
+ module_eval(<<'.,.,', 'parser.racc', 321)
1576
+ def _reduce_156(val, _values, result)
1577
+ result = SQLParser::Statement::String.new('')
1578
+ result
1579
+ end
1580
+ .,.,
1581
+
1582
+ # reduce 157 omitted
1583
+
1584
+ # reduce 158 omitted
1585
+
1586
+ module_eval(<<'.,.,', 'parser.racc', 328)
1587
+ def _reduce_159(val, _values, result)
1588
+ result = SQLParser::Statement::Date.new(val[1])
1589
+ result
1590
+ end
1591
+ .,.,
1592
+
1593
+ def _reduce_none(val, _values, result)
1594
+ val[0]
1595
+ end
1596
+
1597
+ end # class Parser
1598
+ end # module SQLParser