Getting the error while insert the data into sql local temporary table using AWS Lambda

Viewed 25

Getting the error while insert the data into RDS server sql local temporary table using AWS Lambda python.Temp table already created in RDS sql server.

Code

sql10 = f"""SELECT col1, col2, col3, col4 FROM table1 ORDER BY col4 ;"""
select_snow =cs.execute(sql10).fetchall()
                
rds_columns = [(c[0],c[1],c[2],c[3]) for c in select_snow]
                
sql11 = f"INSERT INTO #TempTable(co1,co2,co3,co4) VALUES (?, ?, ?, ?);"
data = (rds_columns)
cursor.executemany(sql11,data)

Error

"ERROR: Unexpected error! - ('42S02', \"[42S02] [Microsoft][ODBC Driver 17 for SQL Server][SQL Server]Invalid object name '#TempTable
0 Answers
Related