sybase.vim


Ⅰ. 插件描述

Connect to a sybase database from within VIM

Ⅱ. 基本信息

创建日期:  2002-04-24
使用用户:  1
Github星:  1
插件作者:  Scott James

Ⅲ. 安装方法

使用Vundle管理器安装

在你的.vimrc下添加:
Plugin '/sybase-vim'
… 然后在Vim中运行以下命令:
:source %
:PluginInstall

对于Vundle版本 < 0.10.2,请用上面的Bundle替换Plugin。

使用NeoBundle管理器安装

在你的.vimrc下添加:
NeoBundle '/sybase-vim'
… 然后在Vim中运行以下命令:
:source %
:NeoBundleInstall

使用VimPlug管理器安装

在你的.vimrc下添加:
Plug '/sybase-vim'
… 然后在Vim中运行以下命令:
:source %
:PlugInstall

使用Pathogen管理器安装

在终端中运行以下命令:
cd ~/.vim/bundle
git clone https://github.com/vim-scripts/sybase.vim

Ⅳ. 文档说明

Follows is an adaption of sqlplus.vim written by Jamis Buck see http://vim.sourceforge.net/scripts/script.php?script_id=97
for the original.

This script contains code required to execute SQL queries from withing VIM.  It uses sqsh (http://www.sqsh.org/) however it could trivially be adapted to use isql.  It is very ruff and ready but seems to offer required functionality.

Thanks to Jamis Buck for creating sqlplus.vim I am sure if you compair the code you will see how little I have had to do to get this code to work ;-)

INSTRUCTIONS

Edit ~/.sqshrc and add the line set semicolon_hack=1

Save the code into a file and source from your .vimrc or use your favourate autoload system.

Edit the code to add the credentials for the databases you would like to connect to.

In highlight mode hit F8 to execute the hightlighed SQL.  It will cope with broken lines.

Hit F8 with no highlighted selection and VIM will prompt you for a database to connect to.

添加新评论