command line: send SQL file to new tab without starting new instance

bendy303's profile image bendy303 posted 4 years ago in General Permalink

Hi,

I have a large collection of snippets and I use a code preview utility in explorer (its actually Directory Opus). I want to send a sql snippet to Heidi with right click (possible with command line) without starting a new instance - just open a tab in the already running instance of Heidi.

is this possible?

Currently when I try to do this, a new instance of Heidi keeps opening.

I know I can drag and drop - but its cumbersome on laptop screen

help appreciated,

cheers

Ben

ansgar's profile image ansgar posted 4 years ago Permalink

Yes, you just need to disallow multiple instances in HeidiSQL:

Description

bendy303's profile image bendy303 posted 4 years ago Permalink

I already tried that....

does not work.

It still opens up other instances - just without the connection popup and I cannot view them.

also does not work if I put a shortcut of Heidi in the "SendTo" folder either.

I am using Heidi version 11, and on Windows 7

2 attachment(s):
  • Image-1632
  • Image-1633
ansgar's profile image ansgar posted 4 years ago Permalink

I suppose you did not restart HeidiSQL after disabling that setting?

bendy303's profile image bendy303 posted 4 years ago Permalink

maybe this has something to do with it. I tried to load multiple, just to test it. Code was:

"D:\Program Files ^\^Internet\HeidiSQL_11.0_64_Portable\heidisql.exe" "E:\Cloud\Dropbox\^code\dev snippets\SQL snippets!!!!!--cat with regex BERLIN.sql" "E:\Cloud\Dropbox\^code\dev snippets\SQL snippets\LOW PAY select all via Regex vB.sql" "E:\Cloud\Dropbox\^code\dev snippets\SQL snippets\Z____delete posts post type post.sql"

and i got this error. It seems to not recogise quotes.

1 attachment(s):
  • Image-1634
ansgar's profile image ansgar posted 4 years ago Permalink

I thought the problem was the new HeidiSQL instance?

bendy303's profile image bendy303 posted 4 years ago Permalink

I wanted to test it with multiple to try to solve it

bendy303's profile image bendy303 posted 4 years ago Permalink

I suppose you didnt test it?

bendy303's profile image bendy303 posted 4 years ago Permalink

I restarted it many times. It is 100% broken. I am using the portable version. could that be the problem?

bendy303's profile image bendy303 posted 4 years ago Permalink

I installed the non-portable version, it is also broken.

I also tried putting the .sql file on the root C: drive so there is no path with spaces. Does not work.

PLease fix. great product otherwise!!

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