Skip to content

Commit

Permalink
Add check for schema name in funcame
Browse files Browse the repository at this point in the history
Signed-off-by: Chenxiao Wang <[email protected]>
  • Loading branch information
Chenxiao Wang committed Nov 15, 2024
1 parent 7ea609a commit e8aff48
Showing 1 changed file with 10 additions and 1 deletion.
11 changes: 10 additions & 1 deletion src/backend/parser/parse_func.c
Original file line number Diff line number Diff line change
Expand Up @@ -2062,7 +2062,16 @@ funcname_signature_string(const char *funcname, int nargs,

initStringInfo(&argbuf);

if (sql_dialect == SQL_DIALECT_TSQL && remove_db_name_in_schema_hook) {
/* Check if there is schema in funcname */
char * ptr = funcname;
while (ptr) {
if (*ptr == '.') {
break;
}
ptr++;
}

if (sql_dialect == SQL_DIALECT_TSQL && remove_db_name_in_schema_hook && ptr) {
funcname = (*remove_db_name_in_schema_hook)(funcname);
}

Expand Down

0 comments on commit e8aff48

Please sign in to comment.