Auto refresh queries?

mgroen posted 1 year ago in General

see attached video recording. I have set auto refresh to 2 seconds. I expect that the query is re-executed every 2 seconds. However, the query is not automatically re-executed.

edit: could not update video format (mp4) (not supported to this). So changed the upload to png file

Note: Also, could the forum please be upgraded to allow update of screenrecordings (mp4 format)?

1 attachment(s):
  • 2018-01-16_17-56-32
ansgar posted 1 year ago

Uploading an mp4 file...

Should work now. Thanks for the good hint.

ansgar posted 1 year ago

To answer your initial question: The auto-refresh feature is intentionally only for the data grid, the process list and some other grids, where Heidi has full control over the query executed in the back. The query editors can have quite dangerous commands, such as DROP and DELETE and whatever.

mgroen posted 1 year ago

Hi, not sure if I understand your answer completely. I am using a simple SELECT statement (nothing "dangerous" in that matter), and I want it to be automatically re-executed every 2 seconds...

Is this scenario supported?

I have also attached the recorded video, to illustrate what I did. Note: thanks for supporting mp4 format! Extra remark: I had to struggle to limit the file to 2MB... maybe file size could be increased?

1 attachment(s):
kalvaro posted 1 year ago

@mgroen What Anse tries to explain is that the Query tab is a free text editor where you can type any kind of SQL commands. Sure, you can type a SELECT one, but absolutely nothing prevents you from typing any other valid query or command, such as DELETE FROM customer or EXEC sp_wipe_out_data.

Misha v.3 posted 1 year ago

For me the requested feature looks too dangerous to be implemented and... not really useful.

apric posted 1 year ago

HeidiSQL is a tool for DBAs and professionals knowing what they are doing. Whether this is "too dangerous" should be left to the user.

I see valid use cases like showing live statistics, or simulating/testing a cronjob-like query (e.g. invalidating old cache entries etc.)

Maybe add a warning dialog for before periodically executing custom queries. (but please with the option to "never show this warning again")

mgroen posted 1 year ago

I totally agree with @apric

martinandersen3d posted 3 months ago

I have been looking for this for the last year !!!!! THANKS !

ansgar posted 3 months ago

If that's still of interest then please make an issue request in the bugtracker, and please follow what the issue template says.

Please login to leave a reply, or register at first.