Skip to content

Commit

Permalink
Avoid hard-coding OIDs
Browse files Browse the repository at this point in the history
  • Loading branch information
PierreSenellart committed Aug 30, 2024
1 parent fd665cb commit 2319836
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/provsql.c
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@
#include "parser/parsetree.h"
#include "storage/lwlock.h"
#include "storage/shmem.h"
#include "utils/fmgroids.h"
#include "utils/syscache.h"
#include "utils/lsyscache.h"
#include "utils/guc.h"
Expand Down Expand Up @@ -559,7 +560,7 @@ static Expr *make_aggregation_expression(
expr_s->funcresulttype = constants->OID_TYPE_UUID;

//check the particular case of count
if(agg_ref->aggfnoid==2803||agg_ref->aggfnoid==2147) //count(*) or count(arg)
if(agg_ref->aggfnoid==F_COUNT_||agg_ref->aggfnoid==F_COUNT_ANY) //count(*) or count(arg)
{
Const *one = makeConst(constants->OID_TYPE_INT,
-1,
Expand Down

0 comments on commit 2319836

Please sign in to comment.