From cf944ddb951c2cae971986aca77e8b5f1ef0656c Mon Sep 17 00:00:00 2001 From: "Dickson S. Guedes" Date: Fri, 11 Apr 2014 11:58:39 -0300 Subject: [PATCH] fixing DBListColumns' sql field Without using the `oid` field to join we can get an error: "dbext:Table not found" when the relfilenode is not equal the relation's oid. --- autoload/dbext.vim | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/autoload/dbext.vim b/autoload/dbext.vim index b920cfb..de9e509 100644 --- a/autoload/dbext.vim +++ b/autoload/dbext.vim @@ -1203,7 +1203,7 @@ function! s:DB_varToString(name) endif endfunction -"FIXME: Csinálni kell erre egy kommandot. +"FIXME: Csin�lni kell erre egy kommandot. function! s:DB_getParameters(scope) "scope must be 'b', 'g', 'd' (buffer, global, default) if (a:scope == "b") @@ -2209,9 +2209,9 @@ function! s:DB_DB2_execSql(str) " In batch files I used the following " -c close when done " -w wait until command finishes - " -i don’t spawn a new cmd window - " -t don’t change the window title - " db2cmd -c -w -i –t “db2 -s -t ; -v -f dave.sql” + " -i don�t spawn a new cmd window + " -t don�t change the window title + " db2cmd -c -w -i �t �db2 -s -t ; -v -f dave.sql� " To see command line options " cd IBM\SQLLIB\BIN " db2cmd -w -i @@ -3224,7 +3224,7 @@ function! s:DB_PGSQL_getListColumn(table_name) let table_name = s:DB_getObjectName(a:table_name) let query = "SELECT a.attname " . \ " FROM pg_class c, pg_attribute a " . - \ " WHERE c.relfilenode = a.attrelid " . + \ " WHERE c.oid = a.attrelid " . \ " AND a.attnum > 0 " . \ " AND c.relname = '" . table_name . "'"