Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit3d225b7

Browse files
committed
simplify handle_opexpr()
1 parentb92dae9 commit3d225b7

File tree

1 file changed

+4
-10
lines changed

1 file changed

+4
-10
lines changed

‎src/pg_pathman.c

Lines changed: 4 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1140,6 +1140,9 @@ handle_opexpr(const OpExpr *expr,
11401140
Node*param;
11411141
constPartRelationInfo*prel=context->prel;
11421142

1143+
/* Save expression */
1144+
result->orig= (constNode*)expr;
1145+
11431146
if (list_length(expr->args)==2)
11441147
{
11451148
/* Is it KEY OP PARAM or PARAM OP KEY? */
@@ -1157,9 +1160,6 @@ handle_opexpr(const OpExpr *expr,
11571160
expr->inputcollid,
11581161
strategy,context,result);
11591162

1160-
/* Save expression */
1161-
result->orig= (constNode*)expr;
1162-
11631163
return;/* done, exit */
11641164
}
11651165
/* TODO: estimate selectivity for param if it's Var */
@@ -1168,19 +1168,13 @@ handle_opexpr(const OpExpr *expr,
11681168
result->rangeset=list_make1_irange_full(prel,IR_LOSSY);
11691169
result->paramsel=estimate_paramsel_using_prel(prel,strategy);
11701170

1171-
/* Save expression */
1172-
result->orig= (constNode*)expr;
1173-
11741171
return;/* done, exit */
11751172
}
11761173
}
11771174
}
11781175

11791176
result->rangeset=list_make1_irange_full(prel,IR_LOSSY);
1180-
result->paramsel=1.0;/* can't give any estimates */
1181-
1182-
/* Save expression */
1183-
result->orig= (constNode*)expr;
1177+
result->paramsel=1.0;
11841178
}
11851179

11861180

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp