[GENERAL] Automatically updating a timestamp upon UPDATE query?

2001-01-12 Thread Ed Loehr
How do you most easily create a timestamp column that updates to the current time on every UPDATE statement? I know you can use triggers, but I thought there was a default value that did this for you. 'current' does not seem appropriate, nor have I made it work (see below for my example).

Re: [GENERAL] exit status 26

2001-01-12 Thread Tom Lane
Dan Moschuk <[EMAIL PROTECTED]> writes: > So it is getting a virtual timer from somewhere. A grep of the backend > directory revealed no setitimer() occurances, so I can confirm that it > isn't postmaster doing it. And if the shells environment is unlimited, > which doesn't leave very many culp

Re: [GENERAL] exit status 26

2001-01-12 Thread Dan Moschuk
| > Signal 26 on FreeBSD is SIGVTARLM. | | We don't ever set a virtual timer alarm, either. Is it possible that | you are running the postmaster with a ulimit-style limit on total | process runtime? No, I've tested this and postmaster is being started in an unlimited enviornment. The code

[GENERAL] Re: mnogosearch -- pgsql seem so slow, please help me find out why

2001-01-12 Thread Tom Lane
"Thomas T. Thai" <[EMAIL PROTECTED]> writes: > On Fri, 12 Jan 2001, Tom Lane wrote: >> "Thomas T. Thai" <[EMAIL PROTECTED]> writes: 'select * from url' from psql monitor took 59 seconds. >> >> How big is the table? Your EXPLAIN mentions 99256 rows, but I can't >> tell if that stat is up-to-

[GENERAL] Re: mnogosearch -- pgsql seem so slow, please help me find out why

2001-01-12 Thread Thomas T. Thai
On Fri, 12 Jan 2001, Tom Lane wrote: > "Thomas T. Thai" <[EMAIL PROTECTED]> writes: > > 'select * from url' from psql monitor took 59 seconds. > > How big is the table? Your EXPLAIN mentions 99256 rows, but I can't > tell if that stat is up-to-date or not. it is 99256. i don't think it's that

[GENERAL] on statement triggers

2001-01-12 Thread Peter Gubis
  hi, when will be implemented 'on statement' triggers ?   --  Peter Gubis Ericsson Business Systems Slovakia Ltd. Stará Vajnorská 90  Tel.:   +421 7 49499 254 SK 831 04 Bratislava Slovakia E-Mail  :   [EMAIL PROTECTED]  

Re: [GENERAL] mnogosearch -- pgsql seem so slow, please help me find out why

2001-01-12 Thread Tom Lane
"Thomas T. Thai" <[EMAIL PROTECTED]> writes: > 'select * from url' from psql monitor took 59 seconds. How big is the table? Your EXPLAIN mentions 99256 rows, but I can't tell if that stat is up-to-date or not. A select like that is going to be pretty much all data transfer: read the disk blocks

RE: [GENERAL] Correlated subquery/update

2001-01-12 Thread Nick Fankhauser
Sounds like the answer is to upgrade to v7+ Much thanks to Tom Lane and Len Morgan for the helpful responses! -Nick >update one set b = (select d from two where one.a = two.c);

[GENERAL] mnogosearch -- pgsql seem so slow, please help me find out why

2001-01-12 Thread Thomas T. Thai
pgsql 7.1-current, mnogosearch-3.1.8, netbsd/alpha-1.5.1-current, dec alpha 500, 1G ram, uw-scsi i'm trying to find out why postgres is the bottle neck in my searches with mnogosearch. i've tried both the search.c and php version of search and they both took up to 50 seconds for a one word search

[GENERAL] postgres replication

2001-01-12 Thread Peter Gubis
hello, i need help with online database replication. is there any daemon, whitch can do that ? right now i'm writting one based on triggers, but it will be great if somebody has some link for something like that, witch is already made . i found erserver.com , but it's not complete right now and i

Re: [GENERAL] Correlated subquery/update

2001-01-12 Thread Tom Lane
"Nick Fankhauser" <[EMAIL PROTECTED]> writes: > In essence, I want to match up the records where one.a=two.c and update > one.b with the value in two.d . In Oracle, I would use this statement: > update one set b = (select d from two where one.a = two.c); > in psql, I get a syntax error when I do t

[GENERAL] Correlated subquery/update

2001-01-12 Thread Nick Fankhauser
Hi all- I'm trying to match up two tables based on a primary key, and then copy (update) a field in the second table to match a field in the first. Hard to explain well... so here's an example: select * from one; a | b - 1 | null 2 | null select * from two; c | d - 1 | o

Re: [GENERAL] union query

2001-01-12 Thread Tom Lane
"Tamsin" <[EMAIL PROTECTED]> writes: >select 'other' union select description from address; >ERROR: Unable to transform varchar to unknown > Each UNION | EXCEPT | INTERSECT clause must have compatible target > types The behavior in 7.0.* and before (as far back as I recall) has b

Re: [GENERAL] MacOS X

2001-01-12 Thread Tom Lane
Sander Tichelaar <[EMAIL PROTECTED]> writes: > Is a port of PostgreSQL planned for MacOS X? We have reports from Apple that PG current sources work on OS X current sources, ie, 7.1 release should work on OS X release. IIRC, PG will not work on the existing "public beta" of OS X. See past traffi

[GENERAL] union query

2001-01-12 Thread Tamsin
Just spent an hour getting nowhere, til I discovered this (description is a varchar field): select description from address union select 'other'; fine but... select 'other' union select description from address; ERROR: Unable to transform varchar to unknown Each UNION | EXCEP

[GENERAL] Re: xml middleware

2001-01-12 Thread Adam Lang
I don't recall names, but it came up in the interfaces list. Like I said, if anyone is actually working on it, I do not know, we just chatted and threw out some ideas and said it would be really neat. :) Adam Lang Systems Engineer Rutgers Casualty Insurance Company http://www.rutgersinsurance.co

Re: [GENERAL] Removing the row limit

2001-01-12 Thread Adam Lang
Beta 3 of 7.1 has been released. You won't have to worry about the row limit and you'll also help check for any possible bugs. :) Adam Lang Systems Engineer Rutgers Casualty Insurance Company http://www.rutgersinsurance.com - Original Message - From: "Mike Cannon-Brookes" <[EMAIL PROTECT

Re: [GENERAL] xml middleware

2001-01-12 Thread Adam Lang
I'd assume you'd need to make your own up (or whoever develops it.) I'd say develop a schema that can be accessible from the internet so the XML can be interpreted. Adam Lang Systems Engineer Rutgers Casualty Insurance Company http://www.rutgersinsurance.com - Original Message - From: "F

[GENERAL] MacOS X

2001-01-12 Thread Sander Tichelaar
Hi, I'm sorry if this is yet another instance of an ever repeating question. I searched the archives and FAQs but couldn't find an answer. Is a port of PostgreSQL planned for MacOS X? It is based on BSD, so it shouldn't be that hard... We are looking for a cross-platform database to use for our

[GENERAL] Problems with connecting to Postgre

2001-01-12 Thread Uro Gruber
Hi! I use postgre 7.0.3 on FreeBSD 4.1.1 I started my postgres with -i, because i want to connect over internet. I tested this in localnet. When i connect with PHP it takes very long time. If i refresh again i get results immediately. If i refresh my page after some seconds it takes long time to

Re: [GENERAL] timestamp update field across multiple tables

2001-01-12 Thread Oliver Elphick
Rajit Singh wrote: >I have five tables which are really intended to be one big table, but has be >en adapted to comply with Postgres's (irritating) 8kb tuple size limit ( >ver 7.0.3). > >I have 'modtime' fields in each of these tables which record the last time a > record w

[GENERAL] timestamp update field across multiple tables

2001-01-12 Thread Rajit Singh
Dear List, Thanks for those who helped me with my last question. I have a slightly related question: I have five tables which are really intended to be one big table, but has been adapted to comply with Postgres's (irritating) 8kb tuple size limit (ver 7.0.3). I have 'modtime' fields in each

[GENERAL] Joins and field types

2001-01-12 Thread Zak McGregor
Hi all What sort of performance penalty on joins using varchar(n) vs. int fields can I expect if both tables are fairly small (ie unlikely to have more than 2 rows each)? Is there a good reference or two on these sorts of questions? thanks a lot Ciao Zak McGregor

[GENERAL] Re: PostgreSQL Client Program

2001-01-12 Thread Anthony E . Greene
On Mon, 08 Jan 2001 19:50:00 Jreniz wrote: >I´ve a Linux RH6.2 machine with PostgreSQL 6.5.3, this works fine with >PHP module, but, I need create a GTK client program that sends queries >to database. > >I saw the manuals and documentation but, i don´t know how compile these >programs, and the man