Vim dadbod configuring adapters - sql-server

I'm trying to configure the plugin dadbod (https://github.com/tpope/vim-dadbod) and must confess I don't know vimscript well enough to comprehend the code :(
I'm stuck on configuring the database adapters. Irrespective of what URL I try, I just get the message
DB: no adapter for SQL Server.
I've also tried SQLite and Postgres with the same results.
In the WIKI, there's a statement: Supports a modern array of backends - which makes me think I haven't configured "the backend" perhaps? I have the jdbc SQL Server driver installed, and set a JAVA_HOME environment variable which works fine with DBeaver and with Azure Data Studio.
I haven't been able to find anything on the web about how to configure dadbod beyond the command structure. Am I missing something obvious about how the plugin works?
Your help greatly appreciated!

The vim-dadbod plugin was definitely not installed correctly. I did a clean install of Vim, then installed the package manager Vundle. Following Vundle's instructions I was able to install vim-dadbod.
I'll be posting a followup later, but the issue is no longer the plugin itself!

Related

Laravel 4.2 SQL Server - PDOException - could not find driver

I got the error on the title in my project (which is working well in production on remote server). My local server is Apache, WAMP package.
By default, SQL Server is the database conection so I can't even login. I'm going to share many screenshots because I try many solutions what I found while searching on Google but no one fix my issue.
First of all, the exception message which is almost the same for everyone.
[
So now, my System variables with PHP and Postgrade path.
Here is the PHP Extension list enabled/disabled
And the "extension_dir" on PHP.ini
Finally, laravel files setting up the connection...
start.php -> set my "local" environment
and my local/database.php settings
So I got eveything properly setted (I think) and even like this I can't connect.
Any some other help, please?
Finally, the problem was the arquitecture used on WAMP, should be 32bits, not 64 as I got.

SSIS deployment yields Error 27123

An attempted deployment from (localhost) to (remote server) yielded the Error 27123 which, appears to be a credentials-related issue. After spending several hours the resolution appears to be one of assigning local-to-the-remote server Windows credentials that are used to launch DTEexec.exe. I am using VS2012 Ultimate locally with SQL Server 2014 Developer version and remote SQL version 2012 SP1. However, my attempts have failed so far.
I would VERY much like to be able to deploy to the remote server inside of VS2012, including creating folders, etc but am still at a loss as to the missing piece needed.
We do not have Active Directory set up as the remote is on the Amazon S3 cloud bit other than that is pretty much a plain vanilla setup. I also noted some folks suggested a Kerberos-based response but before I ask our network guru to proceed I'd like at least to get confirmation.
I AM able to manually FTP, install and run packages when remoted in but that stinks for my contractor who I would also like to be able to have me out of his way. s
All found online materials have not yet yielded the one last piece. I suspect my ignorance rather than the lack of a real solution and would appreciate any guidance.
Thanks in advance.

xampp apache wont start after oracle db 10g is installed. how to fix?

I've been doing php before but as usual,I used mysql as a database. So everything seems easy when using xampp.
Now, for some reason I am required to use Oracle as the database but after installing Oracle database 10g on my pc, I can't seem to start apache from the control panel at all! When I press start,instead of it being started it goes back to the stopped state. I tried making it a service and starting it from, it pops out an error.
What is making this conflict, I can use IIS to do this but I prefer xampp so I'm eager to make this thing work.
Does anyone know whats the conflict? Is it the port?
I know how to configure the oracle extension and all with php to get it to work, but I am just confused why apache can't be started when oracle db 10g is installed.
Hope someone can help me out.
I just had this problem with startup.pl not starting (according to the log files), so I went into xampp\apache\conf\httpd.conf and editted out this include line by putting a hash (or pound as it is called in the states) (#) in front of it:
Perl settings
Include "conf/extra/httpd-perl.conf"
it seems to work now and I have now got oracle and apache working on my machine.
Im not sure if there will be any problems later on because of removing the line, but I don't think I need to use anything perl related so hopefully it will be fine
Sounds like platform is Windows. Oracle has the habit to alter the PATH setting, system wide. There is also an Apache installation in the Oracle installation. Maybe you can tweak the Apache service to use the Oracle Apache installation. Otherwise, make sure that your Apache start service does not have ORACLE_HOME or sub-directories of ORACLE_HOME/bin in the PATH. The services that Oracle installs normally are not on the standard ports so it's not very likely that it is a port conflict.

using doctrine 2 with SQL Server

I need to migrate an existing project, built on the current beta of doctrine 2, from mysql to SQL Server.
I have complete control of the SQL Server.
In the DBAL Folder of Doctrine there already is a PDOMsSql driver, but I can't figure out, how to use it. (there is still no documentation)
Doctrine also offers two other ways, I could maybe use:
driverClass: Specifies a custom driver implementation if no 'driver' is specified. This allows the use of custom drivers that are not part of the Doctrine DBAL itself.
pdo: Specifies an existing PDO instance to use.
Could anyone help me with this? I have no clue how to start here, since I have no experience with ODBC/PDO and SQL Server at all.
I figured it out by myself... on a mac, "mssql.so" does only provide "dblib:" as a driver. So by replacing dbo_mssql in the Doctrine Driver with "dblib", defining a FreeTDS host and using its name as the hostname for my connection, everything works fine.
You can also use sqlsrv or pdosqlsrv now. I submitted changes to the pdosqlsrv driver in the Doctrine DBAL project today that fix some things with the DSN creation and get it working. Sqlsrv/pdosqlsrv is probably the way to go imo since Microsoft is actively developing it.

Connecting to SQL Server (from Ubuntu): [RubyODBC] Cannot allocate SQLHENV

I'm trying to connect my Ruby on Rails application to a legacy Database that is in a Microsoft SQL Server 2008. I have looked around different tutorials, pages, help pages, and question pages and still haven't been able to make it work.
I'm using:
Ubuntu karmic
Rails 2.3.5
Ruby 1.8.7
activerecord-odbc-adapter 2.0
activerecord-sqlserver-adapter 2.3
dbd-odbc 0.2.5
dbi 0.4.3
I also have installed:
freeTDS 0.82-6
tdsodbc 0.82-6
sqsh 2.1-8build1
libodbc-ruby1.8 0.9997-2 (have also tried with 0.9995 and 0.9998)
unixodbc 2.2.11-16ubuntu1
I have managed to connect to the database with tsql, sqsh and isql. But can't connect it through irb nor through rails. Whenever I try I get the following error:
DBI::DatabaseError: **INTERN (0) [RubyODBC]Cannot allocate SQLHENV**
from /var/lib/gems/1.8/gems/dbd-odbc-0.2.5/lib/dbd/odbc/driver.rb:36:in `connect'
from /usr/lib/ruby/1.8/dbi/handles/driver.rb:33:in `connect'
from /usr/lib/ruby/1.8/dbi.rb:142:in `connect'
from (irb):4
It doesn't really matter if I use the odbc-adapter or the sql-adapter, because it always fails in the dbi driver. Any ideas on what can be wrong?
I have the odbc.ini, odbcinst.ini and freetds.conf files properly defined. And they are working with all the other commands to connect (isql, tsql, sqsh).
Please help me or point me somewhere that might help me! =)
PS: I have already followed the following pages with not much success (among others):
wiki.rubyonrails.org/database-support/ms-sql?s[]=sql&s[]=server
piao-tech.blogspot.com/2008/02/using-activerecord-with-microsoft-sql.html
lambie.org/2008/02/28/connecting-to-an-mssql-database-from-ruby-on-ubuntu/
stackoverflow.com/questions/1419397/rubyodbc-cannot-allocate-sqlhenv
This page seems to suggest that the problem may be related to the inability to find a shared library. You should ensure that the system can find any libraries it may need by checking the output of ldconfig -v and ensuring that the folders containing libodbc, libodbcinst and libtdsodbc are included in the library search path. If you are not sure how to do this then this link may help.
If this fails then build the gem manually using the following line
ruby extconf.rb --with-odbc-dir=/folder/to/unixodbc --disable-dlopen
I can't swear that this is the correct answer but it may help. I do have freetds and SQL Server working quite happily with rails on Centos
If you can switch to JRuby ( jruby.org ) you can try using the active-record-jdbc gem with the MS SQL server JDBC driver. I use them to connect to a MS SQL Server 2005 database from Ruby and it works like a charm.
Hope it helps!

Resources