Commit 1c9a1250 authored by Bruce Momjian's avatar Bruce Momjian

OR processing cleanup.

parent f26e1d39
...@@ -7,7 +7,7 @@ ...@@ -7,7 +7,7 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/executor/nodeIndexscan.c,v 1.22 1998/08/03 19:41:29 momjian Exp $ * $Header: /cvsroot/pgsql/src/backend/executor/nodeIndexscan.c,v 1.23 1998/08/04 18:42:38 momjian Exp $
* *
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
...@@ -269,33 +269,36 @@ ExecIndexReScan(IndexScan *node, ExprContext *exprCtxt, Plan *parent) ...@@ -269,33 +269,36 @@ ExecIndexReScan(IndexScan *node, ExprContext *exprCtxt, Plan *parent)
{ {
qual = nth(i, indxqual); qual = nth(i, indxqual);
n_keys = numScanKeys[i]; n_keys = numScanKeys[i];
run_keys = (int *) runtimeKeyInfo[i];
scan_keys = (ScanKey) scanKeys[i]; scan_keys = (ScanKey) scanKeys[i];
for (j = 0; j < n_keys; j++) if (runtimeKeyInfo)
{ {
/* run_keys = (int *) runtimeKeyInfo[i];
* If we have a run-time key, then extract the run-time for (j = 0; j < n_keys; j++)
* expression and evaluate it with respect to the current
* outer tuple. We then stick the result into the scan key.
*/
if (run_keys[j] != NO_OP)
{ {
clause = nth(j, qual);
scanexpr = (run_keys[j] == RIGHT_OP) ?
(Node *) get_rightop(clause) : (Node *) get_leftop(clause);
/* /*
* pass in isDone but ignore it. We don't iterate in * If we have a run-time key, then extract the run-time
* quals * expression and evaluate it with respect to the current
* outer tuple. We then stick the result into the scan key.
*/ */
scanvalue = (Datum) if (run_keys[j] != NO_OP)
ExecEvalExpr(scanexpr, exprCtxt, &isNull, &isDone); {
scan_keys[j].sk_argument = scanvalue; clause = nth(j, qual);
if (isNull) scanexpr = (run_keys[j] == RIGHT_OP) ?
scan_keys[j].sk_flags |= SK_ISNULL; (Node *) get_rightop(clause) : (Node *) get_leftop(clause);
else
scan_keys[j].sk_flags &= ~SK_ISNULL; /*
* pass in isDone but ignore it. We don't iterate in
* quals
*/
scanvalue = (Datum)
ExecEvalExpr(scanexpr, exprCtxt, &isNull, &isDone);
scan_keys[j].sk_argument = scanvalue;
if (isNull)
scan_keys[j].sk_flags |= SK_ISNULL;
else
scan_keys[j].sk_flags &= ~SK_ISNULL;
}
} }
} }
sdesc = scanDescs[i]; sdesc = scanDescs[i];
......
...@@ -219,7 +219,7 @@ ...@@ -219,7 +219,7 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/parser/Attic/gram.c,v 2.22 1998/08/01 22:44:55 momjian Exp $ * $Header: /cvsroot/pgsql/src/backend/parser/Attic/gram.c,v 2.23 1998/08/04 18:42:39 momjian Exp $
* *
* HISTORY * HISTORY
* AUTHOR DATE MAJOR EVENT * AUTHOR DATE MAJOR EVENT
...@@ -795,54 +795,54 @@ static const short yyrline[] = { 0, ...@@ -795,54 +795,54 @@ static const short yyrline[] = { 0,
1847, 1849, 1851, 1864, 1876, 1877, 1880, 1881, 1894, 1896, 1847, 1849, 1851, 1864, 1876, 1877, 1880, 1881, 1894, 1896,
1910, 1911, 1912, 1915, 1917, 1921, 1923, 1925, 1929, 1937, 1910, 1911, 1912, 1915, 1917, 1921, 1923, 1925, 1929, 1937,
1948, 1949, 1950, 1951, 1954, 1955, 1967, 1975, 1997, 2003, 1948, 1949, 1950, 1951, 1954, 1955, 1967, 1975, 1997, 2003,
2009, 2015, 2021, 2029, 2030, 2031, 2042, 2063, 2079, 2101, 2009, 2015, 2021, 2029, 2030, 2031, 2042, 2063, 2079, 2102,
2113, 2114, 2117, 2118, 2121, 2122, 2123, 2126, 2127, 2128, 2114, 2115, 2118, 2119, 2122, 2123, 2124, 2127, 2128, 2129,
2138, 2154, 2171, 2180, 2193, 2194, 2197, 2198, 2201, 2202, 2139, 2155, 2172, 2181, 2194, 2195, 2198, 2199, 2202, 2203,
2205, 2207, 2219, 2240, 2241, 2242, 2243, 2244, 2245, 2256, 2206, 2208, 2220, 2241, 2242, 2243, 2244, 2245, 2246, 2257,
2264, 2275, 2291, 2292, 2295, 2298, 2302, 2319, 2334, 2359, 2265, 2276, 2292, 2293, 2296, 2299, 2303, 2320, 2335, 2360,
2380, 2421, 2440, 2457, 2463, 2467, 2473, 2477, 2493, 2494, 2381, 2422, 2441, 2458, 2464, 2468, 2474, 2478, 2494, 2495,
2497, 2498, 2501, 2502, 2505, 2506, 2507, 2508, 2511, 2512, 2498, 2499, 2502, 2503, 2506, 2507, 2508, 2509, 2512, 2513,
2515, 2516, 2519, 2527, 2535, 2545, 2546, 2547, 2548, 2549, 2516, 2517, 2520, 2528, 2536, 2546, 2547, 2548, 2549, 2550,
2550, 2560, 2561, 2564, 2566, 2568, 2572, 2573, 2576, 2577, 2551, 2561, 2562, 2565, 2567, 2569, 2573, 2574, 2577, 2578,
2580, 2588, 2596, 2606, 2610, 2622, 2627, 2628, 2631, 2633, 2581, 2589, 2597, 2607, 2611, 2623, 2628, 2629, 2632, 2634,
2635, 2639, 2645, 2651, 2659, 2660, 2662, 2664, 2666, 2668, 2636, 2640, 2646, 2652, 2660, 2661, 2663, 2665, 2667, 2669,
2670, 2672, 2676, 2677, 2680, 2681, 2682, 2685, 2686, 2689, 2671, 2673, 2677, 2678, 2681, 2682, 2683, 2686, 2687, 2690,
2697, 2705, 2715, 2716, 2719, 2726, 2734, 2736, 2738, 2742, 2698, 2706, 2716, 2717, 2720, 2727, 2735, 2737, 2739, 2743,
2744, 2746, 2761, 2783, 2784, 2791, 2792, 2793, 2796, 2804, 2745, 2747, 2762, 2784, 2785, 2792, 2793, 2794, 2797, 2805,
2805, 2814, 2820, 2825, 2831, 2839, 2841, 2843, 2845, 2849, 2806, 2815, 2821, 2826, 2832, 2840, 2842, 2844, 2846, 2850,
2860, 2866, 2873, 2878, 2884, 2892, 2898, 2911, 2938, 2957, 2861, 2867, 2874, 2879, 2885, 2893, 2899, 2912, 2939, 2958,
2977, 2978, 2979, 2980, 2983, 2984, 2987, 2988, 2991, 2992, 2978, 2979, 2980, 2981, 2984, 2985, 2988, 2989, 2992, 2993,
2995, 3001, 3008, 3014, 3022, 3023, 3024, 3025, 3026, 3027, 2996, 3002, 3009, 3015, 3023, 3024, 3025, 3026, 3027, 3028,
3030, 3031, 3034, 3035, 3036, 3037, 3038, 3039, 3040, 3041, 3031, 3032, 3035, 3036, 3037, 3038, 3039, 3040, 3041, 3042,
3042, 3052, 3054, 3071, 3081, 3091, 3104, 3117, 3123, 3129, 3043, 3053, 3055, 3072, 3082, 3092, 3105, 3118, 3124, 3130,
3133, 3139, 3140, 3141, 3142, 3143, 3144, 3145, 3146, 3149, 3134, 3140, 3141, 3142, 3143, 3144, 3145, 3146, 3147, 3150,
3150, 3161, 3166, 3168, 3170, 3178, 3180, 3182, 3184, 3186, 3151, 3162, 3167, 3169, 3171, 3179, 3181, 3183, 3185, 3187,
3188, 3190, 3192, 3194, 3196, 3198, 3200, 3216, 3232, 3234, 3189, 3191, 3193, 3195, 3197, 3199, 3201, 3217, 3233, 3235,
3236, 3238, 3240, 3242, 3244, 3256, 3263, 3270, 3285, 3300, 3237, 3239, 3241, 3243, 3245, 3257, 3264, 3271, 3286, 3301,
3322, 3337, 3359, 3366, 3373, 3383, 3390, 3397, 3405, 3412, 3323, 3338, 3360, 3367, 3374, 3384, 3391, 3398, 3406, 3413,
3419, 3426, 3433, 3435, 3437, 3439, 3446, 3456, 3466, 3476, 3420, 3427, 3434, 3436, 3438, 3440, 3447, 3457, 3467, 3477,
3486, 3492, 3498, 3498, 3512, 3512, 3526, 3536, 3546, 3556, 3487, 3493, 3499, 3499, 3513, 3513, 3527, 3537, 3547, 3557,
3566, 3576, 3586, 3596, 3606, 3616, 3626, 3636, 3646, 3656, 3567, 3577, 3587, 3597, 3607, 3617, 3627, 3637, 3647, 3657,
3666, 3676, 3686, 3696, 3706, 3716, 3726, 3736, 3746, 3756, 3667, 3677, 3687, 3697, 3707, 3717, 3727, 3737, 3747, 3757,
3766, 3768, 3770, 3780, 3785, 3787, 3795, 3797, 3799, 3801, 3767, 3769, 3771, 3781, 3786, 3788, 3796, 3798, 3800, 3802,
3803, 3805, 3807, 3809, 3811, 3827, 3843, 3845, 3847, 3849, 3804, 3806, 3808, 3810, 3812, 3828, 3844, 3846, 3848, 3850,
3851, 3858, 3865, 3880, 3895, 3917, 3932, 3954, 3961, 3968, 3852, 3859, 3866, 3881, 3896, 3918, 3933, 3955, 3962, 3969,
3975, 3983, 3990, 3997, 4004, 4013, 4020, 4027, 4031, 4033, 3976, 3984, 3991, 3998, 4005, 4014, 4021, 4028, 4032, 4034,
4035, 4039, 4046, 4050, 4051, 4052, 4055, 4057, 4061, 4066, 4036, 4040, 4047, 4051, 4052, 4053, 4056, 4058, 4062, 4067,
4068, 4070, 4072, 4074, 4076, 4078, 4080, 4096, 4112, 4114, 4069, 4071, 4073, 4075, 4077, 4079, 4081, 4097, 4113, 4115,
4116, 4118, 4120, 4128, 4135, 4142, 4149, 4157, 4164, 4171, 4117, 4119, 4121, 4129, 4136, 4143, 4150, 4158, 4165, 4172,
4178, 4187, 4191, 4195, 4197, 4206, 4208, 4212, 4214, 4216, 4179, 4188, 4192, 4196, 4198, 4207, 4209, 4213, 4215, 4217,
4220, 4226, 4230, 4232, 4238, 4244, 4248, 4250, 4256, 4264, 4221, 4227, 4231, 4233, 4239, 4245, 4249, 4251, 4257, 4265,
4274, 4276, 4278, 4289, 4291, 4293, 4308, 4315, 4322, 4341, 4275, 4277, 4279, 4290, 4292, 4294, 4309, 4316, 4323, 4342,
4343, 4348, 4355, 4362, 4374, 4388, 4389, 4392, 4397, 4409, 4344, 4349, 4356, 4363, 4375, 4389, 4390, 4393, 4398, 4410,
4410, 4411, 4412, 4413, 4419, 4420, 4422, 4423, 4428, 4435, 4411, 4412, 4413, 4414, 4420, 4421, 4423, 4424, 4429, 4436,
4442, 4449, 4457, 4459, 4469, 4481, 4488, 4489, 4490, 4497, 4443, 4450, 4458, 4460, 4470, 4482, 4489, 4490, 4491, 4498,
4499, 4501, 4512, 4513, 4514, 4515, 4516, 4517, 4518, 4519, 4500, 4502, 4513, 4514, 4515, 4516, 4517, 4518, 4519, 4520,
4520, 4521, 4522, 4523, 4524, 4525, 4526, 4527, 4528, 4529, 4521, 4522, 4523, 4524, 4525, 4526, 4527, 4528, 4529, 4530,
4530, 4531, 4532, 4533, 4534, 4535, 4536, 4537, 4538, 4539, 4531, 4532, 4533, 4534, 4535, 4536, 4537, 4538, 4539, 4540,
4540, 4541, 4542, 4543, 4544, 4545, 4546, 4559, 4560, 4561, 4541, 4542, 4543, 4544, 4545, 4546, 4547, 4560, 4561, 4562,
4562, 4563, 4564, 4565, 4566, 4567, 4568, 4569, 4570, 4571, 4563, 4564, 4565, 4566, 4567, 4568, 4569, 4570, 4571, 4572,
4572, 4573, 4576, 4583 4573, 4574, 4577, 4584
}; };
#endif #endif
...@@ -6403,13 +6403,14 @@ case 389: ...@@ -6403,13 +6403,14 @@ case 389:
n->encoding = GetTemplateEncoding(); n->encoding = GetTemplateEncoding();
} }
#else #else
elog(ERROR, "WITH ENCODING is not supported"); if (yyvsp[0].str != NULL)
elog(ERROR, "WITH ENCODING is not supported");
#endif #endif
yyval.node = (Node *)n; yyval.node = (Node *)n;
; ;
break;} break;}
case 390: case 390:
#line 2102 "gram.y" #line 2103 "gram.y"
{ {
CreatedbStmt *n = makeNode(CreatedbStmt); CreatedbStmt *n = makeNode(CreatedbStmt);
n->dbname = yyvsp[0].str; n->dbname = yyvsp[0].str;
...@@ -6421,47 +6422,47 @@ case 390: ...@@ -6421,47 +6422,47 @@ case 390:
; ;
break;} break;}
case 391: case 391:
#line 2113 "gram.y" #line 2114 "gram.y"
{ yyval.str = yyvsp[0].str; ; { yyval.str = yyvsp[0].str; ;
break;} break;}
case 392: case 392:
#line 2114 "gram.y" #line 2115 "gram.y"
{ yyval.str = NULL; ; { yyval.str = NULL; ;
break;} break;}
case 393: case 393:
#line 2117 "gram.y" #line 2118 "gram.y"
{ yyval.str = yyvsp[0].str; ; { yyval.str = yyvsp[0].str; ;
break;} break;}
case 394: case 394:
#line 2118 "gram.y" #line 2119 "gram.y"
{ yyval.str = NULL; ; { yyval.str = NULL; ;
break;} break;}
case 395: case 395:
#line 2121 "gram.y" #line 2122 "gram.y"
{ yyval.str = yyvsp[0].str; ; { yyval.str = yyvsp[0].str; ;
break;} break;}
case 396: case 396:
#line 2122 "gram.y" #line 2123 "gram.y"
{ yyval.str = NULL; ; { yyval.str = NULL; ;
break;} break;}
case 397: case 397:
#line 2123 "gram.y" #line 2124 "gram.y"
{ yyval.str = NULL; ; { yyval.str = NULL; ;
break;} break;}
case 398: case 398:
#line 2126 "gram.y" #line 2127 "gram.y"
{ yyval.str = yyvsp[0].str; ; { yyval.str = yyvsp[0].str; ;
break;} break;}
case 399: case 399:
#line 2127 "gram.y" #line 2128 "gram.y"
{ yyval.str = NULL; ; { yyval.str = NULL; ;
break;} break;}
case 400: case 400:
#line 2128 "gram.y" #line 2129 "gram.y"
{ yyval.str = NULL; ; { yyval.str = NULL; ;
break;} break;}
case 401: case 401:
#line 2139 "gram.y" #line 2140 "gram.y"
{ {
DestroydbStmt *n = makeNode(DestroydbStmt); DestroydbStmt *n = makeNode(DestroydbStmt);
n->dbname = yyvsp[0].str; n->dbname = yyvsp[0].str;
...@@ -6469,7 +6470,7 @@ case 401: ...@@ -6469,7 +6470,7 @@ case 401:
; ;
break;} break;}
case 402: case 402:
#line 2155 "gram.y" #line 2156 "gram.y"
{ {
ClusterStmt *n = makeNode(ClusterStmt); ClusterStmt *n = makeNode(ClusterStmt);
n->relname = yyvsp[0].str; n->relname = yyvsp[0].str;
...@@ -6478,7 +6479,7 @@ case 402: ...@@ -6478,7 +6479,7 @@ case 402:
; ;
break;} break;}
case 403: case 403:
#line 2172 "gram.y" #line 2173 "gram.y"
{ {
VacuumStmt *n = makeNode(VacuumStmt); VacuumStmt *n = makeNode(VacuumStmt);
n->verbose = yyvsp[-1].boolean; n->verbose = yyvsp[-1].boolean;
...@@ -6489,7 +6490,7 @@ case 403: ...@@ -6489,7 +6490,7 @@ case 403:
; ;
break;} break;}
case 404: case 404:
#line 2181 "gram.y" #line 2182 "gram.y"
{ {
VacuumStmt *n = makeNode(VacuumStmt); VacuumStmt *n = makeNode(VacuumStmt);
n->verbose = yyvsp[-3].boolean; n->verbose = yyvsp[-3].boolean;
...@@ -6502,39 +6503,39 @@ case 404: ...@@ -6502,39 +6503,39 @@ case 404:
; ;
break;} break;}
case 405: case 405:
#line 2193 "gram.y" #line 2194 "gram.y"
{ yyval.boolean = TRUE; ; { yyval.boolean = TRUE; ;
break;} break;}
case 406: case 406:
#line 2194 "gram.y" #line 2195 "gram.y"
{ yyval.boolean = FALSE; ; { yyval.boolean = FALSE; ;
break;} break;}
case 407: case 407:
#line 2197 "gram.y" #line 2198 "gram.y"
{ yyval.boolean = TRUE; ; { yyval.boolean = TRUE; ;
break;} break;}
case 408: case 408:
#line 2198 "gram.y" #line 2199 "gram.y"
{ yyval.boolean = FALSE; ; { yyval.boolean = FALSE; ;
break;} break;}
case 409: case 409:
#line 2201 "gram.y" #line 2202 "gram.y"
{ yyval.list = yyvsp[-1].list; ; { yyval.list = yyvsp[-1].list; ;
break;} break;}
case 410: case 410:
#line 2202 "gram.y" #line 2203 "gram.y"
{ yyval.list = NIL; ; { yyval.list = NIL; ;
break;} break;}
case 411: case 411:
#line 2206 "gram.y" #line 2207 "gram.y"
{ yyval.list=lcons(yyvsp[0].str,NIL); ; { yyval.list=lcons(yyvsp[0].str,NIL); ;
break;} break;}
case 412: case 412:
#line 2208 "gram.y" #line 2209 "gram.y"
{ yyval.list=lappend(yyvsp[-2].list,yyvsp[0].str); ; { yyval.list=lappend(yyvsp[-2].list,yyvsp[0].str); ;
break;} break;}
case 413: case 413:
#line 2220 "gram.y" #line 2221 "gram.y"
{ {
ExplainStmt *n = makeNode(ExplainStmt); ExplainStmt *n = makeNode(ExplainStmt);
n->verbose = yyvsp[-1].boolean; n->verbose = yyvsp[-1].boolean;
...@@ -6543,7 +6544,7 @@ case 413: ...@@ -6543,7 +6544,7 @@ case 413:
; ;
break;} break;}
case 420: case 420:
#line 2257 "gram.y" #line 2258 "gram.y"
{ {
yyvsp[0].astmt->relname = yyvsp[-2].str; yyvsp[0].astmt->relname = yyvsp[-2].str;
yyvsp[0].astmt->cols = yyvsp[-1].list; yyvsp[0].astmt->cols = yyvsp[-1].list;
...@@ -6551,7 +6552,7 @@ case 420: ...@@ -6551,7 +6552,7 @@ case 420:
; ;
break;} break;}
case 421: case 421:
#line 2265 "gram.y" #line 2266 "gram.y"
{ {
yyval.astmt = makeNode(InsertStmt); yyval.astmt = makeNode(InsertStmt);
yyval.astmt->unique = NULL; yyval.astmt->unique = NULL;
...@@ -6564,7 +6565,7 @@ case 421: ...@@ -6564,7 +6565,7 @@ case 421:
; ;
break;} break;}
case 422: case 422:
#line 2279 "gram.y" #line 2280 "gram.y"
{ {
yyval.astmt = makeNode(InsertStmt); yyval.astmt = makeNode(InsertStmt);
yyval.astmt->unique = yyvsp[-6].str; yyval.astmt->unique = yyvsp[-6].str;
...@@ -6577,23 +6578,23 @@ case 422: ...@@ -6577,23 +6578,23 @@ case 422:
; ;
break;} break;}
case 423: case 423:
#line 2291 "gram.y" #line 2292 "gram.y"
{ yyval.list = yyvsp[-1].list; ; { yyval.list = yyvsp[-1].list; ;
break;} break;}
case 424: case 424:
#line 2292 "gram.y" #line 2293 "gram.y"
{ yyval.list = NIL; ; { yyval.list = NIL; ;
break;} break;}
case 425: case 425:
#line 2297 "gram.y" #line 2298 "gram.y"
{ yyval.list = lappend(yyvsp[-2].list, yyvsp[0].node); ; { yyval.list = lappend(yyvsp[-2].list, yyvsp[0].node); ;
break;} break;}
case 426: case 426:
#line 2299 "gram.y" #line 2300 "gram.y"
{ yyval.list = lcons(yyvsp[0].node, NIL); ; { yyval.list = lcons(yyvsp[0].node, NIL); ;
break;} break;}
case 427: case 427:
#line 2303 "gram.y" #line 2304 "gram.y"
{ {
Ident *id = makeNode(Ident); Ident *id = makeNode(Ident);
id->name = yyvsp[-1].str; id->name = yyvsp[-1].str;
...@@ -6602,7 +6603,7 @@ case 427: ...@@ -6602,7 +6603,7 @@ case 427:
; ;
break;} break;}
case 428: case 428:
#line 2321 "gram.y" #line 2322 "gram.y"
{ {
DeleteStmt *n = makeNode(DeleteStmt); DeleteStmt *n = makeNode(DeleteStmt);
n->relname = yyvsp[-1].str; n->relname = yyvsp[-1].str;
...@@ -6611,7 +6612,7 @@ case 428: ...@@ -6611,7 +6612,7 @@ case 428:
; ;
break;} break;}
case 429: case 429:
#line 2335 "gram.y" #line 2336 "gram.y"
{ {
DeleteStmt *n = makeNode(DeleteStmt); DeleteStmt *n = makeNode(DeleteStmt);
A_Const *c = makeNode(A_Const); A_Const *c = makeNode(A_Const);
...@@ -6628,7 +6629,7 @@ case 429: ...@@ -6628,7 +6629,7 @@ case 429:
; ;
break;} break;}
case 430: case 430:
#line 2363 "gram.y" #line 2364 "gram.y"
{ {
UpdateStmt *n = makeNode(UpdateStmt); UpdateStmt *n = makeNode(UpdateStmt);
n->relname = yyvsp[-4].str; n->relname = yyvsp[-4].str;
...@@ -6639,7 +6640,7 @@ case 430: ...@@ -6639,7 +6640,7 @@ case 430:
; ;
break;} break;}
case 431: case 431:
#line 2385 "gram.y" #line 2386 "gram.y"
{ {
SelectStmt *n = makeNode(SelectStmt); SelectStmt *n = makeNode(SelectStmt);
...@@ -6668,7 +6669,7 @@ case 431: ...@@ -6668,7 +6669,7 @@ case 431:
; ;
break;} break;}
case 432: case 432:
#line 2425 "gram.y" #line 2426 "gram.y"
{ {
SelectStmt *n = makeNode(SelectStmt); SelectStmt *n = makeNode(SelectStmt);
n->unique = yyvsp[-8].str; n->unique = yyvsp[-8].str;
...@@ -6684,7 +6685,7 @@ case 432: ...@@ -6684,7 +6685,7 @@ case 432:
; ;
break;} break;}
case 433: case 433:
#line 2444 "gram.y" #line 2445 "gram.y"
{ {
SelectStmt *n = makeNode(SelectStmt); SelectStmt *n = makeNode(SelectStmt);
n->unique = yyvsp[-6].str; n->unique = yyvsp[-6].str;
...@@ -6698,7 +6699,7 @@ case 433: ...@@ -6698,7 +6699,7 @@ case 433:
; ;
break;} break;}
case 434: case 434:
#line 2458 "gram.y" #line 2459 "gram.y"
{ {
SelectStmt *n = (SelectStmt *)lfirst(yyvsp[0].list); SelectStmt *n = (SelectStmt *)lfirst(yyvsp[0].list);
n->unionall = yyvsp[-1].boolean; n->unionall = yyvsp[-1].boolean;
...@@ -6706,11 +6707,11 @@ case 434: ...@@ -6706,11 +6707,11 @@ case 434:
; ;
break;} break;}
case 435: case 435:
#line 2464 "gram.y" #line 2465 "gram.y"
{ yyval.list = NIL; ; { yyval.list = NIL; ;
break;} break;}
case 436: case 436:
#line 2468 "gram.y" #line 2469 "gram.y"
{ {
SelectStmt *n = (SelectStmt *)yyvsp[0].node; SelectStmt *n = (SelectStmt *)yyvsp[0].node;
n->unionall = yyvsp[-1].boolean; n->unionall = yyvsp[-1].boolean;
...@@ -6718,11 +6719,11 @@ case 436: ...@@ -6718,11 +6719,11 @@ case 436:
; ;
break;} break;}
case 437: case 437:
#line 2474 "gram.y" #line 2475 "gram.y"
{ yyval.list = lcons(yyvsp[0].node, NIL); ; { yyval.list = lcons(yyvsp[0].node, NIL); ;
break;} break;}
case 438: case 438:
#line 2480 "gram.y" #line 2481 "gram.y"
{ {
SelectStmt *n = makeNode(SelectStmt); SelectStmt *n = makeNode(SelectStmt);
n->unique = yyvsp[-5].str; n->unique = yyvsp[-5].str;
...@@ -6736,63 +6737,63 @@ case 438: ...@@ -6736,63 +6737,63 @@ case 438:
; ;
break;} break;}
case 439: case 439:
#line 2493 "gram.y" #line 2494 "gram.y"
{ yyval.str= yyvsp[0].str; ; { yyval.str= yyvsp[0].str; ;
break;} break;}
case 440: case 440:
#line 2494 "gram.y" #line 2495 "gram.y"
{ yyval.str = NULL; ; { yyval.str = NULL; ;
break;} break;}
case 441: case 441:
#line 2497 "gram.y" #line 2498 "gram.y"
{ yyval.boolean = TRUE; ; { yyval.boolean = TRUE; ;
break;} break;}
case 442: case 442:
#line 2498 "gram.y" #line 2499 "gram.y"
{ yyval.boolean = FALSE; ; { yyval.boolean = FALSE; ;
break;} break;}
case 443: case 443:
#line 2501 "gram.y" #line 2502 "gram.y"
{ yyval.boolean = TRUE; ; { yyval.boolean = TRUE; ;
break;} break;}
case 444: case 444:
#line 2502 "gram.y" #line 2503 "gram.y"
{ yyval.boolean = FALSE; ; { yyval.boolean = FALSE; ;
break;} break;}
case 445: case 445:
#line 2505 "gram.y" #line 2506 "gram.y"
{ yyval.str = "*"; ; { yyval.str = "*"; ;
break;} break;}
case 446: case 446:
#line 2506 "gram.y" #line 2507 "gram.y"
{ yyval.str = yyvsp[0].str; ; { yyval.str = yyvsp[0].str; ;
break;} break;}
case 447: case 447:
#line 2507 "gram.y" #line 2508 "gram.y"
{ yyval.str = NULL; ; { yyval.str = NULL; ;
break;} break;}
case 448: case 448:
#line 2508 "gram.y" #line 2509 "gram.y"
{ yyval.str = NULL; ; { yyval.str = NULL; ;
break;} break;}
case 449: case 449:
#line 2511 "gram.y" #line 2512 "gram.y"
{ yyval.list = yyvsp[0].list; ; { yyval.list = yyvsp[0].list; ;
break;} break;}
case 450: case 450:
#line 2512 "gram.y" #line 2513 "gram.y"
{ yyval.list = NIL; ; { yyval.list = NIL; ;
break;} break;}
case 451: case 451:
#line 2515 "gram.y" #line 2516 "gram.y"
{ yyval.list = lcons(yyvsp[0].sortgroupby, NIL); ; { yyval.list = lcons(yyvsp[0].sortgroupby, NIL); ;
break;} break;}
case 452: case 452:
#line 2516 "gram.y" #line 2517 "gram.y"
{ yyval.list = lappend(yyvsp[-2].list, yyvsp[0].sortgroupby); ; { yyval.list = lappend(yyvsp[-2].list, yyvsp[0].sortgroupby); ;
break;} break;}
case 453: case 453:
#line 2520 "gram.y" #line 2521 "gram.y"
{ {
yyval.sortgroupby = makeNode(SortGroupBy); yyval.sortgroupby = makeNode(SortGroupBy);
yyval.sortgroupby->resno = 0; yyval.sortgroupby->resno = 0;
...@@ -6802,7 +6803,7 @@ case 453: ...@@ -6802,7 +6803,7 @@ case 453:
; ;
break;} break;}
case 454: case 454:
#line 2528 "gram.y" #line 2529 "gram.y"
{ {
yyval.sortgroupby = makeNode(SortGroupBy); yyval.sortgroupby = makeNode(SortGroupBy);
yyval.sortgroupby->resno = 0; yyval.sortgroupby->resno = 0;
...@@ -6812,7 +6813,7 @@ case 454: ...@@ -6812,7 +6813,7 @@ case 454:
; ;
break;} break;}
case 455: case 455:
#line 2536 "gram.y" #line 2537 "gram.y"
{ {
yyval.sortgroupby = makeNode(SortGroupBy); yyval.sortgroupby = makeNode(SortGroupBy);
yyval.sortgroupby->resno = yyvsp[-1].ival; yyval.sortgroupby->resno = yyvsp[-1].ival;
...@@ -6822,63 +6823,63 @@ case 455: ...@@ -6822,63 +6823,63 @@ case 455:
; ;
break;} break;}
case 456: case 456:
#line 2545 "gram.y" #line 2546 "gram.y"
{ yyval.str = yyvsp[0].str; ; { yyval.str = yyvsp[0].str; ;
break;} break;}
case 457: case 457:
#line 2546 "gram.y" #line 2547 "gram.y"
{ yyval.str = "<"; ; { yyval.str = "<"; ;
break;} break;}
case 458: case 458:
#line 2547 "gram.y" #line 2548 "gram.y"
{ yyval.str = ">"; ; { yyval.str = ">"; ;
break;} break;}
case 459: case 459:
#line 2548 "gram.y" #line 2549 "gram.y"
{ yyval.str = "<"; ; { yyval.str = "<"; ;
break;} break;}
case 460: case 460:
#line 2549 "gram.y" #line 2550 "gram.y"
{ yyval.str = ">"; ; { yyval.str = ">"; ;
break;} break;}
case 461: case 461:
#line 2550 "gram.y" #line 2551 "gram.y"
{ yyval.str = "<"; /*default*/ ; { yyval.str = "<"; /*default*/ ;
break;} break;}
case 462: case 462:
#line 2560 "gram.y" #line 2561 "gram.y"
{ yyval.boolean = TRUE; ; { yyval.boolean = TRUE; ;
break;} break;}
case 463: case 463:
#line 2561 "gram.y" #line 2562 "gram.y"
{ yyval.boolean = FALSE; ; { yyval.boolean = FALSE; ;
break;} break;}
case 465: case 465:
#line 2567 "gram.y" #line 2568 "gram.y"
{ yyval.list = lcons(makeString(yyvsp[0].str),NIL); ; { yyval.list = lcons(makeString(yyvsp[0].str),NIL); ;
break;} break;}
case 466: case 466:
#line 2569 "gram.y" #line 2570 "gram.y"
{ yyval.list = lappend(yyvsp[-2].list,makeString(yyvsp[0].str)); ; { yyval.list = lappend(yyvsp[-2].list,makeString(yyvsp[0].str)); ;
break;} break;}
case 467: case 467:
#line 2572 "gram.y" #line 2573 "gram.y"
{ yyval.list = yyvsp[0].list; ; { yyval.list = yyvsp[0].list; ;
break;} break;}
case 468: case 468:
#line 2573 "gram.y" #line 2574 "gram.y"
{ yyval.list = NIL; ; { yyval.list = NIL; ;
break;} break;}
case 469: case 469:
#line 2576 "gram.y" #line 2577 "gram.y"
{ yyval.list = lcons(yyvsp[0].sortgroupby, NIL); ; { yyval.list = lcons(yyvsp[0].sortgroupby, NIL); ;
break;} break;}
case 470: case 470:
#line 2577 "gram.y" #line 2578 "gram.y"
{ yyval.list = lappend(yyvsp[-2].list, yyvsp[0].sortgroupby); ; { yyval.list = lappend(yyvsp[-2].list, yyvsp[0].sortgroupby); ;
break;} break;}
case 471: case 471:
#line 2581 "gram.y" #line 2582 "gram.y"
{ {
yyval.sortgroupby = makeNode(SortGroupBy); yyval.sortgroupby = makeNode(SortGroupBy);
yyval.sortgroupby->resno = 0; yyval.sortgroupby->resno = 0;
...@@ -6888,7 +6889,7 @@ case 471: ...@@ -6888,7 +6889,7 @@ case 471:
; ;
break;} break;}
case 472: case 472:
#line 2589 "gram.y" #line 2590 "gram.y"
{ {
yyval.sortgroupby = makeNode(SortGroupBy); yyval.sortgroupby = makeNode(SortGroupBy);
yyval.sortgroupby->resno = 0; yyval.sortgroupby->resno = 0;
...@@ -6898,7 +6899,7 @@ case 472: ...@@ -6898,7 +6899,7 @@ case 472:
; ;
break;} break;}
case 473: case 473:
#line 2597 "gram.y" #line 2598 "gram.y"
{ {
yyval.sortgroupby = makeNode(SortGroupBy); yyval.sortgroupby = makeNode(SortGroupBy);
yyval.sortgroupby->resno = yyvsp[0].ival; yyval.sortgroupby->resno = yyvsp[0].ival;
...@@ -6908,44 +6909,44 @@ case 473: ...@@ -6908,44 +6909,44 @@ case 473:
; ;
break;} break;}
case 474: case 474:
#line 2607 "gram.y" #line 2608 "gram.y"
{ {
yyval.node = yyvsp[0].node; yyval.node = yyvsp[0].node;
; ;
break;} break;}
case 475: case 475:
#line 2610 "gram.y" #line 2611 "gram.y"
{ yyval.node = NULL; ; { yyval.node = NULL; ;
break;} break;}
case 476: case 476:
#line 2623 "gram.y" #line 2624 "gram.y"
{ {
yyval.list = NIL; yyval.list = NIL;
elog(ERROR,"JOIN not yet implemented"); elog(ERROR,"JOIN not yet implemented");
; ;
break;} break;}
case 477: case 477:
#line 2627 "gram.y" #line 2628 "gram.y"
{ yyval.list = yyvsp[0].list; ; { yyval.list = yyvsp[0].list; ;
break;} break;}
case 478: case 478:
#line 2628 "gram.y" #line 2629 "gram.y"
{ yyval.list = NIL; ; { yyval.list = NIL; ;
break;} break;}
case 479: case 479:
#line 2632 "gram.y" #line 2633 "gram.y"
{ yyval.list = lappend(yyvsp[-2].list, yyvsp[0].range); ; { yyval.list = lappend(yyvsp[-2].list, yyvsp[0].range); ;
break;} break;}
case 480: case 480:
#line 2634 "gram.y" #line 2635 "gram.y"
{ elog(ERROR,"CROSS JOIN not yet implemented"); ; { elog(ERROR,"CROSS JOIN not yet implemented"); ;
break;} break;}
case 481: case 481:
#line 2636 "gram.y" #line 2637 "gram.y"
{ yyval.list = lcons(yyvsp[0].range, NIL); ; { yyval.list = lcons(yyvsp[0].range, NIL); ;
break;} break;}
case 482: case 482:
#line 2640 "gram.y" #line 2641 "gram.y"
{ {
yyval.range = makeNode(RangeVar); yyval.range = makeNode(RangeVar);
yyval.range->relExpr = yyvsp[-2].relexp; yyval.range->relExpr = yyvsp[-2].relexp;
...@@ -6953,7 +6954,7 @@ case 482: ...@@ -6953,7 +6954,7 @@ case 482:
; ;
break;} break;}
case 483: case 483:
#line 2646 "gram.y" #line 2647 "gram.y"
{ {
yyval.range = makeNode(RangeVar); yyval.range = makeNode(RangeVar);
yyval.range->relExpr = yyvsp[-1].relexp; yyval.range->relExpr = yyvsp[-1].relexp;
...@@ -6961,7 +6962,7 @@ case 483: ...@@ -6961,7 +6962,7 @@ case 483:
; ;
break;} break;}
case 484: case 484:
#line 2652 "gram.y" #line 2653 "gram.y"
{ {
yyval.range = makeNode(RangeVar); yyval.range = makeNode(RangeVar);
yyval.range->relExpr = yyvsp[0].relexp; yyval.range->relExpr = yyvsp[0].relexp;
...@@ -6969,67 +6970,67 @@ case 484: ...@@ -6969,67 +6970,67 @@ case 484:
; ;
break;} break;}
case 485: case 485:
#line 2659 "gram.y" #line 2660 "gram.y"
{ yyval.str = NULL; ; { yyval.str = NULL; ;
break;} break;}
case 486: case 486:
#line 2661 "gram.y" #line 2662 "gram.y"
{ elog(ERROR,"FULL OUTER JOIN not yet implemented"); ; { elog(ERROR,"FULL OUTER JOIN not yet implemented"); ;
break;} break;}
case 487: case 487:
#line 2663 "gram.y" #line 2664 "gram.y"
{ elog(ERROR,"LEFT OUTER JOIN not yet implemented"); ; { elog(ERROR,"LEFT OUTER JOIN not yet implemented"); ;
break;} break;}
case 488: case 488:
#line 2665 "gram.y" #line 2666 "gram.y"
{ elog(ERROR,"RIGHT OUTER JOIN not yet implemented"); ; { elog(ERROR,"RIGHT OUTER JOIN not yet implemented"); ;
break;} break;}
case 489: case 489:
#line 2667 "gram.y" #line 2668 "gram.y"
{ elog(ERROR,"OUTER JOIN not yet implemented"); ; { elog(ERROR,"OUTER JOIN not yet implemented"); ;
break;} break;}
case 490: case 490:
#line 2669 "gram.y" #line 2670 "gram.y"
{ elog(ERROR,"INNER JOIN not yet implemented"); ; { elog(ERROR,"INNER JOIN not yet implemented"); ;
break;} break;}
case 491: case 491:
#line 2671 "gram.y" #line 2672 "gram.y"
{ elog(ERROR,"UNION JOIN not yet implemented"); ; { elog(ERROR,"UNION JOIN not yet implemented"); ;
break;} break;}
case 492: case 492:
#line 2673 "gram.y" #line 2674 "gram.y"
{ elog(ERROR,"INNER JOIN not yet implemented"); ; { elog(ERROR,"INNER JOIN not yet implemented"); ;
break;} break;}
case 493: case 493:
#line 2676 "gram.y" #line 2677 "gram.y"
{ yyval.str = NULL; ; { yyval.str = NULL; ;
break;} break;}
case 494: case 494:
#line 2677 "gram.y" #line 2678 "gram.y"
{ yyval.str = NULL; /* no qualifiers */ ; { yyval.str = NULL; /* no qualifiers */ ;
break;} break;}
case 495: case 495:
#line 2680 "gram.y" #line 2681 "gram.y"
{ yyval.str = NULL; ; { yyval.str = NULL; ;
break;} break;}
case 496: case 496:
#line 2681 "gram.y" #line 2682 "gram.y"
{ yyval.str = NULL; ; { yyval.str = NULL; ;
break;} break;}
case 497: case 497:
#line 2682 "gram.y" #line 2683 "gram.y"
{ yyval.str = NULL; /* no qualifiers */ ; { yyval.str = NULL; /* no qualifiers */ ;
break;} break;}
case 498: case 498:
#line 2685 "gram.y" #line 2686 "gram.y"
{ yyval.list = lcons(yyvsp[0].sortgroupby, NIL); ; { yyval.list = lcons(yyvsp[0].sortgroupby, NIL); ;
break;} break;}
case 499: case 499:
#line 2686 "gram.y" #line 2687 "gram.y"
{ yyval.list = lappend(yyvsp[-2].list, yyvsp[0].sortgroupby); ; { yyval.list = lappend(yyvsp[-2].list, yyvsp[0].sortgroupby); ;
break;} break;}
case 500: case 500:
#line 2690 "gram.y" #line 2691 "gram.y"
{ {
yyval.sortgroupby = makeNode(SortGroupBy); yyval.sortgroupby = makeNode(SortGroupBy);
yyval.sortgroupby->resno = 0; yyval.sortgroupby->resno = 0;
...@@ -7039,7 +7040,7 @@ case 500: ...@@ -7039,7 +7040,7 @@ case 500:
; ;
break;} break;}
case 501: case 501:
#line 2698 "gram.y" #line 2699 "gram.y"
{ {
yyval.sortgroupby = makeNode(SortGroupBy); yyval.sortgroupby = makeNode(SortGroupBy);
yyval.sortgroupby->resno = 0; yyval.sortgroupby->resno = 0;
...@@ -7049,7 +7050,7 @@ case 501: ...@@ -7049,7 +7050,7 @@ case 501:
; ;
break;} break;}
case 502: case 502:
#line 2706 "gram.y" #line 2707 "gram.y"
{ {
yyval.sortgroupby = makeNode(SortGroupBy); yyval.sortgroupby = makeNode(SortGroupBy);
yyval.sortgroupby->resno = yyvsp[0].ival; yyval.sortgroupby->resno = yyvsp[0].ival;
...@@ -7059,15 +7060,15 @@ case 502: ...@@ -7059,15 +7060,15 @@ case 502:
; ;
break;} break;}
case 503: case 503:
#line 2715 "gram.y" #line 2716 "gram.y"
{ yyval.node = yyvsp[0].node; ; { yyval.node = yyvsp[0].node; ;
break;} break;}
case 504: case 504:
#line 2716 "gram.y" #line 2717 "gram.y"
{ yyval.node = NULL; /* no qualifiers */ ; { yyval.node = NULL; /* no qualifiers */ ;
break;} break;}
case 505: case 505:
#line 2720 "gram.y" #line 2721 "gram.y"
{ {
/* normal relations */ /* normal relations */
yyval.relexp = makeNode(RelExpr); yyval.relexp = makeNode(RelExpr);
...@@ -7076,7 +7077,7 @@ case 505: ...@@ -7076,7 +7077,7 @@ case 505:
; ;
break;} break;}
case 506: case 506:
#line 2727 "gram.y" #line 2728 "gram.y"
{ {
/* inheritance query */ /* inheritance query */
yyval.relexp = makeNode(RelExpr); yyval.relexp = makeNode(RelExpr);
...@@ -7085,31 +7086,31 @@ case 506: ...@@ -7085,31 +7086,31 @@ case 506:
; ;
break;} break;}
case 507: case 507:
#line 2735 "gram.y" #line 2736 "gram.y"
{ yyval.list = lcons(makeInteger(-1), yyvsp[0].list); ; { yyval.list = lcons(makeInteger(-1), yyvsp[0].list); ;
break;} break;}
case 508: case 508:
#line 2737 "gram.y" #line 2738 "gram.y"
{ yyval.list = lcons(makeInteger(yyvsp[-2].ival), yyvsp[0].list); ; { yyval.list = lcons(makeInteger(yyvsp[-2].ival), yyvsp[0].list); ;
break;} break;}
case 509: case 509:
#line 2739 "gram.y" #line 2740 "gram.y"
{ yyval.list = NIL; ; { yyval.list = NIL; ;
break;} break;}
case 510: case 510:
#line 2743 "gram.y" #line 2744 "gram.y"
{ yyval.list = lcons(makeInteger(-1), yyvsp[0].list); ; { yyval.list = lcons(makeInteger(-1), yyvsp[0].list); ;
break;} break;}
case 511: case 511:
#line 2745 "gram.y" #line 2746 "gram.y"
{ yyval.list = lcons(makeInteger(yyvsp[-2].ival), yyvsp[0].list); ; { yyval.list = lcons(makeInteger(yyvsp[-2].ival), yyvsp[0].list); ;
break;} break;}
case 512: case 512:
#line 2747 "gram.y" #line 2748 "gram.y"
{ yyval.list = NIL; ; { yyval.list = NIL; ;
break;} break;}
case 513: case 513:
#line 2762 "gram.y" #line 2763 "gram.y"
{ {
yyval.typnam = yyvsp[-1].typnam; yyval.typnam = yyvsp[-1].typnam;
yyval.typnam->arrayBounds = yyvsp[0].list; yyval.typnam->arrayBounds = yyvsp[0].list;
...@@ -7133,14 +7134,14 @@ case 513: ...@@ -7133,14 +7134,14 @@ case 513:
; ;
break;} break;}
case 515: case 515:
#line 2785 "gram.y" #line 2786 "gram.y"
{ {
yyval.typnam = yyvsp[0].typnam; yyval.typnam = yyvsp[0].typnam;
yyval.typnam->setof = TRUE; yyval.typnam->setof = TRUE;
; ;
break;} break;}
case 519: case 519:
#line 2797 "gram.y" #line 2798 "gram.y"
{ {
yyval.typnam = makeNode(TypeName); yyval.typnam = makeNode(TypeName);
yyval.typnam->name = xlateSqlType(yyvsp[0].str); yyval.typnam->name = xlateSqlType(yyvsp[0].str);
...@@ -7148,15 +7149,15 @@ case 519: ...@@ -7148,15 +7149,15 @@ case 519:
; ;
break;} break;}
case 520: case 520:
#line 2804 "gram.y" #line 2805 "gram.y"
{ yyval.str = yyvsp[0].str; ; { yyval.str = yyvsp[0].str; ;
break;} break;}
case 521: case 521:
#line 2805 "gram.y" #line 2806 "gram.y"
{ yyval.str = xlateSqlType("type"); ; { yyval.str = xlateSqlType("type"); ;
break;} break;}
case 522: case 522:
#line 2815 "gram.y" #line 2816 "gram.y"
{ {
yyval.typnam = makeNode(TypeName); yyval.typnam = makeNode(TypeName);
yyval.typnam->name = xlateSqlType(yyvsp[0].str); yyval.typnam->name = xlateSqlType(yyvsp[0].str);
...@@ -7164,14 +7165,14 @@ case 522: ...@@ -7164,14 +7165,14 @@ case 522:
; ;
break;} break;}
case 523: case 523:
#line 2821 "gram.y" #line 2822 "gram.y"
{ {
yyval.typnam = makeNode(TypeName); yyval.typnam = makeNode(TypeName);
yyval.typnam->name = xlateSqlType("float"); yyval.typnam->name = xlateSqlType("float");
; ;
break;} break;}
case 524: case 524:
#line 2826 "gram.y" #line 2827 "gram.y"
{ {
yyval.typnam = makeNode(TypeName); yyval.typnam = makeNode(TypeName);
yyval.typnam->name = xlateSqlType("integer"); yyval.typnam->name = xlateSqlType("integer");
...@@ -7179,7 +7180,7 @@ case 524: ...@@ -7179,7 +7180,7 @@ case 524:
; ;
break;} break;}
case 525: case 525:
#line 2832 "gram.y" #line 2833 "gram.y"
{ {
yyval.typnam = makeNode(TypeName); yyval.typnam = makeNode(TypeName);
yyval.typnam->name = xlateSqlType("integer"); yyval.typnam->name = xlateSqlType("integer");
...@@ -7187,23 +7188,23 @@ case 525: ...@@ -7187,23 +7188,23 @@ case 525:
; ;
break;} break;}
case 526: case 526:
#line 2840 "gram.y" #line 2841 "gram.y"
{ yyval.str = xlateSqlType("float8"); ; { yyval.str = xlateSqlType("float8"); ;
break;} break;}
case 527: case 527:
#line 2842 "gram.y" #line 2843 "gram.y"
{ yyval.str = xlateSqlType("float8"); ; { yyval.str = xlateSqlType("float8"); ;
break;} break;}
case 528: case 528:
#line 2844 "gram.y" #line 2845 "gram.y"
{ yyval.str = xlateSqlType("decimal"); ; { yyval.str = xlateSqlType("decimal"); ;
break;} break;}
case 529: case 529:
#line 2846 "gram.y" #line 2847 "gram.y"
{ yyval.str = xlateSqlType("numeric"); ; { yyval.str = xlateSqlType("numeric"); ;
break;} break;}
case 530: case 530:
#line 2850 "gram.y" #line 2851 "gram.y"
{ {
if (yyvsp[-1].ival < 1) if (yyvsp[-1].ival < 1)
elog(ERROR,"precision for FLOAT must be at least 1"); elog(ERROR,"precision for FLOAT must be at least 1");
...@@ -7216,13 +7217,13 @@ case 530: ...@@ -7216,13 +7217,13 @@ case 530:
; ;
break;} break;}
case 531: case 531:
#line 2861 "gram.y" #line 2862 "gram.y"
{ {
yyval.str = xlateSqlType("float8"); yyval.str = xlateSqlType("float8");
; ;
break;} break;}
case 532: case 532:
#line 2867 "gram.y" #line 2868 "gram.y"
{ {
if (yyvsp[-3].ival != 9) if (yyvsp[-3].ival != 9)
elog(ERROR,"NUMERIC precision %d must be 9",yyvsp[-3].ival); elog(ERROR,"NUMERIC precision %d must be 9",yyvsp[-3].ival);
...@@ -7231,20 +7232,20 @@ case 532: ...@@ -7231,20 +7232,20 @@ case 532:
; ;
break;} break;}
case 533: case 533:
#line 2874 "gram.y" #line 2875 "gram.y"
{ {
if (yyvsp[-1].ival != 9) if (yyvsp[-1].ival != 9)
elog(ERROR,"NUMERIC precision %d must be 9",yyvsp[-1].ival); elog(ERROR,"NUMERIC precision %d must be 9",yyvsp[-1].ival);
; ;
break;} break;}
case 534: case 534:
#line 2879 "gram.y" #line 2880 "gram.y"
{ {
yyval.str = NULL; yyval.str = NULL;
; ;
break;} break;}
case 535: case 535:
#line 2885 "gram.y" #line 2886 "gram.y"
{ {
if (yyvsp[-3].ival > 9) if (yyvsp[-3].ival > 9)
elog(ERROR,"DECIMAL precision %d exceeds implementation limit of 9",yyvsp[-3].ival); elog(ERROR,"DECIMAL precision %d exceeds implementation limit of 9",yyvsp[-3].ival);
...@@ -7254,7 +7255,7 @@ case 535: ...@@ -7254,7 +7255,7 @@ case 535:
; ;
break;} break;}
case 536: case 536:
#line 2893 "gram.y" #line 2894 "gram.y"
{ {
if (yyvsp[-1].ival > 9) if (yyvsp[-1].ival > 9)
elog(ERROR,"DECIMAL precision %d exceeds implementation limit of 9",yyvsp[-1].ival); elog(ERROR,"DECIMAL precision %d exceeds implementation limit of 9",yyvsp[-1].ival);
...@@ -7262,13 +7263,13 @@ case 536: ...@@ -7262,13 +7263,13 @@ case 536:
; ;
break;} break;}
case 537: case 537:
#line 2899 "gram.y" #line 2900 "gram.y"
{ {
yyval.str = NULL; yyval.str = NULL;
; ;
break;} break;}
case 538: case 538:
#line 2912 "gram.y" #line 2913 "gram.y"
{ {
yyval.typnam = makeNode(TypeName); yyval.typnam = makeNode(TypeName);
if (strcasecmp(yyvsp[-3].str, "char") == 0) if (strcasecmp(yyvsp[-3].str, "char") == 0)
...@@ -7297,7 +7298,7 @@ case 538: ...@@ -7297,7 +7298,7 @@ case 538:
; ;
break;} break;}
case 539: case 539:
#line 2939 "gram.y" #line 2940 "gram.y"
{ {
yyval.typnam = makeNode(TypeName); yyval.typnam = makeNode(TypeName);
/* Let's try to make all single-character types into bpchar(1) /* Let's try to make all single-character types into bpchar(1)
...@@ -7316,7 +7317,7 @@ case 539: ...@@ -7316,7 +7317,7 @@ case 539:
; ;
break;} break;}
case 540: case 540:
#line 2958 "gram.y" #line 2959 "gram.y"
{ {
char *type, *c; char *type, *c;
if ((yyvsp[-1].str == NULL) || (strcasecmp(yyvsp[-1].str, "sql_text") == 0)) { if ((yyvsp[-1].str == NULL) || (strcasecmp(yyvsp[-1].str, "sql_text") == 0)) {
...@@ -7338,47 +7339,47 @@ case 540: ...@@ -7338,47 +7339,47 @@ case 540:
; ;
break;} break;}
case 541: case 541:
#line 2977 "gram.y" #line 2978 "gram.y"
{ yyval.str = xlateSqlType(yyvsp[0].boolean? "varchar": "char"); ; { yyval.str = xlateSqlType(yyvsp[0].boolean? "varchar": "char"); ;
break;} break;}
case 542: case 542:
#line 2978 "gram.y" #line 2979 "gram.y"
{ yyval.str = xlateSqlType("varchar"); ; { yyval.str = xlateSqlType("varchar"); ;
break;} break;}
case 543: case 543:
#line 2979 "gram.y" #line 2980 "gram.y"
{ yyval.str = xlateSqlType(yyvsp[0].boolean? "varchar": "char"); ; { yyval.str = xlateSqlType(yyvsp[0].boolean? "varchar": "char"); ;
break;} break;}
case 544: case 544:
#line 2980 "gram.y" #line 2981 "gram.y"
{ yyval.str = xlateSqlType(yyvsp[0].boolean? "varchar": "char"); ; { yyval.str = xlateSqlType(yyvsp[0].boolean? "varchar": "char"); ;
break;} break;}
case 545: case 545:
#line 2983 "gram.y" #line 2984 "gram.y"
{ yyval.boolean = TRUE; ; { yyval.boolean = TRUE; ;
break;} break;}
case 546: case 546:
#line 2984 "gram.y" #line 2985 "gram.y"
{ yyval.boolean = FALSE; ; { yyval.boolean = FALSE; ;
break;} break;}
case 547: case 547:
#line 2987 "gram.y" #line 2988 "gram.y"
{ yyval.str = yyvsp[0].str; ; { yyval.str = yyvsp[0].str; ;
break;} break;}
case 548: case 548:
#line 2988 "gram.y" #line 2989 "gram.y"
{ yyval.str = NULL; ; { yyval.str = NULL; ;
break;} break;}
case 549: case 549:
#line 2991 "gram.y" #line 2992 "gram.y"
{ yyval.str = yyvsp[0].str; ; { yyval.str = yyvsp[0].str; ;
break;} break;}
case 550: case 550:
#line 2992 "gram.y" #line 2993 "gram.y"
{ yyval.str = NULL; ; { yyval.str = NULL; ;
break;} break;}
case 551: case 551:
#line 2996 "gram.y" #line 2997 "gram.y"
{ {
yyval.typnam = makeNode(TypeName); yyval.typnam = makeNode(TypeName);
yyval.typnam->name = xlateSqlType(yyvsp[0].str); yyval.typnam->name = xlateSqlType(yyvsp[0].str);
...@@ -7386,7 +7387,7 @@ case 551: ...@@ -7386,7 +7387,7 @@ case 551:
; ;
break;} break;}
case 552: case 552:
#line 3002 "gram.y" #line 3003 "gram.y"
{ {
yyval.typnam = makeNode(TypeName); yyval.typnam = makeNode(TypeName);
yyval.typnam->name = xlateSqlType("timestamp"); yyval.typnam->name = xlateSqlType("timestamp");
...@@ -7395,7 +7396,7 @@ case 552: ...@@ -7395,7 +7396,7 @@ case 552:
; ;
break;} break;}
case 553: case 553:
#line 3009 "gram.y" #line 3010 "gram.y"
{ {
yyval.typnam = makeNode(TypeName); yyval.typnam = makeNode(TypeName);
yyval.typnam->name = xlateSqlType("time"); yyval.typnam->name = xlateSqlType("time");
...@@ -7403,7 +7404,7 @@ case 553: ...@@ -7403,7 +7404,7 @@ case 553:
; ;
break;} break;}
case 554: case 554:
#line 3015 "gram.y" #line 3016 "gram.y"
{ {
yyval.typnam = makeNode(TypeName); yyval.typnam = makeNode(TypeName);
yyval.typnam->name = xlateSqlType("interval"); yyval.typnam->name = xlateSqlType("interval");
...@@ -7411,79 +7412,79 @@ case 554: ...@@ -7411,79 +7412,79 @@ case 554:
; ;
break;} break;}
case 555: case 555:
#line 3022 "gram.y" #line 3023 "gram.y"
{ yyval.str = "year"; ; { yyval.str = "year"; ;
break;} break;}
case 556: case 556:
#line 3023 "gram.y" #line 3024 "gram.y"
{ yyval.str = "month"; ; { yyval.str = "month"; ;
break;} break;}
case 557: case 557:
#line 3024 "gram.y" #line 3025 "gram.y"
{ yyval.str = "day"; ; { yyval.str = "day"; ;
break;} break;}
case 558: case 558:
#line 3025 "gram.y" #line 3026 "gram.y"
{ yyval.str = "hour"; ; { yyval.str = "hour"; ;
break;} break;}
case 559: case 559:
#line 3026 "gram.y" #line 3027 "gram.y"
{ yyval.str = "minute"; ; { yyval.str = "minute"; ;
break;} break;}
case 560: case 560:
#line 3027 "gram.y" #line 3028 "gram.y"
{ yyval.str = "second"; ; { yyval.str = "second"; ;
break;} break;}
case 561: case 561:
#line 3030 "gram.y" #line 3031 "gram.y"
{ yyval.boolean = TRUE; ; { yyval.boolean = TRUE; ;
break;} break;}
case 562: case 562:
#line 3031 "gram.y" #line 3032 "gram.y"
{ yyval.boolean = FALSE; ; { yyval.boolean = FALSE; ;
break;} break;}
case 563: case 563:
#line 3034 "gram.y" #line 3035 "gram.y"
{ yyval.list = lcons(yyvsp[0].str, NIL); ; { yyval.list = lcons(yyvsp[0].str, NIL); ;
break;} break;}
case 564: case 564:
#line 3035 "gram.y" #line 3036 "gram.y"
{ yyval.list = NIL; ; { yyval.list = NIL; ;
break;} break;}
case 565: case 565:
#line 3036 "gram.y" #line 3037 "gram.y"
{ yyval.list = NIL; ; { yyval.list = NIL; ;
break;} break;}
case 566: case 566:
#line 3037 "gram.y" #line 3038 "gram.y"
{ yyval.list = NIL; ; { yyval.list = NIL; ;
break;} break;}
case 567: case 567:
#line 3038 "gram.y" #line 3039 "gram.y"
{ yyval.list = NIL; ; { yyval.list = NIL; ;
break;} break;}
case 568: case 568:
#line 3039 "gram.y" #line 3040 "gram.y"
{ yyval.list = NIL; ; { yyval.list = NIL; ;
break;} break;}
case 569: case 569:
#line 3040 "gram.y" #line 3041 "gram.y"
{ yyval.list = NIL; ; { yyval.list = NIL; ;
break;} break;}
case 570: case 570:
#line 3041 "gram.y" #line 3042 "gram.y"
{ yyval.list = NIL; ; { yyval.list = NIL; ;
break;} break;}
case 571: case 571:
#line 3042 "gram.y" #line 3043 "gram.y"
{ yyval.list = NIL; ; { yyval.list = NIL; ;
break;} break;}
case 572: case 572:
#line 3053 "gram.y" #line 3054 "gram.y"
{ yyval.node = yyvsp[0].node; ; { yyval.node = yyvsp[0].node; ;
break;} break;}
case 573: case 573:
#line 3055 "gram.y" #line 3056 "gram.y"
{ {
A_Const *n = makeNode(A_Const); A_Const *n = makeNode(A_Const);
n->val.type = T_Null; n->val.type = T_Null;
...@@ -7491,7 +7492,7 @@ case 573: ...@@ -7491,7 +7492,7 @@ case 573:
; ;
break;} break;}
case 574: case 574:
#line 3072 "gram.y" #line 3073 "gram.y"
{ {
SubLink *n = makeNode(SubLink); SubLink *n = makeNode(SubLink);
n->lefthand = yyvsp[-5].list; n->lefthand = yyvsp[-5].list;
...@@ -7503,7 +7504,7 @@ case 574: ...@@ -7503,7 +7504,7 @@ case 574:
; ;
break;} break;}
case 575: case 575:
#line 3082 "gram.y" #line 3083 "gram.y"
{ {
SubLink *n = makeNode(SubLink); SubLink *n = makeNode(SubLink);
n->lefthand = yyvsp[-6].list; n->lefthand = yyvsp[-6].list;
...@@ -7515,7 +7516,7 @@ case 575: ...@@ -7515,7 +7516,7 @@ case 575:
; ;
break;} break;}
case 576: case 576:
#line 3092 "gram.y" #line 3093 "gram.y"
{ {
SubLink *n = makeNode(SubLink); SubLink *n = makeNode(SubLink);
n->lefthand = yyvsp[-6].list; n->lefthand = yyvsp[-6].list;
...@@ -7530,7 +7531,7 @@ case 576: ...@@ -7530,7 +7531,7 @@ case 576:
; ;
break;} break;}
case 577: case 577:
#line 3105 "gram.y" #line 3106 "gram.y"
{ {
SubLink *n = makeNode(SubLink); SubLink *n = makeNode(SubLink);
n->lefthand = yyvsp[-5].list; n->lefthand = yyvsp[-5].list;
...@@ -7545,86 +7546,86 @@ case 577: ...@@ -7545,86 +7546,86 @@ case 577:
; ;
break;} break;}
case 578: case 578:
#line 3118 "gram.y" #line 3119 "gram.y"
{ {
yyval.node = makeRowExpr(yyvsp[-3].str, yyvsp[-5].list, yyvsp[-1].list); yyval.node = makeRowExpr(yyvsp[-3].str, yyvsp[-5].list, yyvsp[-1].list);
; ;
break;} break;}
case 579: case 579:
#line 3124 "gram.y" #line 3125 "gram.y"
{ {
yyval.list = lappend(yyvsp[-2].list, yyvsp[0].node); yyval.list = lappend(yyvsp[-2].list, yyvsp[0].node);
; ;
break;} break;}
case 580: case 580:
#line 3130 "gram.y" #line 3131 "gram.y"
{ {
yyval.list = lappend(yyvsp[-2].list, yyvsp[0].node); yyval.list = lappend(yyvsp[-2].list, yyvsp[0].node);
; ;
break;} break;}
case 581: case 581:
#line 3134 "gram.y" #line 3135 "gram.y"
{ {
yyval.list = lcons(yyvsp[0].node, NIL); yyval.list = lcons(yyvsp[0].node, NIL);
; ;
break;} break;}
case 582: case 582:
#line 3139 "gram.y" #line 3140 "gram.y"
{ yyval.str = yyvsp[0].str; ; { yyval.str = yyvsp[0].str; ;
break;} break;}
case 583: case 583:
#line 3140 "gram.y" #line 3141 "gram.y"
{ yyval.str = "<"; ; { yyval.str = "<"; ;
break;} break;}
case 584: case 584:
#line 3141 "gram.y" #line 3142 "gram.y"
{ yyval.str = "="; ; { yyval.str = "="; ;
break;} break;}
case 585: case 585:
#line 3142 "gram.y" #line 3143 "gram.y"
{ yyval.str = ">"; ; { yyval.str = ">"; ;
break;} break;}
case 586: case 586:
#line 3143 "gram.y" #line 3144 "gram.y"
{ yyval.str = "+"; ; { yyval.str = "+"; ;
break;} break;}
case 587: case 587:
#line 3144 "gram.y" #line 3145 "gram.y"
{ yyval.str = "-"; ; { yyval.str = "-"; ;
break;} break;}
case 588: case 588:
#line 3145 "gram.y" #line 3146 "gram.y"
{ yyval.str = "*"; ; { yyval.str = "*"; ;
break;} break;}
case 589: case 589:
#line 3146 "gram.y" #line 3147 "gram.y"
{ yyval.str = "/"; ; { yyval.str = "/"; ;
break;} break;}
case 590: case 590:
#line 3149 "gram.y" #line 3150 "gram.y"
{ yyval.ival = ANY_SUBLINK; ; { yyval.ival = ANY_SUBLINK; ;
break;} break;}
case 591: case 591:
#line 3150 "gram.y" #line 3151 "gram.y"
{ yyval.ival = ALL_SUBLINK; ; { yyval.ival = ALL_SUBLINK; ;
break;} break;}
case 592: case 592:
#line 3162 "gram.y" #line 3163 "gram.y"
{ {
yyvsp[-1].attr->indirection = yyvsp[0].list; yyvsp[-1].attr->indirection = yyvsp[0].list;
yyval.node = (Node *)yyvsp[-1].attr; yyval.node = (Node *)yyvsp[-1].attr;
; ;
break;} break;}
case 593: case 593:
#line 3167 "gram.y" #line 3168 "gram.y"
{ yyval.node = yyvsp[0].node; ; { yyval.node = yyvsp[0].node; ;
break;} break;}
case 594: case 594:
#line 3169 "gram.y" #line 3170 "gram.y"
{ yyval.node = yyvsp[0].node; ; { yyval.node = yyvsp[0].node; ;
break;} break;}
case 595: case 595:
#line 3171 "gram.y" #line 3172 "gram.y"
{ {
/* could be a column name or a relation_name */ /* could be a column name or a relation_name */
Ident *n = makeNode(Ident); Ident *n = makeNode(Ident);
...@@ -7634,51 +7635,51 @@ case 595: ...@@ -7634,51 +7635,51 @@ case 595:
; ;
break;} break;}
case 596: case 596:
#line 3179 "gram.y" #line 3180 "gram.y"
{ yyval.node = makeA_Expr(OP, "-", NULL, yyvsp[0].node); ; { yyval.node = makeA_Expr(OP, "-", NULL, yyvsp[0].node); ;
break;} break;}
case 597: case 597:
#line 3181 "gram.y" #line 3182 "gram.y"
{ yyval.node = makeA_Expr(OP, "+", yyvsp[-2].node, yyvsp[0].node); ; { yyval.node = makeA_Expr(OP, "+", yyvsp[-2].node, yyvsp[0].node); ;
break;} break;}
case 598: case 598:
#line 3183 "gram.y" #line 3184 "gram.y"
{ yyval.node = makeA_Expr(OP, "-", yyvsp[-2].node, yyvsp[0].node); ; { yyval.node = makeA_Expr(OP, "-", yyvsp[-2].node, yyvsp[0].node); ;
break;} break;}
case 599: case 599:
#line 3185 "gram.y" #line 3186 "gram.y"
{ yyval.node = makeA_Expr(OP, "/", yyvsp[-2].node, yyvsp[0].node); ; { yyval.node = makeA_Expr(OP, "/", yyvsp[-2].node, yyvsp[0].node); ;
break;} break;}
case 600: case 600:
#line 3187 "gram.y" #line 3188 "gram.y"
{ yyval.node = makeA_Expr(OP, "*", yyvsp[-2].node, yyvsp[0].node); ; { yyval.node = makeA_Expr(OP, "*", yyvsp[-2].node, yyvsp[0].node); ;
break;} break;}
case 601: case 601:
#line 3189 "gram.y" #line 3190 "gram.y"
{ yyval.node = makeA_Expr(OP, "<", yyvsp[-2].node, yyvsp[0].node); ; { yyval.node = makeA_Expr(OP, "<", yyvsp[-2].node, yyvsp[0].node); ;
break;} break;}
case 602: case 602:
#line 3191 "gram.y" #line 3192 "gram.y"
{ yyval.node = makeA_Expr(OP, ">", yyvsp[-2].node, yyvsp[0].node); ; { yyval.node = makeA_Expr(OP, ">", yyvsp[-2].node, yyvsp[0].node); ;
break;} break;}
case 603: case 603:
#line 3193 "gram.y" #line 3194 "gram.y"
{ yyval.node = makeA_Expr(OP, "=", yyvsp[-2].node, yyvsp[0].node); ; { yyval.node = makeA_Expr(OP, "=", yyvsp[-2].node, yyvsp[0].node); ;
break;} break;}
case 604: case 604:
#line 3195 "gram.y" #line 3196 "gram.y"
{ yyval.node = makeA_Expr(OP, ":", NULL, yyvsp[0].node); ; { yyval.node = makeA_Expr(OP, ":", NULL, yyvsp[0].node); ;
break;} break;}
case 605: case 605:
#line 3197 "gram.y" #line 3198 "gram.y"
{ yyval.node = makeA_Expr(OP, ";", NULL, yyvsp[0].node); ; { yyval.node = makeA_Expr(OP, ";", NULL, yyvsp[0].node); ;
break;} break;}
case 606: case 606:
#line 3199 "gram.y" #line 3200 "gram.y"
{ yyval.node = makeA_Expr(OP, "|", NULL, yyvsp[0].node); ; { yyval.node = makeA_Expr(OP, "|", NULL, yyvsp[0].node); ;
break;} break;}
case 607: case 607:
#line 3201 "gram.y" #line 3202 "gram.y"
{ {
yyval.node = (Node *)yyvsp[-2].node; yyval.node = (Node *)yyvsp[-2].node;
/* AexprConst can be either A_Const or ParamNo */ /* AexprConst can be either A_Const or ParamNo */
...@@ -7696,7 +7697,7 @@ case 607: ...@@ -7696,7 +7697,7 @@ case 607:
; ;
break;} break;}
case 608: case 608:
#line 3217 "gram.y" #line 3218 "gram.y"
{ {
yyval.node = (Node *)yyvsp[-3].node; yyval.node = (Node *)yyvsp[-3].node;
/* AexprConst can be either A_Const or ParamNo */ /* AexprConst can be either A_Const or ParamNo */
...@@ -7714,31 +7715,31 @@ case 608: ...@@ -7714,31 +7715,31 @@ case 608:
; ;
break;} break;}
case 609: case 609:
#line 3233 "gram.y" #line 3234 "gram.y"
{ yyval.node = yyvsp[-1].node; ; { yyval.node = yyvsp[-1].node; ;
break;} break;}
case 610: case 610:
#line 3235 "gram.y" #line 3236 "gram.y"
{ yyval.node = makeIndexable(yyvsp[-1].str,yyvsp[-2].node,yyvsp[0].node); ; { yyval.node = makeIndexable(yyvsp[-1].str,yyvsp[-2].node,yyvsp[0].node); ;
break;} break;}
case 611: case 611:
#line 3237 "gram.y" #line 3238 "gram.y"
{ yyval.node = makeIndexable("~~", yyvsp[-2].node, yyvsp[0].node); ; { yyval.node = makeIndexable("~~", yyvsp[-2].node, yyvsp[0].node); ;
break;} break;}
case 612: case 612:
#line 3239 "gram.y" #line 3240 "gram.y"
{ yyval.node = makeA_Expr(OP, "!~~", yyvsp[-3].node, yyvsp[0].node); ; { yyval.node = makeA_Expr(OP, "!~~", yyvsp[-3].node, yyvsp[0].node); ;
break;} break;}
case 613: case 613:
#line 3241 "gram.y" #line 3242 "gram.y"
{ yyval.node = makeA_Expr(OP, yyvsp[-1].str, NULL, yyvsp[0].node); ; { yyval.node = makeA_Expr(OP, yyvsp[-1].str, NULL, yyvsp[0].node); ;
break;} break;}
case 614: case 614:
#line 3243 "gram.y" #line 3244 "gram.y"
{ yyval.node = makeA_Expr(OP, yyvsp[0].str, yyvsp[-1].node, NULL); ; { yyval.node = makeA_Expr(OP, yyvsp[0].str, yyvsp[-1].node, NULL); ;
break;} break;}
case 615: case 615:
#line 3245 "gram.y" #line 3246 "gram.y"
{ {
/* cheap hack for aggregate (eg. count) */ /* cheap hack for aggregate (eg. count) */
FuncCall *n = makeNode(FuncCall); FuncCall *n = makeNode(FuncCall);
...@@ -7752,7 +7753,7 @@ case 615: ...@@ -7752,7 +7753,7 @@ case 615:
; ;
break;} break;}
case 616: case 616:
#line 3257 "gram.y" #line 3258 "gram.y"
{ {
FuncCall *n = makeNode(FuncCall); FuncCall *n = makeNode(FuncCall);
n->funcname = yyvsp[-2].str; n->funcname = yyvsp[-2].str;
...@@ -7761,7 +7762,7 @@ case 616: ...@@ -7761,7 +7762,7 @@ case 616:
; ;
break;} break;}
case 617: case 617:
#line 3264 "gram.y" #line 3265 "gram.y"
{ {
FuncCall *n = makeNode(FuncCall); FuncCall *n = makeNode(FuncCall);
n->funcname = yyvsp[-3].str; n->funcname = yyvsp[-3].str;
...@@ -7770,7 +7771,7 @@ case 617: ...@@ -7770,7 +7771,7 @@ case 617:
; ;
break;} break;}
case 618: case 618:
#line 3271 "gram.y" #line 3272 "gram.y"
{ {
A_Const *n = makeNode(A_Const); A_Const *n = makeNode(A_Const);
TypeName *t = makeNode(TypeName); TypeName *t = makeNode(TypeName);
...@@ -7787,7 +7788,7 @@ case 618: ...@@ -7787,7 +7788,7 @@ case 618:
; ;
break;} break;}
case 619: case 619:
#line 3286 "gram.y" #line 3287 "gram.y"
{ {
A_Const *n = makeNode(A_Const); A_Const *n = makeNode(A_Const);
TypeName *t = makeNode(TypeName); TypeName *t = makeNode(TypeName);
...@@ -7804,7 +7805,7 @@ case 619: ...@@ -7804,7 +7805,7 @@ case 619:
; ;
break;} break;}
case 620: case 620:
#line 3301 "gram.y" #line 3302 "gram.y"
{ {
FuncCall *n = makeNode(FuncCall); FuncCall *n = makeNode(FuncCall);
A_Const *s = makeNode(A_Const); A_Const *s = makeNode(A_Const);
...@@ -7828,7 +7829,7 @@ case 620: ...@@ -7828,7 +7829,7 @@ case 620:
; ;
break;} break;}
case 621: case 621:
#line 3323 "gram.y" #line 3324 "gram.y"
{ {
A_Const *n = makeNode(A_Const); A_Const *n = makeNode(A_Const);
TypeName *t = makeNode(TypeName); TypeName *t = makeNode(TypeName);
...@@ -7845,7 +7846,7 @@ case 621: ...@@ -7845,7 +7846,7 @@ case 621:
; ;
break;} break;}
case 622: case 622:
#line 3338 "gram.y" #line 3339 "gram.y"
{ {
FuncCall *n = makeNode(FuncCall); FuncCall *n = makeNode(FuncCall);
A_Const *s = makeNode(A_Const); A_Const *s = makeNode(A_Const);
...@@ -7869,7 +7870,7 @@ case 622: ...@@ -7869,7 +7870,7 @@ case 622:
; ;
break;} break;}
case 623: case 623:
#line 3360 "gram.y" #line 3361 "gram.y"
{ {
FuncCall *n = makeNode(FuncCall); FuncCall *n = makeNode(FuncCall);
n->funcname = "getpgusername"; n->funcname = "getpgusername";
...@@ -7878,7 +7879,7 @@ case 623: ...@@ -7878,7 +7879,7 @@ case 623:
; ;
break;} break;}
case 624: case 624:
#line 3367 "gram.y" #line 3368 "gram.y"
{ {
FuncCall *n = makeNode(FuncCall); FuncCall *n = makeNode(FuncCall);
n->funcname = "getpgusername"; n->funcname = "getpgusername";
...@@ -7887,7 +7888,7 @@ case 624: ...@@ -7887,7 +7888,7 @@ case 624:
; ;
break;} break;}
case 625: case 625:
#line 3374 "gram.y" #line 3375 "gram.y"
{ {
SubLink *n = makeNode(SubLink); SubLink *n = makeNode(SubLink);
n->lefthand = NIL; n->lefthand = NIL;
...@@ -7899,7 +7900,7 @@ case 625: ...@@ -7899,7 +7900,7 @@ case 625:
; ;
break;} break;}
case 626: case 626:
#line 3384 "gram.y" #line 3385 "gram.y"
{ {
FuncCall *n = makeNode(FuncCall); FuncCall *n = makeNode(FuncCall);
n->funcname = "date_part"; n->funcname = "date_part";
...@@ -7908,7 +7909,7 @@ case 626: ...@@ -7908,7 +7909,7 @@ case 626:
; ;
break;} break;}
case 627: case 627:
#line 3391 "gram.y" #line 3392 "gram.y"
{ {
FuncCall *n = makeNode(FuncCall); FuncCall *n = makeNode(FuncCall);
n->funcname = "strpos"; n->funcname = "strpos";
...@@ -7917,7 +7918,7 @@ case 627: ...@@ -7917,7 +7918,7 @@ case 627:
; ;
break;} break;}
case 628: case 628:
#line 3398 "gram.y" #line 3399 "gram.y"
{ {
FuncCall *n = makeNode(FuncCall); FuncCall *n = makeNode(FuncCall);
n->funcname = "substr"; n->funcname = "substr";
...@@ -7926,7 +7927,7 @@ case 628: ...@@ -7926,7 +7927,7 @@ case 628:
; ;
break;} break;}
case 629: case 629:
#line 3406 "gram.y" #line 3407 "gram.y"
{ {
FuncCall *n = makeNode(FuncCall); FuncCall *n = makeNode(FuncCall);
n->funcname = "btrim"; n->funcname = "btrim";
...@@ -7935,7 +7936,7 @@ case 629: ...@@ -7935,7 +7936,7 @@ case 629:
; ;
break;} break;}
case 630: case 630:
#line 3413 "gram.y" #line 3414 "gram.y"
{ {
FuncCall *n = makeNode(FuncCall); FuncCall *n = makeNode(FuncCall);
n->funcname = "ltrim"; n->funcname = "ltrim";
...@@ -7944,7 +7945,7 @@ case 630: ...@@ -7944,7 +7945,7 @@ case 630:
; ;
break;} break;}
case 631: case 631:
#line 3420 "gram.y" #line 3421 "gram.y"
{ {
FuncCall *n = makeNode(FuncCall); FuncCall *n = makeNode(FuncCall);
n->funcname = "rtrim"; n->funcname = "rtrim";
...@@ -7953,7 +7954,7 @@ case 631: ...@@ -7953,7 +7954,7 @@ case 631:
; ;
break;} break;}
case 632: case 632:
#line 3427 "gram.y" #line 3428 "gram.y"
{ {
FuncCall *n = makeNode(FuncCall); FuncCall *n = makeNode(FuncCall);
n->funcname = "btrim"; n->funcname = "btrim";
...@@ -7962,23 +7963,23 @@ case 632: ...@@ -7962,23 +7963,23 @@ case 632:
; ;
break;} break;}
case 633: case 633:
#line 3434 "gram.y" #line 3435 "gram.y"
{ yyval.node = makeA_Expr(ISNULL, NULL, yyvsp[-1].node, NULL); ; { yyval.node = makeA_Expr(ISNULL, NULL, yyvsp[-1].node, NULL); ;
break;} break;}
case 634: case 634:
#line 3436 "gram.y" #line 3437 "gram.y"
{ yyval.node = makeA_Expr(ISNULL, NULL, yyvsp[-2].node, NULL); ; { yyval.node = makeA_Expr(ISNULL, NULL, yyvsp[-2].node, NULL); ;
break;} break;}
case 635: case 635:
#line 3438 "gram.y" #line 3439 "gram.y"
{ yyval.node = makeA_Expr(NOTNULL, NULL, yyvsp[-1].node, NULL); ; { yyval.node = makeA_Expr(NOTNULL, NULL, yyvsp[-1].node, NULL); ;
break;} break;}
case 636: case 636:
#line 3440 "gram.y" #line 3441 "gram.y"
{ yyval.node = makeA_Expr(NOTNULL, NULL, yyvsp[-3].node, NULL); ; { yyval.node = makeA_Expr(NOTNULL, NULL, yyvsp[-3].node, NULL); ;
break;} break;}
case 637: case 637:
#line 3447 "gram.y" #line 3448 "gram.y"
{ {
A_Const *n = makeNode(A_Const); A_Const *n = makeNode(A_Const);
n->val.type = T_String; n->val.type = T_String;
...@@ -7990,7 +7991,7 @@ case 637: ...@@ -7990,7 +7991,7 @@ case 637:
; ;
break;} break;}
case 638: case 638:
#line 3457 "gram.y" #line 3458 "gram.y"
{ {
A_Const *n = makeNode(A_Const); A_Const *n = makeNode(A_Const);
n->val.type = T_String; n->val.type = T_String;
...@@ -8002,7 +8003,7 @@ case 638: ...@@ -8002,7 +8003,7 @@ case 638:
; ;
break;} break;}
case 639: case 639:
#line 3467 "gram.y" #line 3468 "gram.y"
{ {
A_Const *n = makeNode(A_Const); A_Const *n = makeNode(A_Const);
n->val.type = T_String; n->val.type = T_String;
...@@ -8014,7 +8015,7 @@ case 639: ...@@ -8014,7 +8015,7 @@ case 639:
; ;
break;} break;}
case 640: case 640:
#line 3477 "gram.y" #line 3478 "gram.y"
{ {
A_Const *n = makeNode(A_Const); A_Const *n = makeNode(A_Const);
n->val.type = T_String; n->val.type = T_String;
...@@ -8026,7 +8027,7 @@ case 640: ...@@ -8026,7 +8027,7 @@ case 640:
; ;
break;} break;}
case 641: case 641:
#line 3487 "gram.y" #line 3488 "gram.y"
{ {
yyval.node = makeA_Expr(AND, NULL, yyval.node = makeA_Expr(AND, NULL,
makeA_Expr(OP, ">=", yyvsp[-4].node, yyvsp[-2].node), makeA_Expr(OP, ">=", yyvsp[-4].node, yyvsp[-2].node),
...@@ -8034,7 +8035,7 @@ case 641: ...@@ -8034,7 +8035,7 @@ case 641:
; ;
break;} break;}
case 642: case 642:
#line 3493 "gram.y" #line 3494 "gram.y"
{ {
yyval.node = makeA_Expr(OR, NULL, yyval.node = makeA_Expr(OR, NULL,
makeA_Expr(OP, "<", yyvsp[-5].node, yyvsp[-2].node), makeA_Expr(OP, "<", yyvsp[-5].node, yyvsp[-2].node),
...@@ -8042,11 +8043,11 @@ case 642: ...@@ -8042,11 +8043,11 @@ case 642:
; ;
break;} break;}
case 643: case 643:
#line 3498 "gram.y" #line 3499 "gram.y"
{ saved_In_Expr = lcons(yyvsp[-1].node,saved_In_Expr); ; { saved_In_Expr = lcons(yyvsp[-1].node,saved_In_Expr); ;
break;} break;}
case 644: case 644:
#line 3499 "gram.y" #line 3500 "gram.y"
{ {
saved_In_Expr = lnext(saved_In_Expr); saved_In_Expr = lnext(saved_In_Expr);
if (nodeTag(yyvsp[-1].node) == T_SubLink) if (nodeTag(yyvsp[-1].node) == T_SubLink)
...@@ -8062,11 +8063,11 @@ case 644: ...@@ -8062,11 +8063,11 @@ case 644:
; ;
break;} break;}
case 645: case 645:
#line 3512 "gram.y" #line 3513 "gram.y"
{ saved_In_Expr = lcons(yyvsp[-2].node,saved_In_Expr); ; { saved_In_Expr = lcons(yyvsp[-2].node,saved_In_Expr); ;
break;} break;}
case 646: case 646:
#line 3513 "gram.y" #line 3514 "gram.y"
{ {
saved_In_Expr = lnext(saved_In_Expr); saved_In_Expr = lnext(saved_In_Expr);
if (nodeTag(yyvsp[-1].node) == T_SubLink) if (nodeTag(yyvsp[-1].node) == T_SubLink)
...@@ -8082,7 +8083,7 @@ case 646: ...@@ -8082,7 +8083,7 @@ case 646:
; ;
break;} break;}
case 647: case 647:
#line 3527 "gram.y" #line 3528 "gram.y"
{ {
SubLink *n = makeNode(SubLink); SubLink *n = makeNode(SubLink);
n->lefthand = lcons(yyvsp[-4].node, NULL); n->lefthand = lcons(yyvsp[-4].node, NULL);
...@@ -8094,7 +8095,7 @@ case 647: ...@@ -8094,7 +8095,7 @@ case 647:
; ;
break;} break;}
case 648: case 648:
#line 3537 "gram.y" #line 3538 "gram.y"
{ {
SubLink *n = makeNode(SubLink); SubLink *n = makeNode(SubLink);
n->lefthand = lcons(yyvsp[-4].node, NULL); n->lefthand = lcons(yyvsp[-4].node, NULL);
...@@ -8106,7 +8107,7 @@ case 648: ...@@ -8106,7 +8107,7 @@ case 648:
; ;
break;} break;}
case 649: case 649:
#line 3547 "gram.y" #line 3548 "gram.y"
{ {
SubLink *n = makeNode(SubLink); SubLink *n = makeNode(SubLink);
n->lefthand = lcons(yyvsp[-4].node, NULL); n->lefthand = lcons(yyvsp[-4].node, NULL);
...@@ -8118,7 +8119,7 @@ case 649: ...@@ -8118,7 +8119,7 @@ case 649:
; ;
break;} break;}
case 650: case 650:
#line 3557 "gram.y" #line 3558 "gram.y"
{ {
SubLink *n = makeNode(SubLink); SubLink *n = makeNode(SubLink);
n->lefthand = lcons(yyvsp[-4].node, NULL); n->lefthand = lcons(yyvsp[-4].node, NULL);
...@@ -8130,7 +8131,7 @@ case 650: ...@@ -8130,7 +8131,7 @@ case 650:
; ;
break;} break;}
case 651: case 651:
#line 3567 "gram.y" #line 3568 "gram.y"
{ {
SubLink *n = makeNode(SubLink); SubLink *n = makeNode(SubLink);
n->lefthand = lcons(yyvsp[-4].node, NULL); n->lefthand = lcons(yyvsp[-4].node, NULL);
...@@ -8142,7 +8143,7 @@ case 651: ...@@ -8142,7 +8143,7 @@ case 651:
; ;
break;} break;}
case 652: case 652:
#line 3577 "gram.y" #line 3578 "gram.y"
{ {
SubLink *n = makeNode(SubLink); SubLink *n = makeNode(SubLink);
n->lefthand = lcons(yyvsp[-4].node, NULL); n->lefthand = lcons(yyvsp[-4].node, NULL);
...@@ -8154,7 +8155,7 @@ case 652: ...@@ -8154,7 +8155,7 @@ case 652:
; ;
break;} break;}
case 653: case 653:
#line 3587 "gram.y" #line 3588 "gram.y"
{ {
SubLink *n = makeNode(SubLink); SubLink *n = makeNode(SubLink);
n->lefthand = lcons(yyvsp[-4].node, NULL); n->lefthand = lcons(yyvsp[-4].node, NULL);
...@@ -8166,7 +8167,7 @@ case 653: ...@@ -8166,7 +8167,7 @@ case 653:
; ;
break;} break;}
case 654: case 654:
#line 3597 "gram.y" #line 3598 "gram.y"
{ {
SubLink *n = makeNode(SubLink); SubLink *n = makeNode(SubLink);
n->lefthand = lcons(yyvsp[-4].node, NULL); n->lefthand = lcons(yyvsp[-4].node, NULL);
...@@ -8178,7 +8179,7 @@ case 654: ...@@ -8178,7 +8179,7 @@ case 654:
; ;
break;} break;}
case 655: case 655:
#line 3607 "gram.y" #line 3608 "gram.y"
{ {
SubLink *n = makeNode(SubLink); SubLink *n = makeNode(SubLink);
n->lefthand = lcons(yyvsp[-5].node,NIL); n->lefthand = lcons(yyvsp[-5].node,NIL);
...@@ -8190,7 +8191,7 @@ case 655: ...@@ -8190,7 +8191,7 @@ case 655:
; ;
break;} break;}
case 656: case 656:
#line 3617 "gram.y" #line 3618 "gram.y"
{ {
SubLink *n = makeNode(SubLink); SubLink *n = makeNode(SubLink);
n->lefthand = lcons(yyvsp[-5].node,NIL); n->lefthand = lcons(yyvsp[-5].node,NIL);
...@@ -8202,7 +8203,7 @@ case 656: ...@@ -8202,7 +8203,7 @@ case 656:
; ;
break;} break;}
case 657: case 657:
#line 3627 "gram.y" #line 3628 "gram.y"
{ {
SubLink *n = makeNode(SubLink); SubLink *n = makeNode(SubLink);
n->lefthand = lcons(yyvsp[-5].node,NIL); n->lefthand = lcons(yyvsp[-5].node,NIL);
...@@ -8214,7 +8215,7 @@ case 657: ...@@ -8214,7 +8215,7 @@ case 657:
; ;
break;} break;}
case 658: case 658:
#line 3637 "gram.y" #line 3638 "gram.y"
{ {
SubLink *n = makeNode(SubLink); SubLink *n = makeNode(SubLink);
n->lefthand = lcons(yyvsp[-5].node,NIL); n->lefthand = lcons(yyvsp[-5].node,NIL);
...@@ -8226,7 +8227,7 @@ case 658: ...@@ -8226,7 +8227,7 @@ case 658:
; ;
break;} break;}
case 659: case 659:
#line 3647 "gram.y" #line 3648 "gram.y"
{ {
SubLink *n = makeNode(SubLink); SubLink *n = makeNode(SubLink);
n->lefthand = lcons(yyvsp[-5].node,NIL); n->lefthand = lcons(yyvsp[-5].node,NIL);
...@@ -8238,7 +8239,7 @@ case 659: ...@@ -8238,7 +8239,7 @@ case 659:
; ;
break;} break;}
case 660: case 660:
#line 3657 "gram.y" #line 3658 "gram.y"
{ {
SubLink *n = makeNode(SubLink); SubLink *n = makeNode(SubLink);
n->lefthand = lcons(yyvsp[-5].node,NIL); n->lefthand = lcons(yyvsp[-5].node,NIL);
...@@ -8250,7 +8251,7 @@ case 660: ...@@ -8250,7 +8251,7 @@ case 660:
; ;
break;} break;}
case 661: case 661:
#line 3667 "gram.y" #line 3668 "gram.y"
{ {
SubLink *n = makeNode(SubLink); SubLink *n = makeNode(SubLink);
n->lefthand = lcons(yyvsp[-5].node,NIL); n->lefthand = lcons(yyvsp[-5].node,NIL);
...@@ -8262,7 +8263,7 @@ case 661: ...@@ -8262,7 +8263,7 @@ case 661:
; ;
break;} break;}
case 662: case 662:
#line 3677 "gram.y" #line 3678 "gram.y"
{ {
SubLink *n = makeNode(SubLink); SubLink *n = makeNode(SubLink);
n->lefthand = lcons(yyvsp[-5].node,NIL); n->lefthand = lcons(yyvsp[-5].node,NIL);
...@@ -8274,7 +8275,7 @@ case 662: ...@@ -8274,7 +8275,7 @@ case 662:
; ;
break;} break;}
case 663: case 663:
#line 3687 "gram.y" #line 3688 "gram.y"
{ {
SubLink *n = makeNode(SubLink); SubLink *n = makeNode(SubLink);
n->lefthand = lcons(yyvsp[-5].node, NULL); n->lefthand = lcons(yyvsp[-5].node, NULL);
...@@ -8286,7 +8287,7 @@ case 663: ...@@ -8286,7 +8287,7 @@ case 663:
; ;
break;} break;}
case 664: case 664:
#line 3697 "gram.y" #line 3698 "gram.y"
{ {
SubLink *n = makeNode(SubLink); SubLink *n = makeNode(SubLink);
n->lefthand = lcons(yyvsp[-5].node, NULL); n->lefthand = lcons(yyvsp[-5].node, NULL);
...@@ -8298,7 +8299,7 @@ case 664: ...@@ -8298,7 +8299,7 @@ case 664:
; ;
break;} break;}
case 665: case 665:
#line 3707 "gram.y" #line 3708 "gram.y"
{ {
SubLink *n = makeNode(SubLink); SubLink *n = makeNode(SubLink);
n->lefthand = lcons(yyvsp[-5].node, NULL); n->lefthand = lcons(yyvsp[-5].node, NULL);
...@@ -8310,7 +8311,7 @@ case 665: ...@@ -8310,7 +8311,7 @@ case 665:
; ;
break;} break;}
case 666: case 666:
#line 3717 "gram.y" #line 3718 "gram.y"
{ {
SubLink *n = makeNode(SubLink); SubLink *n = makeNode(SubLink);
n->lefthand = lcons(yyvsp[-5].node, NULL); n->lefthand = lcons(yyvsp[-5].node, NULL);
...@@ -8322,7 +8323,7 @@ case 666: ...@@ -8322,7 +8323,7 @@ case 666:
; ;
break;} break;}
case 667: case 667:
#line 3727 "gram.y" #line 3728 "gram.y"
{ {
SubLink *n = makeNode(SubLink); SubLink *n = makeNode(SubLink);
n->lefthand = lcons(yyvsp[-5].node, NULL); n->lefthand = lcons(yyvsp[-5].node, NULL);
...@@ -8334,7 +8335,7 @@ case 667: ...@@ -8334,7 +8335,7 @@ case 667:
; ;
break;} break;}
case 668: case 668:
#line 3737 "gram.y" #line 3738 "gram.y"
{ {
SubLink *n = makeNode(SubLink); SubLink *n = makeNode(SubLink);
n->lefthand = lcons(yyvsp[-5].node, NULL); n->lefthand = lcons(yyvsp[-5].node, NULL);
...@@ -8346,7 +8347,7 @@ case 668: ...@@ -8346,7 +8347,7 @@ case 668:
; ;
break;} break;}
case 669: case 669:
#line 3747 "gram.y" #line 3748 "gram.y"
{ {
SubLink *n = makeNode(SubLink); SubLink *n = makeNode(SubLink);
n->lefthand = lcons(yyvsp[-5].node, NULL); n->lefthand = lcons(yyvsp[-5].node, NULL);
...@@ -8358,7 +8359,7 @@ case 669: ...@@ -8358,7 +8359,7 @@ case 669:
; ;
break;} break;}
case 670: case 670:
#line 3757 "gram.y" #line 3758 "gram.y"
{ {
SubLink *n = makeNode(SubLink); SubLink *n = makeNode(SubLink);
n->lefthand = lcons(yyvsp[-5].node, NULL); n->lefthand = lcons(yyvsp[-5].node, NULL);
...@@ -8370,30 +8371,30 @@ case 670: ...@@ -8370,30 +8371,30 @@ case 670:
; ;
break;} break;}
case 671: case 671:
#line 3767 "gram.y" #line 3768 "gram.y"
{ yyval.node = makeA_Expr(AND, NULL, yyvsp[-2].node, yyvsp[0].node); ; { yyval.node = makeA_Expr(AND, NULL, yyvsp[-2].node, yyvsp[0].node); ;
break;} break;}
case 672: case 672:
#line 3769 "gram.y" #line 3770 "gram.y"
{ yyval.node = makeA_Expr(OR, NULL, yyvsp[-2].node, yyvsp[0].node); ; { yyval.node = makeA_Expr(OR, NULL, yyvsp[-2].node, yyvsp[0].node); ;
break;} break;}
case 673: case 673:
#line 3771 "gram.y" #line 3772 "gram.y"
{ yyval.node = makeA_Expr(NOT, NULL, NULL, yyvsp[0].node); ; { yyval.node = makeA_Expr(NOT, NULL, NULL, yyvsp[0].node); ;
break;} break;}
case 674: case 674:
#line 3781 "gram.y" #line 3782 "gram.y"
{ {
yyvsp[-1].attr->indirection = yyvsp[0].list; yyvsp[-1].attr->indirection = yyvsp[0].list;
yyval.node = (Node *)yyvsp[-1].attr; yyval.node = (Node *)yyvsp[-1].attr;
; ;
break;} break;}
case 675: case 675:
#line 3786 "gram.y" #line 3787 "gram.y"
{ yyval.node = yyvsp[0].node; ; { yyval.node = yyvsp[0].node; ;
break;} break;}
case 676: case 676:
#line 3788 "gram.y" #line 3789 "gram.y"
{ {
/* could be a column name or a relation_name */ /* could be a column name or a relation_name */
Ident *n = makeNode(Ident); Ident *n = makeNode(Ident);
...@@ -8403,39 +8404,39 @@ case 676: ...@@ -8403,39 +8404,39 @@ case 676:
; ;
break;} break;}
case 677: case 677:
#line 3796 "gram.y" #line 3797 "gram.y"
{ yyval.node = makeA_Expr(OP, "-", NULL, yyvsp[0].node); ; { yyval.node = makeA_Expr(OP, "-", NULL, yyvsp[0].node); ;
break;} break;}
case 678: case 678:
#line 3798 "gram.y" #line 3799 "gram.y"
{ yyval.node = makeA_Expr(OP, "+", yyvsp[-2].node, yyvsp[0].node); ; { yyval.node = makeA_Expr(OP, "+", yyvsp[-2].node, yyvsp[0].node); ;
break;} break;}
case 679: case 679:
#line 3800 "gram.y" #line 3801 "gram.y"
{ yyval.node = makeA_Expr(OP, "-", yyvsp[-2].node, yyvsp[0].node); ; { yyval.node = makeA_Expr(OP, "-", yyvsp[-2].node, yyvsp[0].node); ;
break;} break;}
case 680: case 680:
#line 3802 "gram.y" #line 3803 "gram.y"
{ yyval.node = makeA_Expr(OP, "/", yyvsp[-2].node, yyvsp[0].node); ; { yyval.node = makeA_Expr(OP, "/", yyvsp[-2].node, yyvsp[0].node); ;
break;} break;}
case 681: case 681:
#line 3804 "gram.y" #line 3805 "gram.y"
{ yyval.node = makeA_Expr(OP, "*", yyvsp[-2].node, yyvsp[0].node); ; { yyval.node = makeA_Expr(OP, "*", yyvsp[-2].node, yyvsp[0].node); ;
break;} break;}
case 682: case 682:
#line 3806 "gram.y" #line 3807 "gram.y"
{ yyval.node = makeA_Expr(OP, ":", NULL, yyvsp[0].node); ; { yyval.node = makeA_Expr(OP, ":", NULL, yyvsp[0].node); ;
break;} break;}
case 683: case 683:
#line 3808 "gram.y" #line 3809 "gram.y"
{ yyval.node = makeA_Expr(OP, ";", NULL, yyvsp[0].node); ; { yyval.node = makeA_Expr(OP, ";", NULL, yyvsp[0].node); ;
break;} break;}
case 684: case 684:
#line 3810 "gram.y" #line 3811 "gram.y"
{ yyval.node = makeA_Expr(OP, "|", NULL, yyvsp[0].node); ; { yyval.node = makeA_Expr(OP, "|", NULL, yyvsp[0].node); ;
break;} break;}
case 685: case 685:
#line 3812 "gram.y" #line 3813 "gram.y"
{ {
yyval.node = (Node *)yyvsp[-2].node; yyval.node = (Node *)yyvsp[-2].node;
/* AexprConst can be either A_Const or ParamNo */ /* AexprConst can be either A_Const or ParamNo */
...@@ -8453,7 +8454,7 @@ case 685: ...@@ -8453,7 +8454,7 @@ case 685:
; ;
break;} break;}
case 686: case 686:
#line 3828 "gram.y" #line 3829 "gram.y"
{ {
yyval.node = (Node *)yyvsp[-3].node; yyval.node = (Node *)yyvsp[-3].node;
/* AexprConst can be either A_Const or ParamNo */ /* AexprConst can be either A_Const or ParamNo */
...@@ -8471,23 +8472,23 @@ case 686: ...@@ -8471,23 +8472,23 @@ case 686:
; ;
break;} break;}
case 687: case 687:
#line 3844 "gram.y" #line 3845 "gram.y"
{ yyval.node = yyvsp[-1].node; ; { yyval.node = yyvsp[-1].node; ;
break;} break;}
case 688: case 688:
#line 3846 "gram.y" #line 3847 "gram.y"
{ yyval.node = makeIndexable(yyvsp[-1].str,yyvsp[-2].node,yyvsp[0].node); ; { yyval.node = makeIndexable(yyvsp[-1].str,yyvsp[-2].node,yyvsp[0].node); ;
break;} break;}
case 689: case 689:
#line 3848 "gram.y" #line 3849 "gram.y"
{ yyval.node = makeA_Expr(OP, yyvsp[-1].str, NULL, yyvsp[0].node); ; { yyval.node = makeA_Expr(OP, yyvsp[-1].str, NULL, yyvsp[0].node); ;
break;} break;}
case 690: case 690:
#line 3850 "gram.y" #line 3851 "gram.y"
{ yyval.node = makeA_Expr(OP, yyvsp[0].str, yyvsp[-1].node, NULL); ; { yyval.node = makeA_Expr(OP, yyvsp[0].str, yyvsp[-1].node, NULL); ;
break;} break;}
case 691: case 691:
#line 3852 "gram.y" #line 3853 "gram.y"
{ {
FuncCall *n = makeNode(FuncCall); FuncCall *n = makeNode(FuncCall);
n->funcname = yyvsp[-2].str; n->funcname = yyvsp[-2].str;
...@@ -8496,7 +8497,7 @@ case 691: ...@@ -8496,7 +8497,7 @@ case 691:
; ;
break;} break;}
case 692: case 692:
#line 3859 "gram.y" #line 3860 "gram.y"
{ {
FuncCall *n = makeNode(FuncCall); FuncCall *n = makeNode(FuncCall);
n->funcname = yyvsp[-3].str; n->funcname = yyvsp[-3].str;
...@@ -8505,7 +8506,7 @@ case 692: ...@@ -8505,7 +8506,7 @@ case 692:
; ;
break;} break;}
case 693: case 693:
#line 3866 "gram.y" #line 3867 "gram.y"
{ {
A_Const *n = makeNode(A_Const); A_Const *n = makeNode(A_Const);
TypeName *t = makeNode(TypeName); TypeName *t = makeNode(TypeName);
...@@ -8522,7 +8523,7 @@ case 693: ...@@ -8522,7 +8523,7 @@ case 693:
; ;
break;} break;}
case 694: case 694:
#line 3881 "gram.y" #line 3882 "gram.y"
{ {
A_Const *n = makeNode(A_Const); A_Const *n = makeNode(A_Const);
TypeName *t = makeNode(TypeName); TypeName *t = makeNode(TypeName);
...@@ -8539,7 +8540,7 @@ case 694: ...@@ -8539,7 +8540,7 @@ case 694:
; ;
break;} break;}
case 695: case 695:
#line 3896 "gram.y" #line 3897 "gram.y"
{ {
FuncCall *n = makeNode(FuncCall); FuncCall *n = makeNode(FuncCall);
A_Const *s = makeNode(A_Const); A_Const *s = makeNode(A_Const);
...@@ -8563,7 +8564,7 @@ case 695: ...@@ -8563,7 +8564,7 @@ case 695:
; ;
break;} break;}
case 696: case 696:
#line 3918 "gram.y" #line 3919 "gram.y"
{ {
A_Const *n = makeNode(A_Const); A_Const *n = makeNode(A_Const);
TypeName *t = makeNode(TypeName); TypeName *t = makeNode(TypeName);
...@@ -8580,7 +8581,7 @@ case 696: ...@@ -8580,7 +8581,7 @@ case 696:
; ;
break;} break;}
case 697: case 697:
#line 3933 "gram.y" #line 3934 "gram.y"
{ {
FuncCall *n = makeNode(FuncCall); FuncCall *n = makeNode(FuncCall);
A_Const *s = makeNode(A_Const); A_Const *s = makeNode(A_Const);
...@@ -8604,7 +8605,7 @@ case 697: ...@@ -8604,7 +8605,7 @@ case 697:
; ;
break;} break;}
case 698: case 698:
#line 3955 "gram.y" #line 3956 "gram.y"
{ {
FuncCall *n = makeNode(FuncCall); FuncCall *n = makeNode(FuncCall);
n->funcname = "getpgusername"; n->funcname = "getpgusername";
...@@ -8613,7 +8614,7 @@ case 698: ...@@ -8613,7 +8614,7 @@ case 698:
; ;
break;} break;}
case 699: case 699:
#line 3962 "gram.y" #line 3963 "gram.y"
{ {
FuncCall *n = makeNode(FuncCall); FuncCall *n = makeNode(FuncCall);
n->funcname = "getpgusername"; n->funcname = "getpgusername";
...@@ -8622,7 +8623,7 @@ case 699: ...@@ -8622,7 +8623,7 @@ case 699:
; ;
break;} break;}
case 700: case 700:
#line 3969 "gram.y" #line 3970 "gram.y"
{ {
FuncCall *n = makeNode(FuncCall); FuncCall *n = makeNode(FuncCall);
n->funcname = "strpos"; n->funcname = "strpos";
...@@ -8631,7 +8632,7 @@ case 700: ...@@ -8631,7 +8632,7 @@ case 700:
; ;
break;} break;}
case 701: case 701:
#line 3976 "gram.y" #line 3977 "gram.y"
{ {
FuncCall *n = makeNode(FuncCall); FuncCall *n = makeNode(FuncCall);
n->funcname = "substr"; n->funcname = "substr";
...@@ -8640,7 +8641,7 @@ case 701: ...@@ -8640,7 +8641,7 @@ case 701:
; ;
break;} break;}
case 702: case 702:
#line 3984 "gram.y" #line 3985 "gram.y"
{ {
FuncCall *n = makeNode(FuncCall); FuncCall *n = makeNode(FuncCall);
n->funcname = "btrim"; n->funcname = "btrim";
...@@ -8649,7 +8650,7 @@ case 702: ...@@ -8649,7 +8650,7 @@ case 702:
; ;
break;} break;}
case 703: case 703:
#line 3991 "gram.y" #line 3992 "gram.y"
{ {
FuncCall *n = makeNode(FuncCall); FuncCall *n = makeNode(FuncCall);
n->funcname = "ltrim"; n->funcname = "ltrim";
...@@ -8658,7 +8659,7 @@ case 703: ...@@ -8658,7 +8659,7 @@ case 703:
; ;
break;} break;}
case 704: case 704:
#line 3998 "gram.y" #line 3999 "gram.y"
{ {
FuncCall *n = makeNode(FuncCall); FuncCall *n = makeNode(FuncCall);
n->funcname = "rtrim"; n->funcname = "rtrim";
...@@ -8667,7 +8668,7 @@ case 704: ...@@ -8667,7 +8668,7 @@ case 704:
; ;
break;} break;}
case 705: case 705:
#line 4005 "gram.y" #line 4006 "gram.y"
{ {
FuncCall *n = makeNode(FuncCall); FuncCall *n = makeNode(FuncCall);
n->funcname = "btrim"; n->funcname = "btrim";
...@@ -8676,7 +8677,7 @@ case 705: ...@@ -8676,7 +8677,7 @@ case 705:
; ;
break;} break;}
case 706: case 706:
#line 4014 "gram.y" #line 4015 "gram.y"
{ {
A_Indices *ai = makeNode(A_Indices); A_Indices *ai = makeNode(A_Indices);
ai->lidx = NULL; ai->lidx = NULL;
...@@ -8685,7 +8686,7 @@ case 706: ...@@ -8685,7 +8686,7 @@ case 706:
; ;
break;} break;}
case 707: case 707:
#line 4021 "gram.y" #line 4022 "gram.y"
{ {
A_Indices *ai = makeNode(A_Indices); A_Indices *ai = makeNode(A_Indices);
ai->lidx = yyvsp[-4].node; ai->lidx = yyvsp[-4].node;
...@@ -8694,23 +8695,23 @@ case 707: ...@@ -8694,23 +8695,23 @@ case 707:
; ;
break;} break;}
case 708: case 708:
#line 4028 "gram.y" #line 4029 "gram.y"
{ yyval.list = NIL; ; { yyval.list = NIL; ;
break;} break;}
case 709: case 709:
#line 4032 "gram.y" #line 4033 "gram.y"
{ yyval.list = lcons(yyvsp[0].node, NIL); ; { yyval.list = lcons(yyvsp[0].node, NIL); ;
break;} break;}
case 710: case 710:
#line 4034 "gram.y" #line 4035 "gram.y"
{ yyval.list = lappend(yyvsp[-2].list, yyvsp[0].node); ; { yyval.list = lappend(yyvsp[-2].list, yyvsp[0].node); ;
break;} break;}
case 711: case 711:
#line 4036 "gram.y" #line 4037 "gram.y"
{ yyval.list = lappend(yyvsp[-2].list, yyvsp[0].node); ; { yyval.list = lappend(yyvsp[-2].list, yyvsp[0].node); ;
break;} break;}
case 712: case 712:
#line 4040 "gram.y" #line 4041 "gram.y"
{ {
A_Const *n = makeNode(A_Const); A_Const *n = makeNode(A_Const);
n->val.type = T_String; n->val.type = T_String;
...@@ -8719,66 +8720,66 @@ case 712: ...@@ -8719,66 +8720,66 @@ case 712:
; ;
break;} break;}
case 713: case 713:
#line 4047 "gram.y" #line 4048 "gram.y"
{ yyval.list = NIL; ; { yyval.list = NIL; ;
break;} break;}
case 714: case 714:
#line 4050 "gram.y" #line 4051 "gram.y"
{ yyval.str = yyvsp[0].str; ; { yyval.str = yyvsp[0].str; ;
break;} break;}
case 715: case 715:
#line 4051 "gram.y" #line 4052 "gram.y"
{ yyval.str = "tz_hour"; ; { yyval.str = "tz_hour"; ;
break;} break;}
case 716: case 716:
#line 4052 "gram.y" #line 4053 "gram.y"
{ yyval.str = "tz_minute"; ; { yyval.str = "tz_minute"; ;
break;} break;}
case 717: case 717:
#line 4056 "gram.y" #line 4057 "gram.y"
{ yyval.list = makeList(yyvsp[0].node, yyvsp[-2].node, -1); ; { yyval.list = makeList(yyvsp[0].node, yyvsp[-2].node, -1); ;
break;} break;}
case 718: case 718:
#line 4058 "gram.y" #line 4059 "gram.y"
{ yyval.list = NIL; ; { yyval.list = NIL; ;
break;} break;}
case 719: case 719:
#line 4062 "gram.y" #line 4063 "gram.y"
{ {
yyvsp[-1].attr->indirection = yyvsp[0].list; yyvsp[-1].attr->indirection = yyvsp[0].list;
yyval.node = (Node *)yyvsp[-1].attr; yyval.node = (Node *)yyvsp[-1].attr;
; ;
break;} break;}
case 720: case 720:
#line 4067 "gram.y" #line 4068 "gram.y"
{ yyval.node = yyvsp[0].node; ; { yyval.node = yyvsp[0].node; ;
break;} break;}
case 721: case 721:
#line 4069 "gram.y" #line 4070 "gram.y"
{ yyval.node = makeA_Expr(OP, "-", NULL, yyvsp[0].node); ; { yyval.node = makeA_Expr(OP, "-", NULL, yyvsp[0].node); ;
break;} break;}
case 722: case 722:
#line 4071 "gram.y" #line 4072 "gram.y"
{ yyval.node = makeA_Expr(OP, "+", yyvsp[-2].node, yyvsp[0].node); ; { yyval.node = makeA_Expr(OP, "+", yyvsp[-2].node, yyvsp[0].node); ;
break;} break;}
case 723: case 723:
#line 4073 "gram.y" #line 4074 "gram.y"
{ yyval.node = makeA_Expr(OP, "-", yyvsp[-2].node, yyvsp[0].node); ; { yyval.node = makeA_Expr(OP, "-", yyvsp[-2].node, yyvsp[0].node); ;
break;} break;}
case 724: case 724:
#line 4075 "gram.y" #line 4076 "gram.y"
{ yyval.node = makeA_Expr(OP, "/", yyvsp[-2].node, yyvsp[0].node); ; { yyval.node = makeA_Expr(OP, "/", yyvsp[-2].node, yyvsp[0].node); ;
break;} break;}
case 725: case 725:
#line 4077 "gram.y" #line 4078 "gram.y"
{ yyval.node = makeA_Expr(OP, "*", yyvsp[-2].node, yyvsp[0].node); ; { yyval.node = makeA_Expr(OP, "*", yyvsp[-2].node, yyvsp[0].node); ;
break;} break;}
case 726: case 726:
#line 4079 "gram.y" #line 4080 "gram.y"
{ yyval.node = makeA_Expr(OP, "|", NULL, yyvsp[0].node); ; { yyval.node = makeA_Expr(OP, "|", NULL, yyvsp[0].node); ;
break;} break;}
case 727: case 727:
#line 4081 "gram.y" #line 4082 "gram.y"
{ {
yyval.node = (Node *)yyvsp[-2].node; yyval.node = (Node *)yyvsp[-2].node;
/* AexprConst can be either A_Const or ParamNo */ /* AexprConst can be either A_Const or ParamNo */
...@@ -8796,7 +8797,7 @@ case 727: ...@@ -8796,7 +8797,7 @@ case 727:
; ;
break;} break;}
case 728: case 728:
#line 4097 "gram.y" #line 4098 "gram.y"
{ {
yyval.node = (Node *)yyvsp[-3].node; yyval.node = (Node *)yyvsp[-3].node;
/* AexprConst can be either A_Const or ParamNo */ /* AexprConst can be either A_Const or ParamNo */
...@@ -8814,23 +8815,23 @@ case 728: ...@@ -8814,23 +8815,23 @@ case 728:
; ;
break;} break;}
case 729: case 729:
#line 4113 "gram.y" #line 4114 "gram.y"
{ yyval.node = yyvsp[-1].node; ; { yyval.node = yyvsp[-1].node; ;
break;} break;}
case 730: case 730:
#line 4115 "gram.y" #line 4116 "gram.y"
{ yyval.node = makeA_Expr(OP, yyvsp[-1].str, yyvsp[-2].node, yyvsp[0].node); ; { yyval.node = makeA_Expr(OP, yyvsp[-1].str, yyvsp[-2].node, yyvsp[0].node); ;
break;} break;}
case 731: case 731:
#line 4117 "gram.y" #line 4118 "gram.y"
{ yyval.node = makeA_Expr(OP, yyvsp[-1].str, NULL, yyvsp[0].node); ; { yyval.node = makeA_Expr(OP, yyvsp[-1].str, NULL, yyvsp[0].node); ;
break;} break;}
case 732: case 732:
#line 4119 "gram.y" #line 4120 "gram.y"
{ yyval.node = makeA_Expr(OP, yyvsp[0].str, yyvsp[-1].node, NULL); ; { yyval.node = makeA_Expr(OP, yyvsp[0].str, yyvsp[-1].node, NULL); ;
break;} break;}
case 733: case 733:
#line 4121 "gram.y" #line 4122 "gram.y"
{ {
/* could be a column name or a relation_name */ /* could be a column name or a relation_name */
Ident *n = makeNode(Ident); Ident *n = makeNode(Ident);
...@@ -8840,7 +8841,7 @@ case 733: ...@@ -8840,7 +8841,7 @@ case 733:
; ;
break;} break;}
case 734: case 734:
#line 4129 "gram.y" #line 4130 "gram.y"
{ {
FuncCall *n = makeNode(FuncCall); FuncCall *n = makeNode(FuncCall);
n->funcname = yyvsp[-2].str; n->funcname = yyvsp[-2].str;
...@@ -8849,7 +8850,7 @@ case 734: ...@@ -8849,7 +8850,7 @@ case 734:
; ;
break;} break;}
case 735: case 735:
#line 4136 "gram.y" #line 4137 "gram.y"
{ {
FuncCall *n = makeNode(FuncCall); FuncCall *n = makeNode(FuncCall);
n->funcname = yyvsp[-3].str; n->funcname = yyvsp[-3].str;
...@@ -8858,7 +8859,7 @@ case 735: ...@@ -8858,7 +8859,7 @@ case 735:
; ;
break;} break;}
case 736: case 736:
#line 4143 "gram.y" #line 4144 "gram.y"
{ {
FuncCall *n = makeNode(FuncCall); FuncCall *n = makeNode(FuncCall);
n->funcname = "strpos"; n->funcname = "strpos";
...@@ -8867,7 +8868,7 @@ case 736: ...@@ -8867,7 +8868,7 @@ case 736:
; ;
break;} break;}
case 737: case 737:
#line 4150 "gram.y" #line 4151 "gram.y"
{ {
FuncCall *n = makeNode(FuncCall); FuncCall *n = makeNode(FuncCall);
n->funcname = "substr"; n->funcname = "substr";
...@@ -8876,7 +8877,7 @@ case 737: ...@@ -8876,7 +8877,7 @@ case 737:
; ;
break;} break;}
case 738: case 738:
#line 4158 "gram.y" #line 4159 "gram.y"
{ {
FuncCall *n = makeNode(FuncCall); FuncCall *n = makeNode(FuncCall);
n->funcname = "btrim"; n->funcname = "btrim";
...@@ -8885,7 +8886,7 @@ case 738: ...@@ -8885,7 +8886,7 @@ case 738:
; ;
break;} break;}
case 739: case 739:
#line 4165 "gram.y" #line 4166 "gram.y"
{ {
FuncCall *n = makeNode(FuncCall); FuncCall *n = makeNode(FuncCall);
n->funcname = "ltrim"; n->funcname = "ltrim";
...@@ -8894,7 +8895,7 @@ case 739: ...@@ -8894,7 +8895,7 @@ case 739:
; ;
break;} break;}
case 740: case 740:
#line 4172 "gram.y" #line 4173 "gram.y"
{ {
FuncCall *n = makeNode(FuncCall); FuncCall *n = makeNode(FuncCall);
n->funcname = "rtrim"; n->funcname = "rtrim";
...@@ -8903,7 +8904,7 @@ case 740: ...@@ -8903,7 +8904,7 @@ case 740:
; ;
break;} break;}
case 741: case 741:
#line 4179 "gram.y" #line 4180 "gram.y"
{ {
FuncCall *n = makeNode(FuncCall); FuncCall *n = makeNode(FuncCall);
n->funcname = "btrim"; n->funcname = "btrim";
...@@ -8912,21 +8913,21 @@ case 741: ...@@ -8912,21 +8913,21 @@ case 741:
; ;
break;} break;}
case 742: case 742:
#line 4188 "gram.y" #line 4189 "gram.y"
{ {
yyval.list = nconc(nconc(yyvsp[-2].list,yyvsp[-1].list),yyvsp[0].list); yyval.list = nconc(nconc(yyvsp[-2].list,yyvsp[-1].list),yyvsp[0].list);
; ;
break;} break;}
case 743: case 743:
#line 4192 "gram.y" #line 4193 "gram.y"
{ yyval.list = NIL; ; { yyval.list = NIL; ;
break;} break;}
case 744: case 744:
#line 4196 "gram.y" #line 4197 "gram.y"
{ yyval.list = yyvsp[0].list; ; { yyval.list = yyvsp[0].list; ;
break;} break;}
case 745: case 745:
#line 4198 "gram.y" #line 4199 "gram.y"
{ {
A_Const *n = makeNode(A_Const); A_Const *n = makeNode(A_Const);
n->val.type = T_Integer; n->val.type = T_Integer;
...@@ -8935,27 +8936,27 @@ case 745: ...@@ -8935,27 +8936,27 @@ case 745:
; ;
break;} break;}
case 746: case 746:
#line 4207 "gram.y" #line 4208 "gram.y"
{ yyval.list = yyvsp[0].list; ; { yyval.list = yyvsp[0].list; ;
break;} break;}
case 747: case 747:
#line 4209 "gram.y" #line 4210 "gram.y"
{ yyval.list = NIL; ; { yyval.list = NIL; ;
break;} break;}
case 748: case 748:
#line 4213 "gram.y" #line 4214 "gram.y"
{ yyval.list = lappend(yyvsp[0].list, yyvsp[-2].node); ; { yyval.list = lappend(yyvsp[0].list, yyvsp[-2].node); ;
break;} break;}
case 749: case 749:
#line 4215 "gram.y" #line 4216 "gram.y"
{ yyval.list = yyvsp[0].list; ; { yyval.list = yyvsp[0].list; ;
break;} break;}
case 750: case 750:
#line 4217 "gram.y" #line 4218 "gram.y"
{ yyval.list = yyvsp[0].list; ; { yyval.list = yyvsp[0].list; ;
break;} break;}
case 751: case 751:
#line 4221 "gram.y" #line 4222 "gram.y"
{ {
SubLink *n = makeNode(SubLink); SubLink *n = makeNode(SubLink);
n->subselect = yyvsp[0].node; n->subselect = yyvsp[0].node;
...@@ -8963,21 +8964,21 @@ case 751: ...@@ -8963,21 +8964,21 @@ case 751:
; ;
break;} break;}
case 752: case 752:
#line 4227 "gram.y" #line 4228 "gram.y"
{ yyval.node = yyvsp[0].node; ; { yyval.node = yyvsp[0].node; ;
break;} break;}
case 753: case 753:
#line 4231 "gram.y" #line 4232 "gram.y"
{ yyval.node = makeA_Expr(OP, "=", lfirst(saved_In_Expr), yyvsp[0].node); ; { yyval.node = makeA_Expr(OP, "=", lfirst(saved_In_Expr), yyvsp[0].node); ;
break;} break;}
case 754: case 754:
#line 4233 "gram.y" #line 4234 "gram.y"
{ yyval.node = makeA_Expr(OR, NULL, yyvsp[-2].node, { yyval.node = makeA_Expr(OR, NULL, yyvsp[-2].node,
makeA_Expr(OP, "=", lfirst(saved_In_Expr), yyvsp[0].node)); makeA_Expr(OP, "=", lfirst(saved_In_Expr), yyvsp[0].node));
; ;
break;} break;}
case 755: case 755:
#line 4239 "gram.y" #line 4240 "gram.y"
{ {
SubLink *n = makeNode(SubLink); SubLink *n = makeNode(SubLink);
n->subselect = yyvsp[0].node; n->subselect = yyvsp[0].node;
...@@ -8985,21 +8986,21 @@ case 755: ...@@ -8985,21 +8986,21 @@ case 755:
; ;
break;} break;}
case 756: case 756:
#line 4245 "gram.y" #line 4246 "gram.y"
{ yyval.node = yyvsp[0].node; ; { yyval.node = yyvsp[0].node; ;
break;} break;}
case 757: case 757:
#line 4249 "gram.y" #line 4250 "gram.y"
{ yyval.node = makeA_Expr(OP, "<>", lfirst(saved_In_Expr), yyvsp[0].node); ; { yyval.node = makeA_Expr(OP, "<>", lfirst(saved_In_Expr), yyvsp[0].node); ;
break;} break;}
case 758: case 758:
#line 4251 "gram.y" #line 4252 "gram.y"
{ yyval.node = makeA_Expr(AND, NULL, yyvsp[-2].node, { yyval.node = makeA_Expr(AND, NULL, yyvsp[-2].node,
makeA_Expr(OP, "<>", lfirst(saved_In_Expr), yyvsp[0].node)); makeA_Expr(OP, "<>", lfirst(saved_In_Expr), yyvsp[0].node));
; ;
break;} break;}
case 759: case 759:
#line 4257 "gram.y" #line 4258 "gram.y"
{ {
yyval.attr = makeNode(Attr); yyval.attr = makeNode(Attr);
yyval.attr->relname = yyvsp[-2].str; yyval.attr->relname = yyvsp[-2].str;
...@@ -9009,7 +9010,7 @@ case 759: ...@@ -9009,7 +9010,7 @@ case 759:
; ;
break;} break;}
case 760: case 760:
#line 4265 "gram.y" #line 4266 "gram.y"
{ {
yyval.attr = makeNode(Attr); yyval.attr = makeNode(Attr);
yyval.attr->relname = NULL; yyval.attr->relname = NULL;
...@@ -9019,27 +9020,27 @@ case 760: ...@@ -9019,27 +9020,27 @@ case 760:
; ;
break;} break;}
case 761: case 761:
#line 4275 "gram.y" #line 4276 "gram.y"
{ yyval.list = lcons(makeString(yyvsp[0].str), NIL); ; { yyval.list = lcons(makeString(yyvsp[0].str), NIL); ;
break;} break;}
case 762: case 762:
#line 4277 "gram.y" #line 4278 "gram.y"
{ yyval.list = lappend(yyvsp[-2].list, makeString(yyvsp[0].str)); ; { yyval.list = lappend(yyvsp[-2].list, makeString(yyvsp[0].str)); ;
break;} break;}
case 763: case 763:
#line 4279 "gram.y" #line 4280 "gram.y"
{ yyval.list = lappend(yyvsp[-2].list, makeString("*")); ; { yyval.list = lappend(yyvsp[-2].list, makeString("*")); ;
break;} break;}
case 764: case 764:
#line 4290 "gram.y" #line 4291 "gram.y"
{ yyval.list = lappend(yyvsp[-2].list,yyvsp[0].target); ; { yyval.list = lappend(yyvsp[-2].list,yyvsp[0].target); ;
break;} break;}
case 765: case 765:
#line 4292 "gram.y" #line 4293 "gram.y"
{ yyval.list = lcons(yyvsp[0].target, NIL); ; { yyval.list = lcons(yyvsp[0].target, NIL); ;
break;} break;}
case 766: case 766:
#line 4294 "gram.y" #line 4295 "gram.y"
{ {
ResTarget *rt = makeNode(ResTarget); ResTarget *rt = makeNode(ResTarget);
Attr *att = makeNode(Attr); Attr *att = makeNode(Attr);
...@@ -9054,7 +9055,7 @@ case 766: ...@@ -9054,7 +9055,7 @@ case 766:
; ;
break;} break;}
case 767: case 767:
#line 4309 "gram.y" #line 4310 "gram.y"
{ {
yyval.target = makeNode(ResTarget); yyval.target = makeNode(ResTarget);
yyval.target->name = yyvsp[-3].str; yyval.target->name = yyvsp[-3].str;
...@@ -9063,7 +9064,7 @@ case 767: ...@@ -9063,7 +9064,7 @@ case 767:
; ;
break;} break;}
case 768: case 768:
#line 4316 "gram.y" #line 4317 "gram.y"
{ {
yyval.target = makeNode(ResTarget); yyval.target = makeNode(ResTarget);
yyval.target->name = NULL; yyval.target->name = NULL;
...@@ -9072,7 +9073,7 @@ case 768: ...@@ -9072,7 +9073,7 @@ case 768:
; ;
break;} break;}
case 769: case 769:
#line 4323 "gram.y" #line 4324 "gram.y"
{ {
Attr *att = makeNode(Attr); Attr *att = makeNode(Attr);
att->relname = yyvsp[-2].str; att->relname = yyvsp[-2].str;
...@@ -9086,15 +9087,15 @@ case 769: ...@@ -9086,15 +9087,15 @@ case 769:
; ;
break;} break;}
case 770: case 770:
#line 4342 "gram.y" #line 4343 "gram.y"
{ yyval.list = lappend(yyvsp[-2].list, yyvsp[0].target); ; { yyval.list = lappend(yyvsp[-2].list, yyvsp[0].target); ;
break;} break;}
case 771: case 771:
#line 4344 "gram.y" #line 4345 "gram.y"
{ yyval.list = lcons(yyvsp[0].target, NIL); ; { yyval.list = lcons(yyvsp[0].target, NIL); ;
break;} break;}
case 772: case 772:
#line 4349 "gram.y" #line 4350 "gram.y"
{ {
yyval.target = makeNode(ResTarget); yyval.target = makeNode(ResTarget);
yyval.target->name = yyvsp[0].str; yyval.target->name = yyvsp[0].str;
...@@ -9103,7 +9104,7 @@ case 772: ...@@ -9103,7 +9104,7 @@ case 772:
; ;
break;} break;}
case 773: case 773:
#line 4356 "gram.y" #line 4357 "gram.y"
{ {
yyval.target = makeNode(ResTarget); yyval.target = makeNode(ResTarget);
yyval.target->name = NULL; yyval.target->name = NULL;
...@@ -9112,7 +9113,7 @@ case 773: ...@@ -9112,7 +9113,7 @@ case 773:
; ;
break;} break;}
case 774: case 774:
#line 4363 "gram.y" #line 4364 "gram.y"
{ {
Attr *att = makeNode(Attr); Attr *att = makeNode(Attr);
att->relname = yyvsp[-2].str; att->relname = yyvsp[-2].str;
...@@ -9126,7 +9127,7 @@ case 774: ...@@ -9126,7 +9127,7 @@ case 774:
; ;
break;} break;}
case 775: case 775:
#line 4375 "gram.y" #line 4376 "gram.y"
{ {
Attr *att = makeNode(Attr); Attr *att = makeNode(Attr);
att->relname = "*"; att->relname = "*";
...@@ -9140,22 +9141,22 @@ case 775: ...@@ -9140,22 +9141,22 @@ case 775:
; ;
break;} break;}
case 776: case 776:
#line 4388 "gram.y" #line 4389 "gram.y"
{ yyval.str = yyvsp[0].str; ; { yyval.str = yyvsp[0].str; ;
break;} break;}
case 777: case 777:
#line 4389 "gram.y" #line 4390 "gram.y"
{ yyval.str = NULL; ; { yyval.str = NULL; ;
break;} break;}
case 778: case 778:
#line 4393 "gram.y" #line 4394 "gram.y"
{ {
yyval.str = yyvsp[0].str; yyval.str = yyvsp[0].str;
StrNCpy(saved_relname, yyvsp[0].str, NAMEDATALEN); StrNCpy(saved_relname, yyvsp[0].str, NAMEDATALEN);
; ;
break;} break;}
case 779: case 779:
#line 4398 "gram.y" #line 4399 "gram.y"
{ {
/* disallow refs to variable system tables */ /* disallow refs to variable system tables */
if (strcmp(LogRelationName, yyvsp[0].str) == 0 if (strcmp(LogRelationName, yyvsp[0].str) == 0
...@@ -9167,43 +9168,43 @@ case 779: ...@@ -9167,43 +9168,43 @@ case 779:
; ;
break;} break;}
case 780: case 780:
#line 4409 "gram.y" #line 4410 "gram.y"
{ yyval.str = yyvsp[0].str; ; { yyval.str = yyvsp[0].str; ;
break;} break;}
case 781: case 781:
#line 4410 "gram.y" #line 4411 "gram.y"
{ yyval.str = yyvsp[0].str; ; { yyval.str = yyvsp[0].str; ;
break;} break;}
case 782: case 782:
#line 4411 "gram.y" #line 4412 "gram.y"
{ yyval.str = yyvsp[0].str; ; { yyval.str = yyvsp[0].str; ;
break;} break;}
case 783: case 783:
#line 4412 "gram.y" #line 4413 "gram.y"
{ yyval.str = yyvsp[0].str; ; { yyval.str = yyvsp[0].str; ;
break;} break;}
case 784: case 784:
#line 4413 "gram.y" #line 4414 "gram.y"
{ yyval.str = yyvsp[0].str; ; { yyval.str = yyvsp[0].str; ;
break;} break;}
case 785: case 785:
#line 4419 "gram.y" #line 4420 "gram.y"
{ yyval.str = yyvsp[0].str; ; { yyval.str = yyvsp[0].str; ;
break;} break;}
case 786: case 786:
#line 4420 "gram.y" #line 4421 "gram.y"
{ yyval.str = xlateSqlFunc(yyvsp[0].str); ; { yyval.str = xlateSqlFunc(yyvsp[0].str); ;
break;} break;}
case 787: case 787:
#line 4422 "gram.y" #line 4423 "gram.y"
{ yyval.str = yyvsp[0].str; ; { yyval.str = yyvsp[0].str; ;
break;} break;}
case 788: case 788:
#line 4423 "gram.y" #line 4424 "gram.y"
{ yyval.str = yyvsp[0].str; ; { yyval.str = yyvsp[0].str; ;
break;} break;}
case 789: case 789:
#line 4429 "gram.y" #line 4430 "gram.y"
{ {
A_Const *n = makeNode(A_Const); A_Const *n = makeNode(A_Const);
n->val.type = T_Integer; n->val.type = T_Integer;
...@@ -9212,7 +9213,7 @@ case 789: ...@@ -9212,7 +9213,7 @@ case 789:
; ;
break;} break;}
case 790: case 790:
#line 4436 "gram.y" #line 4437 "gram.y"
{ {
A_Const *n = makeNode(A_Const); A_Const *n = makeNode(A_Const);
n->val.type = T_Float; n->val.type = T_Float;
...@@ -9221,7 +9222,7 @@ case 790: ...@@ -9221,7 +9222,7 @@ case 790:
; ;
break;} break;}
case 791: case 791:
#line 4443 "gram.y" #line 4444 "gram.y"
{ {
A_Const *n = makeNode(A_Const); A_Const *n = makeNode(A_Const);
n->val.type = T_String; n->val.type = T_String;
...@@ -9230,7 +9231,7 @@ case 791: ...@@ -9230,7 +9231,7 @@ case 791:
; ;
break;} break;}
case 792: case 792:
#line 4450 "gram.y" #line 4451 "gram.y"
{ {
A_Const *n = makeNode(A_Const); A_Const *n = makeNode(A_Const);
n->typename = yyvsp[-1].typnam; n->typename = yyvsp[-1].typnam;
...@@ -9240,11 +9241,11 @@ case 792: ...@@ -9240,11 +9241,11 @@ case 792:
; ;
break;} break;}
case 793: case 793:
#line 4458 "gram.y" #line 4459 "gram.y"
{ yyval.node = (Node *)yyvsp[0].paramno; ; { yyval.node = (Node *)yyvsp[0].paramno; ;
break;} break;}
case 794: case 794:
#line 4460 "gram.y" #line 4461 "gram.y"
{ {
A_Const *n = makeNode(A_Const); A_Const *n = makeNode(A_Const);
n->val.type = T_String; n->val.type = T_String;
...@@ -9256,7 +9257,7 @@ case 794: ...@@ -9256,7 +9257,7 @@ case 794:
; ;
break;} break;}
case 795: case 795:
#line 4470 "gram.y" #line 4471 "gram.y"
{ {
A_Const *n = makeNode(A_Const); A_Const *n = makeNode(A_Const);
n->val.type = T_String; n->val.type = T_String;
...@@ -9268,238 +9269,238 @@ case 795: ...@@ -9268,238 +9269,238 @@ case 795:
; ;
break;} break;}
case 796: case 796:
#line 4482 "gram.y" #line 4483 "gram.y"
{ {
yyval.paramno = makeNode(ParamNo); yyval.paramno = makeNode(ParamNo);
yyval.paramno->number = yyvsp[0].ival; yyval.paramno->number = yyvsp[0].ival;
; ;
break;} break;}
case 797: case 797:
#line 4488 "gram.y" #line 4489 "gram.y"
{ yyval.ival = yyvsp[0].ival; ; { yyval.ival = yyvsp[0].ival; ;
break;} break;}
case 798: case 798:
#line 4489 "gram.y" #line 4490 "gram.y"
{ yyval.str = yyvsp[0].str; ; { yyval.str = yyvsp[0].str; ;
break;} break;}
case 799: case 799:
#line 4490 "gram.y" #line 4491 "gram.y"
{ yyval.str = yyvsp[0].str; ; { yyval.str = yyvsp[0].str; ;
break;} break;}
case 800: case 800:
#line 4498 "gram.y" #line 4499 "gram.y"
{ yyval.str = xlateSqlType(yyvsp[0].str); ; { yyval.str = xlateSqlType(yyvsp[0].str); ;
break;} break;}
case 801: case 801:
#line 4500 "gram.y" #line 4501 "gram.y"
{ yyval.str = xlateSqlType(yyvsp[0].str); ; { yyval.str = xlateSqlType(yyvsp[0].str); ;
break;} break;}
case 802: case 802:
#line 4502 "gram.y" #line 4503 "gram.y"
{ yyval.str = xlateSqlType(yyvsp[0].str); ; { yyval.str = xlateSqlType(yyvsp[0].str); ;
break;} break;}
case 803: case 803:
#line 4512 "gram.y" #line 4513 "gram.y"
{ yyval.str = yyvsp[0].str; ; { yyval.str = yyvsp[0].str; ;
break;} break;}
case 804: case 804:
#line 4513 "gram.y" #line 4514 "gram.y"
{ yyval.str = yyvsp[0].str; ; { yyval.str = yyvsp[0].str; ;
break;} break;}
case 805: case 805:
#line 4514 "gram.y" #line 4515 "gram.y"
{ yyval.str = "action"; ; { yyval.str = "action"; ;
break;} break;}
case 806: case 806:
#line 4515 "gram.y" #line 4516 "gram.y"
{ yyval.str = "cache"; ; { yyval.str = "cache"; ;
break;} break;}
case 807: case 807:
#line 4516 "gram.y" #line 4517 "gram.y"
{ yyval.str = "cycle"; ; { yyval.str = "cycle"; ;
break;} break;}
case 808: case 808:
#line 4517 "gram.y" #line 4518 "gram.y"
{ yyval.str = "database"; ; { yyval.str = "database"; ;
break;} break;}
case 809: case 809:
#line 4518 "gram.y" #line 4519 "gram.y"
{ yyval.str = "delimiters"; ; { yyval.str = "delimiters"; ;
break;} break;}
case 810: case 810:
#line 4519 "gram.y" #line 4520 "gram.y"
{ yyval.str = "double"; ; { yyval.str = "double"; ;
break;} break;}
case 811: case 811:
#line 4520 "gram.y" #line 4521 "gram.y"
{ yyval.str = "each"; ; { yyval.str = "each"; ;
break;} break;}
case 812: case 812:
#line 4521 "gram.y" #line 4522 "gram.y"
{ yyval.str = "encoding"; ; { yyval.str = "encoding"; ;
break;} break;}
case 813: case 813:
#line 4522 "gram.y" #line 4523 "gram.y"
{ yyval.str = "function"; ; { yyval.str = "function"; ;
break;} break;}
case 814: case 814:
#line 4523 "gram.y" #line 4524 "gram.y"
{ yyval.str = "increment"; ; { yyval.str = "increment"; ;
break;} break;}
case 815: case 815:
#line 4524 "gram.y" #line 4525 "gram.y"
{ yyval.str = "index"; ; { yyval.str = "index"; ;
break;} break;}
case 816: case 816:
#line 4525 "gram.y" #line 4526 "gram.y"
{ yyval.str = "key"; ; { yyval.str = "key"; ;
break;} break;}
case 817: case 817:
#line 4526 "gram.y" #line 4527 "gram.y"
{ yyval.str = "language"; ; { yyval.str = "language"; ;
break;} break;}
case 818: case 818:
#line 4527 "gram.y" #line 4528 "gram.y"
{ yyval.str = "location"; ; { yyval.str = "location"; ;
break;} break;}
case 819: case 819:
#line 4528 "gram.y" #line 4529 "gram.y"
{ yyval.str = "match"; ; { yyval.str = "match"; ;
break;} break;}
case 820: case 820:
#line 4529 "gram.y" #line 4530 "gram.y"
{ yyval.str = "maxvalue"; ; { yyval.str = "maxvalue"; ;
break;} break;}
case 821: case 821:
#line 4530 "gram.y" #line 4531 "gram.y"
{ yyval.str = "minvalue"; ; { yyval.str = "minvalue"; ;
break;} break;}
case 822: case 822:
#line 4531 "gram.y" #line 4532 "gram.y"
{ yyval.str = "operator"; ; { yyval.str = "operator"; ;
break;} break;}
case 823: case 823:
#line 4532 "gram.y" #line 4533 "gram.y"
{ yyval.str = "option"; ; { yyval.str = "option"; ;
break;} break;}
case 824: case 824:
#line 4533 "gram.y" #line 4534 "gram.y"
{ yyval.str = "password"; ; { yyval.str = "password"; ;
break;} break;}
case 825: case 825:
#line 4534 "gram.y" #line 4535 "gram.y"
{ yyval.str = "privileges"; ; { yyval.str = "privileges"; ;
break;} break;}
case 826: case 826:
#line 4535 "gram.y" #line 4536 "gram.y"
{ yyval.str = "recipe"; ; { yyval.str = "recipe"; ;
break;} break;}
case 827: case 827:
#line 4536 "gram.y" #line 4537 "gram.y"
{ yyval.str = "row"; ; { yyval.str = "row"; ;
break;} break;}
case 828: case 828:
#line 4537 "gram.y" #line 4538 "gram.y"
{ yyval.str = "start"; ; { yyval.str = "start"; ;
break;} break;}
case 829: case 829:
#line 4538 "gram.y" #line 4539 "gram.y"
{ yyval.str = "statement"; ; { yyval.str = "statement"; ;
break;} break;}
case 830: case 830:
#line 4539 "gram.y" #line 4540 "gram.y"
{ yyval.str = "time"; ; { yyval.str = "time"; ;
break;} break;}
case 831: case 831:
#line 4540 "gram.y" #line 4541 "gram.y"
{ yyval.str = "timezone_hour"; ; { yyval.str = "timezone_hour"; ;
break;} break;}
case 832: case 832:
#line 4541 "gram.y" #line 4542 "gram.y"
{ yyval.str = "timezone_minute"; ; { yyval.str = "timezone_minute"; ;
break;} break;}
case 833: case 833:
#line 4542 "gram.y" #line 4543 "gram.y"
{ yyval.str = "trigger"; ; { yyval.str = "trigger"; ;
break;} break;}
case 834: case 834:
#line 4543 "gram.y" #line 4544 "gram.y"
{ yyval.str = "type"; ; { yyval.str = "type"; ;
break;} break;}
case 835: case 835:
#line 4544 "gram.y" #line 4545 "gram.y"
{ yyval.str = "valid"; ; { yyval.str = "valid"; ;
break;} break;}
case 836: case 836:
#line 4545 "gram.y" #line 4546 "gram.y"
{ yyval.str = "version"; ; { yyval.str = "version"; ;
break;} break;}
case 837: case 837:
#line 4546 "gram.y" #line 4547 "gram.y"
{ yyval.str = "zone"; ; { yyval.str = "zone"; ;
break;} break;}
case 838: case 838:
#line 4559 "gram.y" #line 4560 "gram.y"
{ yyval.str = yyvsp[0].str; ; { yyval.str = yyvsp[0].str; ;
break;} break;}
case 839: case 839:
#line 4560 "gram.y" #line 4561 "gram.y"
{ yyval.str = "archive"; ; { yyval.str = "archive"; ;
break;} break;}
case 840: case 840:
#line 4561 "gram.y" #line 4562 "gram.y"
{ yyval.str = "cluster"; ; { yyval.str = "cluster"; ;
break;} break;}
case 841: case 841:
#line 4562 "gram.y" #line 4563 "gram.y"
{ yyval.str = "constraint"; ; { yyval.str = "constraint"; ;
break;} break;}
case 842: case 842:
#line 4563 "gram.y" #line 4564 "gram.y"
{ yyval.str = "cross"; ; { yyval.str = "cross"; ;
break;} break;}
case 843: case 843:
#line 4564 "gram.y" #line 4565 "gram.y"
{ yyval.str = "foreign"; ; { yyval.str = "foreign"; ;
break;} break;}
case 844: case 844:
#line 4565 "gram.y" #line 4566 "gram.y"
{ yyval.str = "group"; ; { yyval.str = "group"; ;
break;} break;}
case 845: case 845:
#line 4566 "gram.y" #line 4567 "gram.y"
{ yyval.str = "load"; ; { yyval.str = "load"; ;
break;} break;}
case 846: case 846:
#line 4567 "gram.y" #line 4568 "gram.y"
{ yyval.str = "order"; ; { yyval.str = "order"; ;
break;} break;}
case 847: case 847:
#line 4568 "gram.y" #line 4569 "gram.y"
{ yyval.str = "position"; ; { yyval.str = "position"; ;
break;} break;}
case 848: case 848:
#line 4569 "gram.y" #line 4570 "gram.y"
{ yyval.str = "precision"; ; { yyval.str = "precision"; ;
break;} break;}
case 849: case 849:
#line 4570 "gram.y" #line 4571 "gram.y"
{ yyval.str = "table"; ; { yyval.str = "table"; ;
break;} break;}
case 850: case 850:
#line 4571 "gram.y" #line 4572 "gram.y"
{ yyval.str = "transaction"; ; { yyval.str = "transaction"; ;
break;} break;}
case 851: case 851:
#line 4572 "gram.y" #line 4573 "gram.y"
{ yyval.str = "true"; ; { yyval.str = "true"; ;
break;} break;}
case 852: case 852:
#line 4573 "gram.y" #line 4574 "gram.y"
{ yyval.str = "false"; ; { yyval.str = "false"; ;
break;} break;}
case 853: case 853:
#line 4577 "gram.y" #line 4578 "gram.y"
{ {
if (QueryIsRule) if (QueryIsRule)
yyval.str = "*CURRENT*"; yyval.str = "*CURRENT*";
...@@ -9508,7 +9509,7 @@ case 853: ...@@ -9508,7 +9509,7 @@ case 853:
; ;
break;} break;}
case 854: case 854:
#line 4584 "gram.y" #line 4585 "gram.y"
{ {
if (QueryIsRule) if (QueryIsRule)
yyval.str = "*NEW*"; yyval.str = "*NEW*";
...@@ -9714,7 +9715,7 @@ yyerrhandle: ...@@ -9714,7 +9715,7 @@ yyerrhandle:
yystate = yyn; yystate = yyn;
goto yynewstate; goto yynewstate;
} }
#line 4592 "gram.y" #line 4593 "gram.y"
static Node * static Node *
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment