3
3
*
4
4
* Copyright (c) 2000-2007, PostgreSQL Global Development Group
5
5
*
6
- * $PostgreSQL: pgsql/src/bin/psql/tab-complete.c,v 1.164 2007/04/26 22:25:56 neilc Exp $
6
+ * $PostgreSQL: pgsql/src/bin/psql/tab-complete.c,v 1.165 2007/06/13 23:59:47 neilc Exp $
7
7
*/
8
8
9
9
/*----------------------------------------------------------------------
@@ -397,7 +397,7 @@ static const SchemaQuery Query_for_list_of_views = {
397
397
"SELECT pg_catalog.quote_ident(c1.relname) "\
398
398
" FROM pg_catalog.pg_class c1, pg_catalog.pg_class c2, pg_catalog.pg_index i"\
399
399
" WHERE c1.oid=i.indrelid and i.indexrelid=c2.oid"\
400
- " and (%d = length('%s'))"\
400
+ " and (%d = pg_catalog. length('%s'))"\
401
401
" and pg_catalog.quote_ident(c2.relname)='%s'"\
402
402
" and pg_catalog.pg_table_is_visible(c2.oid)"
403
403
@@ -406,15 +406,15 @@ static const SchemaQuery Query_for_list_of_views = {
406
406
"SELECT pg_catalog.quote_ident(c2.relname) "\
407
407
" FROM pg_catalog.pg_class c1, pg_catalog.pg_class c2, pg_catalog.pg_index i"\
408
408
" WHERE c1.oid=i.indrelid and i.indexrelid=c2.oid"\
409
- " and (%d = length('%s'))"\
409
+ " and (%d = pg_catalog. length('%s'))"\
410
410
" and pg_catalog.quote_ident(c1.relname)='%s'"\
411
411
" and pg_catalog.pg_table_is_visible(c2.oid)"
412
412
413
413
/* the silly-looking length condition is just to eat up the current word */
414
414
#define Query_for_list_of_tables_for_trigger \
415
415
"SELECT pg_catalog.quote_ident(relname) "\
416
416
" FROM pg_catalog.pg_class"\
417
- " WHERE (%d = length('%s'))"\
417
+ " WHERE (%d = pg_catalog. length('%s'))"\
418
418
" AND oid IN "\
419
419
" (SELECT tgrelid FROM pg_catalog.pg_trigger "\
420
420
" WHERE pg_catalog.quote_ident(tgname)='%s')"
0 commit comments