Re: [PATCHES] pg_id.c windows fix

2003-10-04 Thread Stephan Szabo
On Sun, 5 Oct 2003, Bruce Momjian wrote: > > Can you tell me what Win32 compile environment can't handle a sizeof() > as a function parameter? > > ! GetUserName(pw->pw_name, sizeof(pw->pw_name)-1); > > Does casting to DWORD help? > > ! GetUserName(pw->pw_name, &pwname_size); It looks

Re: [PATCHES] pg_id.c windows fix

2003-10-04 Thread Bruce Momjian
Can you tell me what Win32 compile environment can't handle a sizeof() as a function parameter? ! GetUserName(pw->pw_name, sizeof(pw->pw_name)-1); Does casting to DWORD help? --- Andrew Dunstan wrote: > Here's a patc

Re: [PATCHES] fix log_min_duration_statement logic error

2003-10-04 Thread Bruce Momjian
Tom Lane wrote: > Bruce Momjian <[EMAIL PROTECTED]> writes: > > I think they fit pretty nicely on one line, and lot of folks want that > > information. I realize it looks like bloatware because it duplicates > > some existing functionality, but I think it is a combination of duration > > and state

Re: [PATCHES] fix log_min_duration_statement logic error

2003-10-04 Thread Tom Lane
Bruce Momjian <[EMAIL PROTECTED]> writes: > I think they fit pretty nicely on one line, and lot of folks want that > information. I realize it looks like bloatware because it duplicates > some existing functionality, but I think it is a combination of duration > and statement output that can't be

Re: [PATCHES] fix log_min_duration_statement logic error

2003-10-04 Thread Bruce Momjian
Tom Lane wrote: > Bruce Momjian <[EMAIL PROTECTED]> writes: > > The reason we > > needed to do it this way was so we could print the statement _after_ it > > completes so we could include the duration. > > The behavior I had in mind was to dump the statement at the end of the > query if (a) the du

Re: [PATCHES] fix log_min_duration_statement logic error

2003-10-04 Thread Tom Lane
Bruce Momjian <[EMAIL PROTECTED]> writes: > The reason we > needed to do it this way was so we could print the statement _after_ it > completes so we could include the duration. The behavior I had in mind was to dump the statement at the end of the query if (a) the duration needs to be printed and

Re: [PATCHES] fix log_min_duration_statement logic error

2003-10-04 Thread Bruce Momjian
OK, here is a patch that uses the zero value to print all queries: LOG: duration: 0.310 msecs, select 1; LOG: duration: 8.108 msecs, select * from pg_class; LOG: duration: 1.992 msecs, select * from pg_class, pg_proc limit 1; LOG: duration: 2.797 msecs, select * from pg_class, pg_proc

Re: [PATCHES] fix log_min_duration_statement logic error

2003-10-04 Thread Bruce Momjian
Tom Lane wrote: > Bruce Momjian <[EMAIL PROTECTED]> writes: > > Tom Lane wrote: > >> I would prefer to see the log entries look like > >> > >> LOG: query: select * from pg_class; > >> LOG: duration: nn.nnn msec > > > The problem with two lines is that another log message could get between > > the

Re: [PATCHES] more spanish updates

2003-10-04 Thread Peter Eisentraut
Alvaro Herrera writes: > Did you get this one? > http://archives.postgresql.org/pgsql-patches/2003-10/msg9.php > (backend translation) No, but I've installed it from the archives now. -- Peter Eisentraut [EMAIL PROTECTED] ---(end of broadcast)

Re: [PATCHES] fix log_min_duration_statement logic error

2003-10-04 Thread Tom Lane
Bruce Momjian <[EMAIL PROTECTED]> writes: > Tom Lane wrote: >> I would prefer to see the log entries look like >> >> LOG: query: select * from pg_class; >> LOG: duration: nn.nnn msec > The problem with two lines is that another log message could get between > them. That was true already with log

Re: [PATCHES] fix log_min_duration_statement logic error

2003-10-04 Thread Bruce Momjian
Tom Lane wrote: > Peter Eisentraut <[EMAIL PROTECTED]> writes: > > Bruce Momjian writes: > >> LOG: duration(secs): 0.000257 > >> LOG: duration(secs): 0.000754 > >> LOG: duration(secs): 0.008115 select * from pg_class; > > > I think the units typically go after the number. > > In any case, this

Re: [PATCHES] more spanish updates

2003-10-04 Thread Alvaro Herrera
On Sat, Oct 04, 2003 at 08:13:23PM +0200, Peter Eisentraut wrote: > Alvaro Herrera writes: > > > Attached are psql and libpq spanish PO files, 100% translated. > > Installed. Thanks. Did you get this one? http://archives.postgresql.org/pgsql-patches/2003-10/msg9.php (backend translation)

Re: [PATCHES] fix log_min_duration_statement logic error

2003-10-04 Thread Tom Lane
Peter Eisentraut <[EMAIL PROTECTED]> writes: > Bruce Momjian writes: >> LOG: duration(secs): 0.000257 >> LOG: duration(secs): 0.000754 >> LOG: duration(secs): 0.008115 select * from pg_class; > I think the units typically go after the number. In any case, this is unnecessarily incompatible wit

Re: [PATCHES] more spanish updates

2003-10-04 Thread Peter Eisentraut
Alvaro Herrera writes: > Attached are psql and libpq spanish PO files, 100% translated. Installed. -- Peter Eisentraut [EMAIL PROTECTED] ---(end of broadcast)--- TIP 9: the planner will ignore your desire to choose an index scan if your

Re: [PATCHES] fix log_min_duration_statement logic error

2003-10-04 Thread Peter Eisentraut
Bruce Momjian writes: > Thanks Peter. Patch attached. I added "(secs)" to the ouput: > > LOG: duration(secs): 0.000257 > LOG: duration(secs): 0.000754 > LOG: duration(secs): 0.008115 select * from pg_class; I think the units typically go after the number. -- Peter Eisentr

[PATCHES] pg_id.c windows fix

2003-10-04 Thread Andrew Dunstan
Here's a patch for pg_id.c that lets it compile cleanly and run on Windows.   cheers   andrew   Index: src/bin/pg_id/pg_id.c===RCS file: /projects/cvsroot/pgsql-server/src/bin/pg_id/pg_id.c,vretrieving revision 1.22.2.1diff -c -