Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to figure out when a SQL query will end?

Tags:

People also ask

Does SQL Between include end date?

The SQL BETWEEN Operator The BETWEEN operator selects values within a given range. The values can be numbers, text, or dates. The BETWEEN operator is inclusive: begin and end values are included.


Is there any way to figure out when a SQL query will end after it starts? In other words, is there any way to figure out how much time a query will take before query execution? (rough estimate is fine!)

ALTER IGNORE TABLE mytbl ADD UNIQUE (c);

I ran this query on innodb table that has 35 million records. c is varchar(255)

This command has been running for 10 hours and it still is running. I don't want to cancel if I'm close to the end.

I appreciate any help. Thank you!