embulk-filter-row 0.3.2 → 0.3.3

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 5339052a179409622158694483a27d6ab80f4a80
4
- data.tar.gz: 0460d1d3511ca884042e60465b40d6a8d5e41bf0
3
+ metadata.gz: d1a5e3ca3f112b41b011aeedc0ac215ba78c70fd
4
+ data.tar.gz: 8ca385ba7785b9ed44d077dc274727e621a2c380
5
5
  SHA512:
6
- metadata.gz: 0b12e47564da7eabd58733723e463ac1da4523795905a19f9583839b5c3a51f2ea56230ea564d452d75c8bbf125a724497f462f4f0213ba6e82a250fa7ea4d92
7
- data.tar.gz: b133c708497f4e78f09b35b35b8f11bb06d48bdf5ac5abe61ab7f9261d63abe98bb942a4c5f0bd55500516fb0076b0e7c35bbec59cf64da275999bc0fa23c5d0
6
+ metadata.gz: 7cfb6083eacafa6e1c235b49663569b1b9f23524dc455b947fb7da10d22039823d4f4a114dfc84e0e9432b76e9a9c27bb19b070e4b595e2b7a2dbe13d1e09cb8
7
+ data.tar.gz: b9f9da54d28074537d2bd655ba1d23acb67bb62bb88b7968ad7f2a384a648cb800f1fafb0aee920e725e7d35169ae751b89d56ca406516630cd784aa0098f358
data/CHANGELOG.md CHANGED
@@ -1,3 +1,10 @@
1
+ # 0.3.3 (2016-08-09)
2
+
3
+ Enhancements
4
+
5
+ * Support REGEXP operator
6
+ * Allow to omit TIMESTAMP keyword
7
+
1
8
  # 0.3.2 (2016-08-08)
2
9
 
3
10
  Changes
data/README.md CHANGED
@@ -6,7 +6,7 @@ A filter plugin for Embulk to filter out rows
6
6
 
7
7
  ## Configuration
8
8
 
9
- * **where**: Write conditions with SQL-like syntax. See [SQL-like Syntax](#sql-like-syntax)
9
+ * **where**: Select only rows which matches with conditions written in SQL-like syntax. See [SQL-like Syntax](#sql-like-syntax)
10
10
 
11
11
  Following options are **deprecated**, and will be removed someday.
12
12
 
@@ -124,7 +124,8 @@ where: |-
124
124
  OR
125
125
  (
126
126
  time = TIMESTAMP '2016-01-01 +0900' AND
127
- "true" = true
127
+ "true" = true AND
128
+ string REGEXP '^reg'
128
129
  )
129
130
  ```
130
131
 
@@ -159,6 +160,8 @@ String is a timestamp string which matches with one of following format:
159
160
 
160
161
  The time zone for formats without `%z` is UTC, and the time resolution is micro second (caused by limitation of Embulk TimestampParser).
161
162
 
163
+ It is possible to omit `TIMESTAMP` keyword on comparing with `timestamp` identifier from version >= 0.3.3.
164
+
162
165
  ### Json Literal
163
166
 
164
167
  Not supported yet
@@ -171,12 +174,12 @@ Characters matching with a regular expression `[a-zA-Z_][a-zA-z0-9_]*` such as `
171
174
 
172
175
  ### Boolean Operator
173
176
 
174
- * ==
177
+ * =
175
178
  * !=
176
179
 
177
180
  ### Number Operator (Long and Double)
178
181
 
179
- * ==
182
+ * =
180
183
  * !=
181
184
  * >
182
185
  * >=
@@ -185,15 +188,16 @@ Characters matching with a regular expression `[a-zA-Z_][a-zA-z0-9_]*` such as `
185
188
 
186
189
  ### String Operator
187
190
 
188
- * ==
191
+ * =
189
192
  * !=
190
193
  * START_WITH
191
194
  * END_WITH
192
195
  * INCLUDE
196
+ * REGEXP
193
197
 
194
198
  ### Timestamp Operator
195
199
 
196
- * ==
200
+ * =
197
201
  * !=
198
202
  * >
199
203
  * >=
data/build.gradle CHANGED
@@ -15,7 +15,7 @@ configurations {
15
15
  provided
16
16
  }
17
17
 
18
- version = "0.3.2"
18
+ version = "0.3.3"
19
19
  sourceCompatibility = 1.7
20
20
  targetCompatibility = 1.7
21
21
 
@@ -178,48 +178,55 @@ public final static short STRING=272;
178
178
  public final static short NUMBER=273;
179
179
  public final static short IDENTIFIER=274;
180
180
  public final static short TIMESTAMP=275;
181
+ public final static short REGEXP=276;
181
182
  public final static short YYERRCODE=256;
182
183
  final static short yylhs[] = { -1,
183
184
  0, 0, 2, 2, 1, 1, 1, 1, 1, 1,
184
185
  1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
185
186
  1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
186
187
  1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
187
- 1, 1, 1, 1, 1, 1, 1, 1,
188
+ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
189
+ 1, 1, 1, 1, 1, 1, 1,
188
190
  };
189
191
  final static short yylen[] = { 2,
190
192
  0, 1, 2, 2, 3, 3, 3, 3, 3, 3,
191
193
  3, 3, 3, 3, 3, 3, 3, 3, 3, 3,
192
194
  3, 3, 3, 3, 3, 3, 3, 3, 3, 3,
193
195
  3, 3, 3, 3, 3, 3, 3, 3, 3, 3,
194
- 3, 3, 3, 4, 3, 3, 2, 3,
196
+ 3, 3, 3, 3, 3, 3, 3, 3, 3, 3,
197
+ 3, 3, 4, 3, 3, 2, 3,
195
198
  };
196
199
  final static short yydefred[] = { 0,
197
200
  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
198
- 47, 0, 0, 0, 0, 0, 0, 0, 0, 0,
201
+ 56, 0, 0, 0, 0, 0, 0, 0, 0, 0,
199
202
  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
200
- 0, 0, 0, 0, 3, 4, 0, 0, 0, 0,
201
- 0, 0, 0, 0, 0, 7, 8, 26, 27, 28,
202
- 29, 30, 15, 16, 17, 18, 19, 20, 5, 21,
203
- 9, 31, 6, 22, 10, 32, 11, 33, 12, 34,
204
- 13, 35, 14, 36, 23, 24, 25, 0, 43, 48,
205
- 46, 0, 37, 38, 39, 40, 41, 42, 44,
203
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 3,
204
+ 4, 0, 0, 0, 0, 0, 0, 0, 0, 0,
205
+ 7, 8, 30, 31, 32, 33, 34, 35, 36, 37,
206
+ 38, 15, 16, 17, 18, 19, 20, 5, 21, 9,
207
+ 39, 6, 22, 10, 40, 23, 11, 41, 24, 12,
208
+ 42, 25, 13, 43, 26, 14, 44, 27, 28, 29,
209
+ 0, 52, 51, 57, 55, 0, 45, 46, 47, 48,
210
+ 49, 50, 53,
206
211
  };
207
212
  final static short yydgoto[] = { 8,
208
213
  9, 10,
209
214
  };
210
215
  final static short yysindex[] = { -40,
211
- -40, -234, -237, -228, -247, -208, -40, 0, -202, -214,
212
- 0, -215, -206, -205, -204, -203, -201, -200, -199, -198,
213
- -197, -196, -195, -194, -267, -236, -218, -217, -213, -212,
214
- -265, -191, -190, -245, 0, 0, -39, -40, -40, -189,
215
- -188, -187, -186, -185, -184, 0, 0, 0, 0, 0,
216
+ -40, -181, -237, -227, -247, -229, -40, 0, -190, -221,
217
+ 0, -200, -194, -193, -192, -191, -189, -188, -187, -186,
218
+ -185, -184, -183, -182, -180, -179, -178, -177, -267, -218,
219
+ -214, -210, -206, -202, -265, -216, -212, -195, -208, 0,
220
+ 0, -39, -40, -40, -176, -175, -174, -173, -172, -171,
221
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
222
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
216
223
  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
217
224
  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
218
- 0, 0, 0, 0, 0, 0, 0, -232, 0, 0,
219
- 0, -177, 0, 0, 0, 0, 0, 0, 0,
225
+ -166, 0, 0, 0, 0, -163, 0, 0, 0, 0,
226
+ 0, 0, 0,
220
227
  };
221
- final static short yyrindex[] = { 72,
222
- 0, 0, 0, 0, 0, 0, 0, 0, 83, 0,
228
+ final static short yyrindex[] = { 68,
229
+ 0, 0, 0, 0, 0, 0, 0, 0, 84, 0,
223
230
  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
224
231
  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
225
232
  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
@@ -227,27 +234,29 @@ final static short yyrindex[] = { 72,
227
234
  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
228
235
  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
229
236
  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
230
- 0, 1, 0, 0, 0, 0, 0, 0, 0,
237
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
238
+ 0, 0, 0, 0, 0, 1, 0, 0, 0, 0,
239
+ 0, 0, 0,
231
240
  };
232
241
  final static short yygindex[] = { 0,
233
- 2, 24,
242
+ 2, 18,
234
243
  };
235
244
  final static int YYTABLESIZE=270;
236
245
  static short yytable[];
237
246
  static { yytable();}
238
247
  static void yytable(){
239
248
  yytable = new short[]{ 7,
240
- 45, 80, 11, 59, 60, 61, 75, 6, 37, 25,
241
- 26, 27, 28, 29, 30, 31, 32, 33, 34, 14,
242
- 15, 78, 12, 13, 79, 16, 17, 18, 19, 20,
243
- 21, 22, 23, 24, 63, 64, 65, 89, 6, 81,
244
- 82, 45, 40, 41, 42, 43, 44, 45, 62, 66,
245
- 68, 70, 72, 74, 67, 69, 6, 6, 46, 71,
246
- 73, 6, 6, 35, 36, 38, 39, 47, 48, 49,
247
- 50, 1, 51, 52, 53, 54, 55, 56, 57, 58,
248
- 76, 77, 2, 0, 83, 84, 85, 86, 87, 88,
249
- 38, 0, 0, 0, 0, 0, 0, 0, 0, 0,
250
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
249
+ 54, 94, 11, 68, 69, 70, 88, 6, 42, 29,
250
+ 30, 31, 32, 33, 34, 35, 36, 37, 38, 14,
251
+ 15, 16, 17, 18, 19, 20, 21, 22, 39, 23,
252
+ 24, 25, 26, 27, 28, 45, 46, 47, 48, 49,
253
+ 50, 54, 40, 41, 95, 96, 71, 75, 78, 81,
254
+ 84, 87, 72, 73, 74, 89, 6, 76, 77, 90,
255
+ 6, 79, 80, 93, 6, 82, 83, 1, 6, 85,
256
+ 86, 91, 6, 51, 92, 12, 13, 43, 44, 52,
257
+ 53, 54, 55, 2, 56, 57, 58, 59, 60, 61,
258
+ 62, 63, 0, 64, 65, 66, 67, 97, 98, 99,
259
+ 100, 101, 102, 103, 43, 0, 0, 0, 0, 0,
251
260
  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
252
261
  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
253
262
  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
@@ -259,11 +268,11 @@ yytable = new short[]{ 7,
259
268
  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
260
269
  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
261
270
  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
262
- 0, 0, 0, 0, 0, 0, 1, 0, 38, 39,
271
+ 0, 0, 0, 0, 0, 0, 1, 0, 43, 44,
263
272
  2, 3, 4, 5, 6, 0, 0, 0, 0, 0,
264
273
  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
265
274
  0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
266
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 45,
275
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 54,
267
276
  };
268
277
  }
269
278
  static short yycheck[];
@@ -272,15 +281,15 @@ static void yycheck() {
272
281
  yycheck = new short[] { 40,
273
282
  0, 41, 1, 271, 272, 273, 272, 275, 7, 257,
274
283
  258, 259, 260, 261, 262, 263, 264, 265, 266, 257,
275
- 258, 267, 257, 258, 270, 263, 264, 265, 257, 258,
276
- 259, 260, 261, 262, 271, 272, 273, 270, 275, 38,
277
- 39, 41, 257, 258, 259, 260, 261, 262, 25, 26,
278
- 27, 28, 29, 30, 273, 273, 275, 275, 274, 273,
279
- 273, 275, 275, 272, 273, 268, 269, 274, 274, 274,
280
- 274, 0, 274, 274, 274, 274, 274, 274, 274, 274,
281
- 272, 272, 0, -1, 274, 274, 274, 274, 274, 274,
282
- 268, -1, -1, -1, -1, -1, -1, -1, -1, -1,
283
- -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
284
+ 258, 259, 260, 261, 262, 263, 264, 265, 276, 257,
285
+ 258, 259, 260, 261, 262, 257, 258, 259, 260, 261,
286
+ 262, 41, 272, 273, 43, 44, 29, 30, 31, 32,
287
+ 33, 34, 271, 272, 273, 272, 275, 272, 273, 272,
288
+ 275, 272, 273, 272, 275, 272, 273, 0, 275, 272,
289
+ 273, 267, 275, 274, 270, 257, 258, 268, 269, 274,
290
+ 274, 274, 274, 0, 274, 274, 274, 274, 274, 274,
291
+ 274, 274, -1, 274, 274, 274, 274, 274, 274, 274,
292
+ 274, 274, 274, 270, 268, -1, -1, -1, -1, -1,
284
293
  -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
285
294
  -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
286
295
  -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
@@ -300,7 +309,7 @@ yycheck = new short[] { 40,
300
309
  };
301
310
  }
302
311
  final static short YYFINAL=8;
303
- final static short YYMAXTOKEN=275;
312
+ final static short YYMAXTOKEN=276;
304
313
  final static String yyname[] = {
305
314
  "end-of-file",null,null,null,null,null,null,null,null,null,null,null,null,null,
306
315
  null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,
@@ -320,7 +329,7 @@ null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,
320
329
  null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,
321
330
  null,null,null,null,"EQ","NEQ","GT","GE","LT","LE","START_WITH","END_WITH",
322
331
  "INCLUDE","IS","NOT","AND","OR","NULL","BOOLEAN","STRING","NUMBER","IDENTIFIER",
323
- "TIMESTAMP",
332
+ "TIMESTAMP","REGEXP",
324
333
  };
325
334
  final static String yyrule[] = {
326
335
  "$accept : input",
@@ -346,11 +355,19 @@ final static String yyrule[] = {
346
355
  "exp : NUMBER LE IDENTIFIER",
347
356
  "exp : IDENTIFIER EQ STRING",
348
357
  "exp : IDENTIFIER NEQ STRING",
358
+ "exp : IDENTIFIER GT STRING",
359
+ "exp : IDENTIFIER GE STRING",
360
+ "exp : IDENTIFIER LT STRING",
361
+ "exp : IDENTIFIER LE STRING",
349
362
  "exp : IDENTIFIER START_WITH STRING",
350
363
  "exp : IDENTIFIER END_WITH STRING",
351
364
  "exp : IDENTIFIER INCLUDE STRING",
352
365
  "exp : STRING EQ IDENTIFIER",
353
366
  "exp : STRING NEQ IDENTIFIER",
367
+ "exp : STRING GT IDENTIFIER",
368
+ "exp : STRING GE IDENTIFIER",
369
+ "exp : STRING LT IDENTIFIER",
370
+ "exp : STRING LE IDENTIFIER",
354
371
  "exp : STRING START_WITH IDENTIFIER",
355
372
  "exp : STRING END_WITH IDENTIFIER",
356
373
  "exp : STRING INCLUDE IDENTIFIER",
@@ -366,6 +383,7 @@ final static String yyrule[] = {
366
383
  "exp : timestamp GE IDENTIFIER",
367
384
  "exp : timestamp LT IDENTIFIER",
368
385
  "exp : timestamp LE IDENTIFIER",
386
+ "exp : IDENTIFIER REGEXP STRING",
369
387
  "exp : IDENTIFIER IS NULL",
370
388
  "exp : IDENTIFIER IS NOT NULL",
371
389
  "exp : exp OR exp",
@@ -374,7 +392,7 @@ final static String yyrule[] = {
374
392
  "exp : '(' exp ')'",
375
393
  };
376
394
 
377
- //#line 92 "src/main/java/org/embulk/filter/row/where/_parser.y"
395
+ //#line 101 "src/main/java/org/embulk/filter/row/where/_parser.y"
378
396
 
379
397
  protected Schema schema;
380
398
  protected Yylex lexer;
@@ -413,7 +431,7 @@ void yyerror(String s)
413
431
  {
414
432
  throw new ConfigException("yyerror: " + s);
415
433
  }
416
- //#line 344 "Parser.java"
434
+ //#line 362 "Parser.java"
417
435
  //###############################################################
418
436
  // method: yylexdebug : check lexer state
419
437
  //###############################################################
@@ -581,181 +599,217 @@ case 4:
581
599
  break;
582
600
  case 5:
583
601
  //#line 46 "src/main/java/org/embulk/filter/row/where/_parser.y"
584
- { yyval = new ParserVal(new BooleanOpExp(val_peek(2), val_peek(0), EQ)); }
602
+ { yyval = new ParserVal(BinaryOpExp.create(val_peek(2), val_peek(0), EQ)); }
585
603
  break;
586
604
  case 6:
587
605
  //#line 47 "src/main/java/org/embulk/filter/row/where/_parser.y"
588
- { yyval = new ParserVal(new BooleanOpExp(val_peek(2), val_peek(0), NEQ)); }
606
+ { yyval = new ParserVal(BinaryOpExp.create(val_peek(2), val_peek(0), NEQ)); }
589
607
  break;
590
608
  case 7:
591
609
  //#line 48 "src/main/java/org/embulk/filter/row/where/_parser.y"
592
- { yyval = new ParserVal(new BooleanOpExp(val_peek(2), val_peek(0), EQ)); }
610
+ { yyval = new ParserVal(BinaryOpExp.create(val_peek(2), val_peek(0), EQ)); }
593
611
  break;
594
612
  case 8:
595
613
  //#line 49 "src/main/java/org/embulk/filter/row/where/_parser.y"
596
- { yyval = new ParserVal(new BooleanOpExp(val_peek(2), val_peek(0), NEQ)); }
614
+ { yyval = new ParserVal(BinaryOpExp.create(val_peek(2), val_peek(0), NEQ)); }
597
615
  break;
598
616
  case 9:
599
617
  //#line 50 "src/main/java/org/embulk/filter/row/where/_parser.y"
600
- { yyval = new ParserVal(new NumberOpExp(val_peek(2), val_peek(0), EQ)); }
618
+ { yyval = new ParserVal(BinaryOpExp.create(val_peek(2), val_peek(0), EQ)); }
601
619
  break;
602
620
  case 10:
603
621
  //#line 51 "src/main/java/org/embulk/filter/row/where/_parser.y"
604
- { yyval = new ParserVal(new NumberOpExp(val_peek(2), val_peek(0), NEQ)); }
622
+ { yyval = new ParserVal(BinaryOpExp.create(val_peek(2), val_peek(0), NEQ)); }
605
623
  break;
606
624
  case 11:
607
625
  //#line 52 "src/main/java/org/embulk/filter/row/where/_parser.y"
608
- { yyval = new ParserVal(new NumberOpExp(val_peek(2), val_peek(0), GT)); }
626
+ { yyval = new ParserVal(BinaryOpExp.create(val_peek(2), val_peek(0), GT)); }
609
627
  break;
610
628
  case 12:
611
629
  //#line 53 "src/main/java/org/embulk/filter/row/where/_parser.y"
612
- { yyval = new ParserVal(new NumberOpExp(val_peek(2), val_peek(0), GE)); }
630
+ { yyval = new ParserVal(BinaryOpExp.create(val_peek(2), val_peek(0), GE)); }
613
631
  break;
614
632
  case 13:
615
633
  //#line 54 "src/main/java/org/embulk/filter/row/where/_parser.y"
616
- { yyval = new ParserVal(new NumberOpExp(val_peek(2), val_peek(0), LT)); }
634
+ { yyval = new ParserVal(BinaryOpExp.create(val_peek(2), val_peek(0), LT)); }
617
635
  break;
618
636
  case 14:
619
637
  //#line 55 "src/main/java/org/embulk/filter/row/where/_parser.y"
620
- { yyval = new ParserVal(new NumberOpExp(val_peek(2), val_peek(0), LE)); }
638
+ { yyval = new ParserVal(BinaryOpExp.create(val_peek(2), val_peek(0), LE)); }
621
639
  break;
622
640
  case 15:
623
641
  //#line 56 "src/main/java/org/embulk/filter/row/where/_parser.y"
624
- { yyval = new ParserVal(new NumberOpExp(val_peek(2), val_peek(0), EQ)); }
642
+ { yyval = new ParserVal(BinaryOpExp.create(val_peek(2), val_peek(0), EQ)); }
625
643
  break;
626
644
  case 16:
627
645
  //#line 57 "src/main/java/org/embulk/filter/row/where/_parser.y"
628
- { yyval = new ParserVal(new NumberOpExp(val_peek(2), val_peek(0), NEQ)); }
646
+ { yyval = new ParserVal(BinaryOpExp.create(val_peek(2), val_peek(0), NEQ)); }
629
647
  break;
630
648
  case 17:
631
649
  //#line 58 "src/main/java/org/embulk/filter/row/where/_parser.y"
632
- { yyval = new ParserVal(new NumberOpExp(val_peek(2), val_peek(0), GT)); }
650
+ { yyval = new ParserVal(BinaryOpExp.create(val_peek(2), val_peek(0), GT)); }
633
651
  break;
634
652
  case 18:
635
653
  //#line 59 "src/main/java/org/embulk/filter/row/where/_parser.y"
636
- { yyval = new ParserVal(new NumberOpExp(val_peek(2), val_peek(0), GE)); }
654
+ { yyval = new ParserVal(BinaryOpExp.create(val_peek(2), val_peek(0), GE)); }
637
655
  break;
638
656
  case 19:
639
657
  //#line 60 "src/main/java/org/embulk/filter/row/where/_parser.y"
640
- { yyval = new ParserVal(new NumberOpExp(val_peek(2), val_peek(0), LT)); }
658
+ { yyval = new ParserVal(BinaryOpExp.create(val_peek(2), val_peek(0), LT)); }
641
659
  break;
642
660
  case 20:
643
661
  //#line 61 "src/main/java/org/embulk/filter/row/where/_parser.y"
644
- { yyval = new ParserVal(new NumberOpExp(val_peek(2), val_peek(0), LE)); }
662
+ { yyval = new ParserVal(BinaryOpExp.create(val_peek(2), val_peek(0), LE)); }
645
663
  break;
646
664
  case 21:
647
665
  //#line 62 "src/main/java/org/embulk/filter/row/where/_parser.y"
648
- { yyval = new ParserVal(new StringOpExp(val_peek(2), val_peek(0), EQ)); }
666
+ { yyval = new ParserVal(BinaryOpExp.create(val_peek(2), val_peek(0), EQ)); }
649
667
  break;
650
668
  case 22:
651
669
  //#line 63 "src/main/java/org/embulk/filter/row/where/_parser.y"
652
- { yyval = new ParserVal(new StringOpExp(val_peek(2), val_peek(0), NEQ)); }
670
+ { yyval = new ParserVal(BinaryOpExp.create(val_peek(2), val_peek(0), NEQ)); }
653
671
  break;
654
672
  case 23:
655
673
  //#line 64 "src/main/java/org/embulk/filter/row/where/_parser.y"
656
- { yyval = new ParserVal(new StringOpExp(val_peek(2), val_peek(0), START_WITH)); }
674
+ { yyval = new ParserVal(BinaryOpExp.create(val_peek(2), val_peek(0), GT)); }
657
675
  break;
658
676
  case 24:
659
677
  //#line 65 "src/main/java/org/embulk/filter/row/where/_parser.y"
660
- { yyval = new ParserVal(new StringOpExp(val_peek(2), val_peek(0), END_WITH)); }
678
+ { yyval = new ParserVal(BinaryOpExp.create(val_peek(2), val_peek(0), GE)); }
661
679
  break;
662
680
  case 25:
663
681
  //#line 66 "src/main/java/org/embulk/filter/row/where/_parser.y"
664
- { yyval = new ParserVal(new StringOpExp(val_peek(2), val_peek(0), INCLUDE)); }
682
+ { yyval = new ParserVal(BinaryOpExp.create(val_peek(2), val_peek(0), LT)); }
665
683
  break;
666
684
  case 26:
667
685
  //#line 67 "src/main/java/org/embulk/filter/row/where/_parser.y"
668
- { yyval = new ParserVal(new StringOpExp(val_peek(2), val_peek(0), EQ)); }
686
+ { yyval = new ParserVal(BinaryOpExp.create(val_peek(2), val_peek(0), LE)); }
669
687
  break;
670
688
  case 27:
671
689
  //#line 68 "src/main/java/org/embulk/filter/row/where/_parser.y"
672
- { yyval = new ParserVal(new StringOpExp(val_peek(2), val_peek(0), NEQ)); }
690
+ { yyval = new ParserVal(BinaryOpExp.create(val_peek(2), val_peek(0), START_WITH)); }
673
691
  break;
674
692
  case 28:
675
693
  //#line 69 "src/main/java/org/embulk/filter/row/where/_parser.y"
676
- { yyval = new ParserVal(new StringOpExp(val_peek(2), val_peek(0), START_WITH)); }
694
+ { yyval = new ParserVal(BinaryOpExp.create(val_peek(2), val_peek(0), END_WITH)); }
677
695
  break;
678
696
  case 29:
679
697
  //#line 70 "src/main/java/org/embulk/filter/row/where/_parser.y"
680
- { yyval = new ParserVal(new StringOpExp(val_peek(2), val_peek(0), END_WITH)); }
698
+ { yyval = new ParserVal(BinaryOpExp.create(val_peek(2), val_peek(0), INCLUDE)); }
681
699
  break;
682
700
  case 30:
683
701
  //#line 71 "src/main/java/org/embulk/filter/row/where/_parser.y"
684
- { yyval = new ParserVal(new StringOpExp(val_peek(2), val_peek(0), INCLUDE)); }
702
+ { yyval = new ParserVal(BinaryOpExp.create(val_peek(2), val_peek(0), EQ)); }
685
703
  break;
686
704
  case 31:
687
705
  //#line 72 "src/main/java/org/embulk/filter/row/where/_parser.y"
688
- { yyval = new ParserVal(new TimestampOpExp(val_peek(2), val_peek(0), EQ)); }
706
+ { yyval = new ParserVal(BinaryOpExp.create(val_peek(2), val_peek(0), NEQ)); }
689
707
  break;
690
708
  case 32:
691
709
  //#line 73 "src/main/java/org/embulk/filter/row/where/_parser.y"
692
- { yyval = new ParserVal(new TimestampOpExp(val_peek(2), val_peek(0), NEQ)); }
710
+ { yyval = new ParserVal(BinaryOpExp.create(val_peek(2), val_peek(0), GT)); }
693
711
  break;
694
712
  case 33:
695
713
  //#line 74 "src/main/java/org/embulk/filter/row/where/_parser.y"
696
- { yyval = new ParserVal(new TimestampOpExp(val_peek(2), val_peek(0), GT)); }
714
+ { yyval = new ParserVal(BinaryOpExp.create(val_peek(2), val_peek(0), GE)); }
697
715
  break;
698
716
  case 34:
699
717
  //#line 75 "src/main/java/org/embulk/filter/row/where/_parser.y"
700
- { yyval = new ParserVal(new TimestampOpExp(val_peek(2), val_peek(0), GE)); }
718
+ { yyval = new ParserVal(BinaryOpExp.create(val_peek(2), val_peek(0), LT)); }
701
719
  break;
702
720
  case 35:
703
721
  //#line 76 "src/main/java/org/embulk/filter/row/where/_parser.y"
704
- { yyval = new ParserVal(new TimestampOpExp(val_peek(2), val_peek(0), LT)); }
722
+ { yyval = new ParserVal(BinaryOpExp.create(val_peek(2), val_peek(0), LE)); }
705
723
  break;
706
724
  case 36:
707
725
  //#line 77 "src/main/java/org/embulk/filter/row/where/_parser.y"
708
- { yyval = new ParserVal(new TimestampOpExp(val_peek(2), val_peek(0), LE)); }
726
+ { yyval = new ParserVal(BinaryOpExp.create(val_peek(2), val_peek(0), START_WITH)); }
709
727
  break;
710
728
  case 37:
711
729
  //#line 78 "src/main/java/org/embulk/filter/row/where/_parser.y"
712
- { yyval = new ParserVal(new TimestampOpExp(val_peek(2), val_peek(0), EQ)); }
730
+ { yyval = new ParserVal(BinaryOpExp.create(val_peek(2), val_peek(0), END_WITH)); }
713
731
  break;
714
732
  case 38:
715
733
  //#line 79 "src/main/java/org/embulk/filter/row/where/_parser.y"
716
- { yyval = new ParserVal(new TimestampOpExp(val_peek(2), val_peek(0), NEQ)); }
734
+ { yyval = new ParserVal(BinaryOpExp.create(val_peek(2), val_peek(0), INCLUDE)); }
717
735
  break;
718
736
  case 39:
719
737
  //#line 80 "src/main/java/org/embulk/filter/row/where/_parser.y"
720
- { yyval = new ParserVal(new TimestampOpExp(val_peek(2), val_peek(0), GT)); }
738
+ { yyval = new ParserVal(BinaryOpExp.create(val_peek(2), val_peek(0), EQ)); }
721
739
  break;
722
740
  case 40:
723
741
  //#line 81 "src/main/java/org/embulk/filter/row/where/_parser.y"
724
- { yyval = new ParserVal(new TimestampOpExp(val_peek(2), val_peek(0), GE)); }
742
+ { yyval = new ParserVal(BinaryOpExp.create(val_peek(2), val_peek(0), NEQ)); }
725
743
  break;
726
744
  case 41:
727
745
  //#line 82 "src/main/java/org/embulk/filter/row/where/_parser.y"
728
- { yyval = new ParserVal(new TimestampOpExp(val_peek(2), val_peek(0), LT)); }
746
+ { yyval = new ParserVal(BinaryOpExp.create(val_peek(2), val_peek(0), GT)); }
729
747
  break;
730
748
  case 42:
731
749
  //#line 83 "src/main/java/org/embulk/filter/row/where/_parser.y"
732
- { yyval = new ParserVal(new TimestampOpExp(val_peek(2), val_peek(0), LE)); }
750
+ { yyval = new ParserVal(BinaryOpExp.create(val_peek(2), val_peek(0), GE)); }
733
751
  break;
734
752
  case 43:
735
753
  //#line 84 "src/main/java/org/embulk/filter/row/where/_parser.y"
736
- { yyval = new ParserVal(new NullOpExp(val_peek(2), EQ)); }
754
+ { yyval = new ParserVal(BinaryOpExp.create(val_peek(2), val_peek(0), LT)); }
737
755
  break;
738
756
  case 44:
739
757
  //#line 85 "src/main/java/org/embulk/filter/row/where/_parser.y"
740
- { yyval = new ParserVal(new NullOpExp(val_peek(3), NEQ)); }
758
+ { yyval = new ParserVal(BinaryOpExp.create(val_peek(2), val_peek(0), LE)); }
741
759
  break;
742
760
  case 45:
743
761
  //#line 86 "src/main/java/org/embulk/filter/row/where/_parser.y"
744
- { yyval = new ParserVal(new LogicalOpExp(val_peek(2), val_peek(0), OR)); }
762
+ { yyval = new ParserVal(BinaryOpExp.create(val_peek(2), val_peek(0), EQ)); }
745
763
  break;
746
764
  case 46:
747
765
  //#line 87 "src/main/java/org/embulk/filter/row/where/_parser.y"
748
- { yyval = new ParserVal(new LogicalOpExp(val_peek(2), val_peek(0), AND)); }
766
+ { yyval = new ParserVal(BinaryOpExp.create(val_peek(2), val_peek(0), NEQ)); }
749
767
  break;
750
768
  case 47:
751
769
  //#line 88 "src/main/java/org/embulk/filter/row/where/_parser.y"
752
- { yyval = new ParserVal(new NegateOpExp(val_peek(0))); }
770
+ { yyval = new ParserVal(BinaryOpExp.create(val_peek(2), val_peek(0), GT)); }
753
771
  break;
754
772
  case 48:
755
773
  //#line 89 "src/main/java/org/embulk/filter/row/where/_parser.y"
774
+ { yyval = new ParserVal(BinaryOpExp.create(val_peek(2), val_peek(0), GE)); }
775
+ break;
776
+ case 49:
777
+ //#line 90 "src/main/java/org/embulk/filter/row/where/_parser.y"
778
+ { yyval = new ParserVal(BinaryOpExp.create(val_peek(2), val_peek(0), LT)); }
779
+ break;
780
+ case 50:
781
+ //#line 91 "src/main/java/org/embulk/filter/row/where/_parser.y"
782
+ { yyval = new ParserVal(BinaryOpExp.create(val_peek(2), val_peek(0), LE)); }
783
+ break;
784
+ case 51:
785
+ //#line 92 "src/main/java/org/embulk/filter/row/where/_parser.y"
786
+ { yyval = new ParserVal(new RegexpOpExp(val_peek(2), val_peek(0), REGEXP)); }
787
+ break;
788
+ case 52:
789
+ //#line 93 "src/main/java/org/embulk/filter/row/where/_parser.y"
790
+ { yyval = new ParserVal(new NullOpExp(val_peek(2), EQ)); }
791
+ break;
792
+ case 53:
793
+ //#line 94 "src/main/java/org/embulk/filter/row/where/_parser.y"
794
+ { yyval = new ParserVal(new NullOpExp(val_peek(3), NEQ)); }
795
+ break;
796
+ case 54:
797
+ //#line 95 "src/main/java/org/embulk/filter/row/where/_parser.y"
798
+ { yyval = new ParserVal(new LogicalOpExp(val_peek(2), val_peek(0), OR)); }
799
+ break;
800
+ case 55:
801
+ //#line 96 "src/main/java/org/embulk/filter/row/where/_parser.y"
802
+ { yyval = new ParserVal(new LogicalOpExp(val_peek(2), val_peek(0), AND)); }
803
+ break;
804
+ case 56:
805
+ //#line 97 "src/main/java/org/embulk/filter/row/where/_parser.y"
806
+ { yyval = new ParserVal(new NegateOpExp(val_peek(0))); }
807
+ break;
808
+ case 57:
809
+ //#line 98 "src/main/java/org/embulk/filter/row/where/_parser.y"
756
810
  { yyval = val_peek(1); }
757
811
  break;
758
- //#line 681 "Parser.java"
812
+ //#line 735 "Parser.java"
759
813
  //########## END OF USER-SUPPLIED ACTIONS ##########
760
814
  }//switch
761
815
  //#### Now let's reduce... ####