4

I've switched from helm to Ivy and mostly everything works, but today I noticed that connecting to databases with sql-connect doesn't work anymore. I have the following in the variable sql-connection-alist

(setq sql-connection-alist
  '(("dev" (sql-product 'postgres)
     (sql-database "testdb")
     (sql-user "testuser")
     (sql-server "localhost")
     (sql-password ""))))

which was sufficient under helm and vanilla emacs for running M-x sql-connect and connecting to a database. When I run it under Ivy though, I get a prompt that looks similar to this:

0    Connection: 

When I type dev and press <enter> or try to tab complete, the prompt changes to

0    Connection (match required): dev

and I can't get any further. The match required part is red, indicating an error, but I don't know how to get past this point. If it were a tab-completion, I'd at least expect typing "dev" and pressing <enter> to be sufficient, but I get the same error.

What do I need to do to connect to a database using Ivy in emacs?

  • This is something that was working with earlier versions of ivy -- I've been meaning to file an ivy issue for this problem. I've hit this a couple times and have just done M-x ivy-mode to turn ivy off (then back on) around a sql-connect command. – glucas Jul 18 '17 at 18:13
  • I filed github.com/abo-abo/swiper/issues/1112 for this. – glucas Jul 18 '17 at 18:17
4

This is an issue in ivy, so I filed it: https://github.com/abo-abo/swiper/issues/1112.

And it's already been fixed!

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.