Account Options

  1. Sign in
The old Google Groups will be going away soon, but your browser is incompatible with the new version.
Google Groups Home
« Groups Home
Vim for Oracle
There are currently too many topics in this group that display first. To make this topic appear first, remove this option from another topic.
There was an error processing your request. Please try again.
flag
  16 messages - Collapse all  -  Translate all to Translated (View all originals)
The group you are posting to is a Usenet group. Messages posted to this group will make your email address visible to anyone on the Internet.
Your reply message has not been sent.
Your post was successful
 
From:
To:
Cc:
Followup To:
Add Cc | Add Followup-to | Edit Subject
Subject:
Validation:
For verification purposes please type the characters you see in the picture below or the numbers you hear by clicking the accessibility icon. Listen and type the numbers you hear
 
vicky b  
View profile  
 More options Sep 24 2012, 12:55 pm
From: vicky b <vickyb2...@gmail.com>
Date: Mon, 24 Sep 2012 22:24:41 +0530
Local: Mon, Sep 24 2012 12:54 pm
Subject: Vim for Oracle

HI All,

 I am  an enthusiastic vim fan but never used it much .I use sqldeveloper
for db related tasks.Due you guys really feel comfortable in vim to write
pl/sql and also can you guys also query the db and see the resutlset
through vim.

--
*Thanks & Regards
 Vickyb

*


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Paul Stewart  
View profile  
 More options Sep 24 2012, 1:07 pm
From: Paul Stewart <paulbrianstew...@gmail.com>
Date: Mon, 24 Sep 2012 10:07:43 -0700
Local: Mon, Sep 24 2012 1:07 pm
Subject: Re: Vim for Oracle

Hi Vicky,

Yes to both questions. If you download the dbext script from the vim.org
site you can access and view the data on any db. I use it in my
day-to-day work...

The instructions are pretty straightforward on the script, so have a
look and let me know if you have questions.

http://www.vim.org/scripts/script.php?script_id=356

Thanks
Paul Stewart

On 09/24/2012 09:54 AM, vicky b wrote:


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Tim Chase  
View profile  
 More options Sep 24 2012, 1:16 pm
From: Tim Chase <v...@tim.thechases.com>
Date: Mon, 24 Sep 2012 12:17:15 -0500
Local: Mon, Sep 24 2012 1:17 pm
Subject: Re: Vim for Oracle
On 09/24/12 11:54, vicky b wrote:

>  I am  an enthusiastic vim fan but never used it much .I use sqldeveloper
> for db related tasks.Due you guys really feel comfortable in vim to write
> pl/sql and also can you guys also query the db and see the resutlset
> through vim.

While I don't use it regularly for Oracle/pl/sql, I do use it for
T-SQL on SQL-Server for my day job.  I don't use the dbext script
that Paul mentions, but I don't usually use *any* scripts, so don't
take it as a negative mark :-)

I usually just use vim for easy formatting, and the power of :g and
:s commands.  I usually keep the master SQL in vim and copy into
Query Analyzer to test.

-tim


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
vicky b  
View profile  
 More options Sep 24 2012, 1:19 pm
From: vicky b <vickyb2...@gmail.com>
Date: Mon, 24 Sep 2012 22:49:27 +0530
Local: Mon, Sep 24 2012 1:19 pm
Subject: Re: Vim for Oracle

Thanks for the replies guys but in the present world where we leave with so
much of ide and code completion and so many features what is that makes you
guys stick to vim .. does it make your job simpler or features are great or
your use to it.

--
*Thanks & Regards
 Vickyb

*


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Paul Stewart  
View profile  
 More options Sep 24 2012, 1:21 pm
From: Paul Stewart <paulbrianstew...@gmail.com>
Date: Mon, 24 Sep 2012 10:21:02 -0700
Local: Mon, Sep 24 2012 1:21 pm
Subject: Re: Vim for Oracle
Actually, I do that too, I should've mentioned...I think the thing that
I like about the dbext script is that I can do quick data validation
before I cut and paste into other functions etc (if I'm embedding in a
c# program or something similar)...I do like that with the script I can
do all my work however without the need for any other editor...
Paul

On 09/24/2012 10:17 AM, Tim Chase wrote:


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Paul Stewart  
View profile  
 More options Sep 24 2012, 1:22 pm
From: Paul Stewart <paulbrianstew...@gmail.com>
Date: Mon, 24 Sep 2012 10:22:02 -0700
Local: Mon, Sep 24 2012 1:22 pm
Subject: Re: Vim for Oracle
I should also mention that I use viemu on Visual Studio too....so I have
a variety of tools to meet my needs
www.viemu.com

Paul

On 09/24/2012 10:17 AM, Tim Chase wrote:


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Paul Stewart  
View profile  
 More options Sep 24 2012, 1:30 pm
From: Paul Stewart <paulbrianstew...@gmail.com>
Date: Mon, 24 Sep 2012 10:30:16 -0700
Local: Mon, Sep 24 2012 1:30 pm
Subject: Re: Vim for Oracle

For me personally, number of reasons, but probably the main ones:

--it is so small
--it's fast
--it's totally customizable (you can pretty much set it up exactly as
you need/want it)
--it works on pretty much every OS
--once you get used to it is it incredibly fast to use...it's so much
quicker than if you have to use the mouse...it frees your mind to
concentrate on the code, not the editor
--it's free!!

There are many many other reasons, these are just a few of my own ones.

Hope that helps...I would say give it a try....personally, I don't think
you'll go back to another editor once you get proficient on vim

On 09/24/2012 10:19 AM, vicky b wrote:


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Tim Chase  
View profile  
 More options Sep 24 2012, 1:34 pm
From: Tim Chase <v...@tim.thechases.com>
Date: Mon, 24 Sep 2012 12:36:03 -0500
Local: Mon, Sep 24 2012 1:36 pm
Subject: Re: Vim for Oracle
On 09/24/12 12:19, vicky b wrote:

> Thanks for the replies guys but in the present world where we
> leave with so much of ide and code completion and so many
> features what is that makes you guys stick to vim .. does it make
> your job simpler or features are great or your use to it.

First, I've used Vim for so long that I now find things like ":w"
appearing in my other editing tools (Query Analyzer, Word, etc), so
using Vim is habit.

Also, the power of Vim makes it very easy to perform quick
transformations on text/queries which I regularly do.  For DB work,
one I frequently do is a

  SELECT TOP 1 * FROM SomeTable

and run it in text-mode (rather than grid-mode).  I then copy out
the headers in the results, paste them into Vim and issue a

  :s/\t/,\r/g

to turn them into named columns that I can order as I see fit,
without hand-entering them all.  That often makes the foundation of
a SELECT clause for me.

Matching parens/braces, syntax highlighting, batch transforms,
macros, etc. are all reasons I have trouble stepping away from Vim.

-tim


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Paul Stewart  
View profile  
 More options Sep 24 2012, 1:46 pm
From: Paul Stewart <paulbrianstew...@gmail.com>
Date: Mon, 24 Sep 2012 10:45:54 -0700
Local: Mon, Sep 24 2012 1:45 pm
Subject: Re: Vim for Oracle
look at that...I learn something new today....

  :s/\t/,\r/g

I didn't know that one...thanks

On 09/24/2012 10:36 AM, Tim Chase wrote:


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Tim Chase  
View profile  
 More options Sep 24 2012, 1:51 pm
From: Tim Chase <v...@tim.thechases.com>
Date: Mon, 24 Sep 2012 12:52:51 -0500
Local: Mon, Sep 24 2012 1:52 pm
Subject: Re: Vim for Oracle
On 09/24/12 12:45, Paul Stewart wrote:

> look at that...I learn something new today....

>   :s/\t/,\r/g

> I didn't know that one...thanks

Granted, I'm lazy, so I've also been known to write SQL queries that
return SQL queries as the result-set, and then run those in turn. :-)

-tim


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
David Fishburn  
View profile  
 More options Sep 24 2012, 10:18 pm
From: David Fishburn <dfishburn....@gmail.com>
Date: Mon, 24 Sep 2012 22:18:23 -0400
Local: Mon, Sep 24 2012 10:18 pm
Subject: Re: Vim for Oracle

On 24/09/2012 1:19 PM, vicky b wrote:

> Thanks for the replies guys but in the present world where we leave
> with so much of ide and code completion and so many features what is
> that makes you guys stick to vim .. does it make your job simpler or
> features are great or your use to it.

I am the maintainer of dbext and a host of other related SQL support in Vim.

IDE features provided by other software are great and a number of them
have been added to Vim via plugins.

SrchRplcHiGrp.vim : Search and/or replace based on a syntax highlight group

http://www.vim.org/scripts/script.php?script_id=848
<http://www.vim.org/scripts/script.php?script_id=848>

Since I work with SQL all day, I primarily created it to UPPER CASE
keywords (SELECT, UPDATE, FROM, WHERE, ...) in SQL. But, it has nothing
to do with SQL.

Basically, if Vim can colour highlight text in a file, then you can
choose to search and replace on those colour highlights. I justchoose
sqlKeyword highlighting keywords and then to do a search and replace to
transform those words into UPPER CASE strings.

There is also this plugin:
SQLUtilities : SQL utilities - Formatting, generate - columns lists,
procedures for databases
http://www.vim.org/scripts/script.php?script_id=492
<http://www.vim.org/scripts/script.php?script_id=492>

The main purpose of this plugin is it will reformat SQL queries into a
nice readable format. But it has another option which will allow you
to UPPER CASE your keywords as well.

Tim, I noticed you mentioned you format SQL, have a look at the web page
for this plugin it shows a few formatting examples.

dbext.vim : Provides database access to many dbms (Oracle, Sybase,
Microsoft, MySQL, DBI,..)
http://www.vim.org/scripts/script.php?script_id=356
<http://www.vim.org/scripts/script.php?script_id=356>

This one was mentioned by Paul.  It can do far more than simply execute SQL.
One of the most useful features I find is the ability to execute SQL and
prompt you for input parameters.  It can also do this for many different
fileformats.  For example  assume you had the following Java code:

     String mySQL =
         "SELECT s.script, ts.event, t.name                  " +
         "     , s.script_language, sv.name                  " +
         "  FROM ml_script s, ml_table_script ts, ml_table t " +
             "     , ml_script_version sv                        " +
         " WHERE s.script_id   = " + script_version +
         "   AND ts.version    = "+obj.method() +
         "   AND ts.table_id   = t.table_id                  ";

  If you visually select from the "SELECT ... to the "; and ran
  :'<,'>DBExecSQL

  The Java filetype support would concatenate each individual string into
  one single string.  In this case it removed the " + " and concatenated
  the lines to result in the following (assuming this is on one line):
           SELECT s.script, ts.event, t.name , s.script_language, sv.name
            FROM ml_script s, ml_table_script ts, ml_table t
                   , ml_script_version sv
           WHERE s.script_id   = " + script_version + "
             AND ts.version    = "+obj.method() +"
             AND ts.table_id   = t.table_id

It will then prompt you for values for "script_version" and "obj.method()".
This allows you to execute the query and test it without having you to
modify your code at all.

A number of different filetypes are supported, Java, Perl, PHP, VB, Vim,
SQL.  More can be added.

Included with Vim 7.3 is the SQL Complete plugin.  It uses the OMNI
completion built into Vim (CTRL-X CTRL-O) and will complete using SQL
syntax keywords.

If you have the dbext plugin installed, it will also complete, tables,
columns, stored procedures and other items.  It will dynamically pull
these from whatever database you have it connect.  See the help file :h
omni-sql-completion or :h ft_sql.txt

Tim, you also showed an example of how create a select column list by
grabbing the headers (from a different program) and running a search and
replace on it.

SQLComplete.vim has provisions for doing just that.  When on a table
name, a key stroke will replace the table name with a comma separated
list of columns from that table.

Anyway, there is a bunch more to the SQL support I have added in Vim,
but that should give people a fairly good overview.

David.


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Paul Stewart  
View profile  
 More options Sep 25 2012, 1:09 am
From: Paul Stewart <paulbrianstew...@gmail.com>
Date: Mon, 24 Sep 2012 22:08:56 -0700
Local: Tues, Sep 25 2012 1:08 am
Subject: Re: Vim for Oracle

Hi David,

Thanks for the info, I only use about 20% of the power of your plugins
I'm sure.
Thanks for maintaining them, they are a great help.

Paul Stewart

On 09/24/2012 07:18 PM, David Fishburn wrote:


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
talek  
View profile  
 More options Sep 27 2012, 6:42 am
From: talek <alexandru.t...@gmail.com>
Date: Thu, 27 Sep 2012 03:42:36 -0700 (PDT)
Local: Thurs, Sep 27 2012 6:42 am
Subject: Re: Vim for Oracle

On Monday, September 24, 2012 7:55:11 PM UTC+3, vicky b wrote:
> HI All,

>  I am  an enthusiastic vim fan but never used it much .I use sqldeveloper for db related tasks.Due you guys really feel comfortable in vim to write pl/sql and also can you guys also query the db and see the resutlset through vim.

> --
> Thanks & Regards
>  Vickyb

Hi,

You may also have a look on VoraX: https://github.com/talek/vorax


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
vicky b  
View profile  
 More options Oct 4 2012, 2:41 am
From: vicky b <vickyb2...@gmail.com>
Date: Thu, 4 Oct 2012 12:10:39 +0530
Local: Thurs, Oct 4 2012 2:40 am
Subject: Re: Vim for Oracle

do we have anything for mysql

--
*Thanks & Regards
 Vickyb

*


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Paul Stewart  
View profile  
 More options Oct 4 2012, 10:28 am
From: Paul Stewart <paulbrianstew...@gmail.com>
Date: Thu, 04 Oct 2012 07:28:45 -0700
Local: Thurs, Oct 4 2012 10:28 am
Subject: Re: Vim for Oracle

Hi Vicky,

DBext also can be connected to MySql

Paul

On 10/03/2012 11:40 PM, vicky b wrote:


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
David Fishburn  
View profile  
 More options Oct 4 2012, 1:22 pm
From: David Fishburn <dfishburn....@gmail.com>
Date: Thu, 4 Oct 2012 13:21:59 -0400
Local: Thurs, Oct 4 2012 1:21 pm
Subject: Re: Vim for Oracle

Yes everything I outlined in my email is for all databases supported by the dbext plugin. That is around 14 databases plus ODBC and Perl's DBI interface.

--
David Fishburn

On Oct 4, 2012, at 10:28 AM, Paul Stewart <paulbrianstew...@gmail.com> wrote:


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
End of messages
« Back to Discussions « Newer topic     Older topic »