This is an automated email from the ASF dual-hosted git repository.
chenjinbao1989 pushed a commit to branch cbdb-postgres-merge
in repository https://gitbox.apache.org/repos/asf/cloudberry.git
The following commit(s) were added to refs/heads/cbdb-postgres-merge by this
push:
new 5ca7f4af36a Convert an empty string to NULL in url
5ca7f4af36a is described below
commit 5ca7f4af36a21e4379867520e80248598d8d8b26
Author: Jinbao Chen <[email protected]>
AuthorDate: Fri Dec 26 02:51:32 2025 +0800
Convert an empty string to NULL in url
---
gpcontrib/gp_exttable_fdw/extaccess.c | 10 ++++++++--
1 file changed, 8 insertions(+), 2 deletions(-)
diff --git a/gpcontrib/gp_exttable_fdw/extaccess.c
b/gpcontrib/gp_exttable_fdw/extaccess.c
index f283239dda3..220867e7995 100644
--- a/gpcontrib/gp_exttable_fdw/extaccess.c
+++ b/gpcontrib/gp_exttable_fdw/extaccess.c
@@ -186,7 +186,10 @@ external_beginscan(Relation relation, uint32 scancounter,
{
v = list_nth(uriList, idx);
- uri = strVal(v);
+ if (strlen(v->sval) == 0)
+ uri = NULL;
+ else
+ uri = strVal(v);
}
}
/*
@@ -202,7 +205,10 @@ external_beginscan(Relation relation, uint32 scancounter,
{
String *v = list_nth(uriList, 0);
- uri = strVal(v);
+ if (strlen(v->sval) == 0)
+ uri = NULL;
+ else
+ uri = strVal(v);
}
}
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]