tpope / vim-dadbod

dadbod.vim: Modern database interface for Vim
https://www.vim.org/scripts/script.php?script_id=5665
3.75k stars 132 forks source link

DB: 'env' executable not found #159

Closed TasseDo closed 9 months ago

TasseDo commented 9 months ago

I get the error in title when trying to connect to a SQL Server database using :DB sqlserver:// and the UI, sqlcmd is available in path.

I've seen the previous issue #146, but I need to use a password in my case so I don't know if I'm missing something obvious or it's normal that it doesn't work?

Any pointers appreciated

Thanks,

OS: Windows 11 Editor: nvim v0.9.2

tpope commented 9 months ago

Fixing would require adopting the use of the env options to job_start() and jobstart(). As a partial workaround, I've avoided calling env if there isn't a password.

I've gone ahead and done this.

TasseDo commented 9 months ago

Thanks a lot! Extremely appreciated

anish1617 commented 6 months ago

I'm stil getting this 'env' executable not found error while connecting to azure sql server. Can you please help me if someone has solved this issue. Appreciate the help.

tpope commented 6 months ago

This should be solved for everyone. For vanilla Vim, you'll need 8.2.0239 or newer.

anish1617 commented 6 months ago

Really Sorry, for not being descriptive. I'm new to vim and this is what i did. I'm using neovim and Lazy package manager: return { 'tpope/vim-dadbod', { 'kristijanhusak/vim-dadbod-completion', ft = { 'sql', 'mssql' } }, 'kristijanhusak/vim-dadbod-ui', } And i have updated my plugin from :Lazy and my connection is as follows: sqlserver://user1:password123$$$$@some-random-values-45612315d.database.windows.net:1433/customerdb does having $ character in password needs to be escaped?

it keeps saying error connecting to db cutomerdb: Db 'env' executable not found.

tpope commented 6 months ago

Oh I see, there's a bug. Should be fixed now.