[SQL] Use of Setof Record Dynamically

2003-12-24 Thread A E
Hi,   I am attempting to use Setof Record dynamically. I am developing an application where I will not know what the end-user is trying to work with from a web front end. Thus I will not know before hand the structure of the table I am trying to pull the record from.   My Code:   CREATE FUNCTION r

[SQL] stored queries

2003-12-24 Thread Joop
Hello everyone, I'm just about to start on the reporting part of a PostgreSQL / PHP application. I think it would be a good idea to create a table in my db in which I can store queries, something like this: create table stored_queries ( id bigint primary key, name varchar, description varch

Re: [SQL] how do i get differences between rows

2003-12-24 Thread teknokrat
Bruno Wolff III wrote: On Thu, Dec 18, 2003 at 12:21:35 +, teknokrat <[EMAIL PROTECTED]> wrote: I am after an sql query that can give the differnces between consecutive timestamp values in the resultset. anyone know how to do this? I think you can do something like the following (untested)

[SQL] MD5 encrypt

2003-12-24 Thread alvaro
Hi, Is there any function on postgresql that allows to encrypt data when making an Insert statment? Tks a lot, Alvaro ---(end of broadcast)--- TIP 2: you can get off all lists at once with the unregister command (send "unregister YourEmailA

[SQL] not in vs not exists - vastly diferent performance

2003-12-24 Thread Iain
(B (B (BHi All, (B  (BI found this interesting and thought I'd (Boffer it up for comment. (B  (BI have the following delete: (B  (Bdelete from tableB where id not in (select (Bid from tableA); (B  (BThere are about 100,000 rows in table A, (Band about 500,000 in table B. id is ind

Re: [SQL] Distributed keys

2003-12-24 Thread Chris Travers
It seems to me that if the inheritance/fireign key behavior was changed so that foreign key constraints could exist within the entire inheritance tree, this problem would be solved. According to previous posts, the behavior will probably change at some point but does not appear to be a priority at