1

I am using JayDeBeApi to connect to GridDB and use the standard SQL functionality offered by GridDB to load rows into my container. This is how I currently prepare the statement and execute it.

sql_query = "INSERT INTO container_name (col1,col2,col3) VALUES (?,?,?)"

cursor = conn.cursor()
for _, row in container_name.iterrows():
try:
    with conn.cursor() as cursor:
        cursor.execute(sql_query, tuple(row))
except Exception as e:
    print("Error:", e, ' ', row)

conn.commit()

I am looking to speed up the process as much as possible. Is there a bulk insert option or any equivalent option that I can use? Any help is greatly appreciated! Thanks!

Shuba
  • 21
  • 3

0 Answers0