Skip to content

Commit

Permalink
Testing experimental changes to support cross-db query in BABEL-5119
Browse files Browse the repository at this point in the history
Signed-off-by: P Aswini Kumar <[email protected]>
  • Loading branch information
P Aswini Kumar committed Aug 23, 2024
1 parent 6886c3c commit 2aa4924
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions contrib/babelfishpg_tsql/src/pl_exec.c
Original file line number Diff line number Diff line change
Expand Up @@ -4661,7 +4661,10 @@ exec_stmt_execsql(PLtsql_execstate *estate,
* schemas, Change the session property.
*/
if (stmt->schema_name != NULL && (strcmp(stmt->schema_name, "sys") == 0 || strcmp(stmt->schema_name, "information_schema") == 0))
{
set_session_properties(stmt->db_name);
SetCurrentRoleId(GetSessionUserId(), false);
}
}
if (stmt->is_dml || stmt->is_ddl || stmt->is_create_view)
{
Expand Down

0 comments on commit 2aa4924

Please sign in to comment.