[SQL] Trigger on select :-(

2010-03-11 Thread Ray Madigan
What I want is to have a trigger on select, but since I have searched the archives I know that is not possible. I also read that view rules is the technology is whats available. Having never used views before I can't seem to get my mind to figure out what I need to do to solve my problem. I

[SQL] Except without elimination of non-distinct rows

2008-02-04 Thread Ray Madigan
Is there any way to use except that won't remove the non-distinct rows from the left side of the query? ---(end of broadcast)--- TIP 2: Don't 'kill -9' the postmaster

Re: [SQL] Except without elimination of non-distinct rows

2008-02-04 Thread Ray Madigan
I tried using EXCEPT ALL but it seems to only remove one row when there is more then one matching row? Thanks Ray Madigan -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Behalf Of Tom Lane Sent: Monday, February 04, 2008 6:20 PM To: Ray Madigan Cc: Pgsql-Sql Subject

[SQL] Select in From clause

2007-11-09 Thread Ray Madigan
I have never seen this done before, but it seems like it is supposed to work from reading the manual. I want to be able to get a table name from another table and use it in the from clause of a select. Something like SELECT * FROM (SELECT name FROM bar WHERE conditions) AS b WHERE b.condition =

Re: [SQL] Computed table name in function

2007-10-10 Thread Ray Madigan
I thought that the documentation said I couldn't use EXECUTE on a SELECT INTO? -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Behalf Of Scott Marlowe Sent: Wednesday, October 10, 2007 11:10 AM To: Ray Madigan Cc: Pgsql-Sql Subject: Re: [SQL] Computed table name

[SQL] Computed table name in function

2007-10-10 Thread Ray Madigan
I have a problem that I don't know where to look to understand the problem. I have a function that I first select to get a table name followed by another select into on that table name. If someone could tell me where to look to solve this problem I would appreciate it. It is something like

[SQL] Rules with sequence columns

2007-03-28 Thread Ray Madigan
I have the following situation that I would appreciate your input on: I have a table with a column that I use to uniquely identify its rows. The table also has a rule on insert that stores the row identifier into another table for reference at some other point. The table is defined as CREATE

[SQL] LinkedList

2006-04-26 Thread Ray Madigan
Ray Madigan ---(end of broadcast)--- TIP 2: Don't 'kill -9' the postmaster

Re: [SQL] LinkedList

2006-04-26 Thread Ray Madigan
willing Thanks -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Behalf Of Scott Marlowe Sent: Wednesday, April 26, 2006 8:59 AM To: Ray Madigan Cc: pgsql-sql@postgresql.org Subject: Re: [SQL] LinkedList On Wed, 2006-04-26 at 11:09, Ray Madigan wrote: I have a table that I

[SQL] LOOP?

2005-02-17 Thread Ray Madigan
I am writing a trigger to inspect a row of a temporary table to determine if the row has any null columns, I will return as soon as I find a null column. I ran across this in the manual and It seems like I could use The FOR-IN-EXECUTE statement is another way to iterate over rows: [label] FOR

[SQL] Count Columns

2005-02-16 Thread Ray Madigan
I haven't done very many complex queries in sql, and maybe Im thinking about my problem wrong but: Is there a way to count the number of null or not null columns in a row and have an output column that has that count as the value? I want to create a ranking of the row based upon the number of not