[GENERAL] Functions on tables

2006-12-16 Thread Brendan Jurd
In the object-relational context, the definition of a relation is much the same as the idea of a class; the columns in a table are analogous to the attributes of a class. The names of Postgres' system catalogs reflect this correlation (pg_class, pg_attribute). Likewise, each tuple within a

Re: [GENERAL] Functions on tables

2006-12-16 Thread Tom Lane
Brendan Jurd [EMAIL PROTECTED] writes: That works fine, but wouldn't it be far more elegant if you could do this instead: CREATE TABLE person ( id SERIAL PRIMARY KEY, firstname TEXT NOT NULL, lastname TEXT NOT NULL, FUNCTION name() RETURNS text AS $$ SELECT firstname || ' ' ||

Re: [GENERAL] Functions on tables

2006-12-16 Thread Brendan Jurd
On 12/17/06, Tom Lane [EMAIL PROTECTED] wrote: 90% of the value this would have is already available with views, I think, without going outside bog-standard SQL: Views also work fine, but one of the big advantages of having table methods is that all the things your table can do are contained

Re: [GENERAL] Subcribing to this list, what`s the secret?

2006-12-16 Thread Greg Sabino Mullane
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 I seem to have a natural knack for hitting the ruts around here, which is exciting. I've tried to subscribe to the list using both yahoo and gmail email accounts and the webform always reports The email address you entered does not appear to be

Re: [GENERAL] Subcribing to this list, what's the secret?

2006-12-16 Thread Ian Harding
If you have a dot in your gmail username, take it out. Gmail ignores it and validation scripts often puke on it. Then use that email as your reply to, not some nonexistent carp. - Ian On 12/13/06, wheel [EMAIL PROTECTED] wrote: I seem to have a natural knack for hitting the ruts around here,

Re: [GENERAL] [pgsql-www] Subcribing to this list, what's the

2006-12-16 Thread Arturo Perez
In article [EMAIL PROTECTED], [EMAIL PROTECTED] (Joshua D. Drake) wrote: I also have not been able to duplicate the problem from multiple yahoo and gmail tests. I did however note that postgresql.org will not let you subscribe as [EMAIL PROTECTED] . Is .not even a valid suffix? Joshua D.

[GENERAL] Stored Procedure and Trigger they puzzle me

2006-12-16 Thread Lars Heidieker
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Hi all, I just started to write my first stored procedure in plpgsql and installed a trigger for it. The two Tables are: CREATE TABLE ltlocation ( id integer DEFAULT nextval('ltlocation_id_seq'::text) NOT NULL, name varchar(30) NOT NULL

Re: [GENERAL] [Oledb-dev] A major rewrite of the Postgres OLE DB Provider.

2006-12-16 Thread Shachar Shemesh
Jeremy Lea wrote: - Runs multiple queries (using PQexec) if you pass a command with no parameters and IID_NULL for the return record set. You should be aware that there is a security advantage to NOT being able to do that, in fact. On the plus side, it does allow servers older than 7.4

Re: [pgsql-www] [GENERAL] Subcribing to this list, what's the

2006-12-16 Thread Richard Broersma Jr
I also have not been able to duplicate the problem from multiple yahoo and gmail tests. I did however note that postgresql.org will not let you subscribe as [EMAIL PROTECTED] . Is .not even a valid suffix? I wasn't able to create an account for pg_docs mailing list the other day. I figured

Re: [GENERAL] Failed to set permision Win2k3-PG Installation Issues

2006-12-16 Thread objectmodelol
[EMAIL PROTECTED] wrote: Everytime I try to install Postgre 8.2, I get the following error: Failed to set permissions on the installed files. Please see the logfile. The thing is, I'm telling PG to use my Administrator account (the account I'm currently logged in as) and I'm pretty sure

[GENERAL] Authenticating with x509 certificate

2006-12-16 Thread Andre Lebedev
Hello. Based on the information I was able to find so far, it seems that Postgres has the capability of authenticating users through x509 certificate. But I can't find instructions on how to do it. Any help will be greatly appreciated! Regards, Andre.

Re: [GENERAL] out of memory woes

2006-12-16 Thread mwrynn
Thank you all for the replies. Overcommit is indeed disabled - the reason we disabled it is that this very same process caused the Linux oom-killer to kill processes. This was perhaps two months ago. The setting was changed to, and is currently set to: vm.overcommit_memory=2 ...All has been well

[GENERAL] strange slow performance

2006-12-16 Thread michael . guiard
Hi ! I have a strange slow performance problem depending on client computer. I have a postgresql server (8.1.3) running on an XP system (P4 3GHz, 1Go RAM). I have 3 other computers from which I make request on the database : 2 XP(named 1 2) and 1 2K. From one XP(1) and from the 2K computer, I

Re: [pgsql-www] [GENERAL] Subcribing to this list, what's the secret?

2006-12-16 Thread Tom Lane
Bruce Momjian [EMAIL PROTECTED] writes: wheel wrote: I seem to have a natural knack for hitting the ruts around here, which is exciting. I've tried to subscribe to the list using both yahoo and gmail email accounts and the webform always reports The email address you entered does not

Re: [GENERAL] Subcribing to this list, what's the secret?

2006-12-16 Thread Bruce Momjian
wheel wrote: I seem to have a natural knack for hitting the ruts around here, which is exciting. I've tried to subscribe to the list using both yahoo and gmail email accounts and the webform always reports The email address you entered does not appear to be valid. I would like to use either

Re: [GENERAL] How to check constraints before call of simple_heap_insert()?

2006-12-16 Thread Vanyel
But SPI_exec() takes string containing an SQL command :-( I need to pass previously prepared HeapTuple variable. Best regards :-) ---(end of broadcast)--- TIP 2: Don't 'kill -9' the postmaster

Re: [GENERAL] [Oledb-dev] A major rewrite of the Postgres OLE DB Provider.

2006-12-16 Thread Konstantin Izmailov
Great! I will take a look and let you know. I had rewritten the Provider about a year ago as well. However, I did not have time to clean-up most of the new bugs and decided to keep the code for myself. There is certain interest in the US to the more capable Provider. On 12/15/06, Jeremy Lea

[GENERAL] Performance of outer joins?

2006-12-16 Thread Benjamin Smith
I have a situation that can be summarized to the following: -- day in 20061215 format Create table calendar ( day integer unique not null ); Create table customers ( id serial unique not null, name varchar, address varchar, ); Create table

[GENERAL] Regular expression and Group By

2006-12-16 Thread Clodoaldo
Regular expression and Group By There is a varchar column which I need to group by an uppered substring inside '[]' like in 'xxx[substring]yyy'. All the other lines should not be changed. I can do it using a union. I would like to reduce it to a single query, but after much thought I can't. So

[GENERAL] Failed to set permision Win2k3-PG Installation Issues

2006-12-16 Thread objectmodelol
Everytime I try to install Postgre 8.2, I get the following error: Failed to set permissions on the installed files. Please see the logfile. The thing is, I'm telling PG to use my Administrator account (the account I'm currently logged in as) and I'm pretty sure it has access to everything.

Re: [GENERAL] Failed to set permision Win2k3-PG Installation Issues

2006-12-16 Thread Magnus Hagander
[EMAIL PROTECTED] wrote: [EMAIL PROTECTED] wrote: Everytime I try to install Postgre 8.2, I get the following error: Failed to set permissions on the installed files. Please see the logfile. The thing is, I'm telling PG to use my Administrator account (the account I'm currently logged in

Re: [GENERAL] Authenticating with x509 certificate

2006-12-16 Thread Magnus Hagander
Andre Lebedev wrote: Hello. Based on the information I was able to find so far, it seems that Postgres has the capability of authenticating users through x509 certificate. But I can't find instructions on how to do it. Any help will be greatly appreciated! It does not, unfortunately

Re: [GENERAL] Performance of outer joins?

2006-12-16 Thread Tom Lane
Benjamin Smith [EMAIL PROTECTED] writes: FROM customers JOIN calendars ON ( -- GIVE A CALENDAR OF POSSIBLE DAYS FOR DELIVERIES calendar.day 20061201 AND calendar.day = 20060101 ) Haven't you written a

Re: [GENERAL] Functions on tables

2006-12-16 Thread TJ O'Donnell
I wholeheartedly support the approach BJ is advocating. The notion that methods (functions) and variables (tables) can be defined together is a very useful OO approach. I too find it difficult to recall which functions belong to which tables. Of course, some of my functions are very generic and

Re: [GENERAL] out of memory woes

2006-12-16 Thread Tom Lane
[EMAIL PROTECTED] writes: Tom, below is the information you requested. Well, the table definitions look ordinary enough, but this is odd: SPI Exec: 528474160 total in 69 blocks; 309634880 free (9674592 chunks); 218839280 used Something's leaking a lot of memory within a SPI call, which means