Re: [PATCHES] [HACKERS] allowed user/db variables

2003-07-20 Thread Bruce Momjian

Oh, I see now.  My new 'make check' script doesn't install a new version
in my standard path but just in the regression database.

I see what you see now.

---

Tom Lane wrote:
 Bruce Momjian [EMAIL PROTECTED] writes:
  Tom Lane wrote:
  No, it's a DONE.
 
  I just tried this with CVS:
   
  test= show datestyle;
 DateStyle
  ---
   ISO with US (NonEuropean) conventions
  (1 row)
 
 Uh, when was your last update?  I get
 
 regression=# show datestyle;
  DateStyle 
 ---
  ISO, US
 (1 row)
 
 regression=# 
 
   regards, tom lane
 

-- 
  Bruce Momjian|  http://candle.pha.pa.us
  [EMAIL PROTECTED]   |  (610) 359-1001
  +  If your life is a hard drive, |  13 Roberts Road
  +  Christ can be your backup.|  Newtown Square, Pennsylvania 19073

---(end of broadcast)---
TIP 8: explain analyze is your friend


Re: [PATCHES] timestamp date_trunc('quarter',...)

2003-07-20 Thread Bruce Momjian

Your patch has been added to the PostgreSQL unapplied patches list at:

http://momjian.postgresql.org/cgi-bin/pgpatches

I will try to apply it within the next 48 hours.

---


Böjthe Zoltán wrote:
 I corecting date_trunc('quarter',...) and friends because orig version 
 doing '2003-07-30' - '2003-04-01', '2003-11-30' -'2003-07-01'

 --- src/backend/utils/adt/timestamp.c
 +++ src/backend/utils/adt/timestamp.c
 @@ -2412,7 +2412,7 @@
   case DTK_YEAR:
   tm-tm_mon = 1;
   case DTK_QUARTER:
 - tm-tm_mon = (3 * (tm-tm_mon / 4)) + 1;
 + tm-tm_mon = (3 * ((tm-tm_mon - 1) / 3)) + 1;
   case DTK_MONTH:
   tm-tm_mday = 1;
   case DTK_DAY:
 @@ -2505,7 +2505,7 @@
   case DTK_YEAR:
   tm-tm_mon = 1;
   case DTK_QUARTER:
 - tm-tm_mon = (3 * (tm-tm_mon / 4)) + 1;
 + tm-tm_mon = (3 * ((tm-tm_mon - 1) / 3)) + 1;
   case DTK_MONTH:
   tm-tm_mday = 1;
   case DTK_DAY:
 @@ -2598,7 +2598,7 @@
   case DTK_YEAR:
   tm-tm_mon = 0;
   case DTK_QUARTER:
 - tm-tm_mon = (3 * (tm-tm_mon / 4));
 + tm-tm_mon = (3 * (tm-tm_mon / 3));
   case DTK_MONTH:
   tm-tm_mday = 0;
   case DTK_DAY:
 @@ -3175,7 +3175,7 @@
   break;
  
   case DTK_QUARTER:
 - result = (tm-tm_mon / 4) + 1;
 + result = (tm-tm_mon / 3) + 1;
   break;
  
   case DTK_YEAR:

 
 ---(end of broadcast)---
 TIP 1: subscribe and unsubscribe commands go to [EMAIL PROTECTED]

-- 
  Bruce Momjian|  http://candle.pha.pa.us
  [EMAIL PROTECTED]   |  (610) 359-1001
  +  If your life is a hard drive, |  13 Roberts Road
  +  Christ can be your backup.|  Newtown Square, Pennsylvania 19073

---(end of broadcast)---
TIP 4: Don't 'kill -9' the postmaster


[PATCHES] Eliminate information_schema from oid2name listing

2003-07-20 Thread Kenji Sugita
This small patch eliminates relations in information_schema from oid2name
listing.
Index: oid2name.c
===
RCS file: /projects/cvsroot/pgsql-server/contrib/oid2name/oid2name.c,v
retrieving revision 1.18
diff -u -r1.18 oid2name.c
--- oid2name.c  14 May 2003 03:25:56 -  1.18
+++ oid2name.c  21 Jul 2003 03:49:57 -
@@ -355,7 +355,10 @@
if (systables == 1)
snprintf(todo, 1024, select relfilenode,relname from pg_class order 
by relname);
else
-   snprintf(todo, 1024, select relfilenode,relname from pg_class where 
relname not like 'pg_%%' order by relname);
+   snprintf(todo, 1024, select relfilenode,relname 
+from pg_class c, pg_namespace n 
+where c.relnamespace = n.oid and n.nspname != 
'information_schema' and c.relname not like 'pg_%%' 
+order by c.relname);
 
sql_exec(conn, todo, 0);
 }

---(end of broadcast)---
TIP 8: explain analyze is your friend


Re: [PATCHES] Eliminate information_schema from oid2name listing

2003-07-20 Thread Tom Lane
Kenji Sugita [EMAIL PROTECTED] writes:
 This small patch eliminates relations in information_schema from oid2name
 listing.

Seems like it'd be a good idea to eliminate views and composite types as
well.

regards, tom lane

---(end of broadcast)---
TIP 7: don't forget to increase your free space map settings


Re: [PATCHES] Eliminate information_schema from oid2name listing

2003-07-20 Thread Kenji Sugita
From: Tom Lane [EMAIL PROTECTED]
Subject: Re: [PATCHES] Eliminate information_schema from oid2name listing 
Date: Mon, 21 Jul 2003 00:32:46 -0400

;;; Kenji Sugita [EMAIL PROTECTED] writes:
;;;  This small patch eliminates relations in information_schema from oid2name
;;;  listing.
;;; 
;;; Seems like it'd be a good idea to eliminate views and composite types as
;;; well.

It can be displayed by option -x. Information_schema displayed by oid2name -d
databasename is noisy.


Kenji Sugita  

---(end of broadcast)---
TIP 4: Don't 'kill -9' the postmaster