I have a script running to iterate over 4-5 million rows. It keeps showing up in red in PgAdmin. It remains active.
How long does iteration over 4-5 million rows usually take?
Please share the SQL query, schema, and sample data. If you are using a third party script with a db connector, then the answer is much harder to answer.