I can see a answer for my question in the following post How to read from one DB but write to another using Snowflake's Snowpark?
Since i do not have access to add comment raising as separate question here.
I really new to snowflake and snowpark. I have to copy data from Prod DB to Test DB. both are having different users and different roles. I may need to create 2 sessions to connect the databases. How to pass the data from Prod snowpark session to test snow park session session.
Source session parameters
connection_parameters = {
"account": "abc.snowflake.come",
"user": "Produser1",
"password": "123",
"role": "PROD_USER",
"warehouse": "WF_IT",
"database": "ProdUser",
"schema": "user"
}
Target session parameters
connection_parameters = {
"account": "abc.snowflake.come",
"user": "TestUser1",
"role": "Test_USER",
"warehouse": "WF_IT",
"database": "DevUser",
"schema": "user"
}