Re: [SQL] Error on dynamic code.

2005-07-15 Thread John DeSoi
On Jul 14, 2005, at 3:46 AM, Mark J Camilleri wrote: The funny thing is that the documentation I read about SELECT INTO and RECORD types give the following example, amongst others: See the section below that on EXECUTE: The results from SELECT commands are discarded by EXECUTE, and SEL

Re: [SQL] problem (bug?) with "in (subquery)"

2005-07-15 Thread Tom Lane
Luca Pireddu <[EMAIL PROTECTED]> writes: > On July 15, 2005 08:58, Tom Lane wrote: >> Ah-hah: this one is the fault of create_unique_path, which quoth > In any case, it looks like Tom has already found the problem :-) Thanks guys! On closer analysis, the test in create_unique_path is almost but

Re: [SQL] problem (bug?) with "in (subquery)"

2005-07-15 Thread Luca Pireddu
On July 15, 2005 07:34, Michael Fuhr wrote: > On Thu, Jul 14, 2005 at 01:34:21AM -0600, Luca Pireddu wrote: > > I have the following query that isn't behaving like I would expect: Thanks for creating the reduced test case Michael. My apologies for not doing it myself. > > > > select * from str

Re: [SQL] problem (bug?) with "in (subquery)"

2005-07-15 Thread Tom Lane
Michael Fuhr <[EMAIL PROTECTED]> writes: > I've been reverse-engineering and simplifying this. Here's something > that I think is close: > CREATE TABLE foo (id integer); > CREATE TABLE bar (id1 integer, id2 integer); > INSERT INTO foo VALUES (1); > INSERT INTO bar VALUES (1, 1); > INSERT INTO b

[SQL] Postgres for Fedora Core 2 OS ****************

2005-07-15 Thread Dinesh Pandey
From where can I download?   “Postgres 8.x” + required packages and “installation instruction” of Postgres for Fedora Core 2 OS. Thanks Dinesh Pandey  

Re: [SQL] problem (bug?) with "in (subquery)"

2005-07-15 Thread Michael Fuhr
On Fri, Jul 15, 2005 at 09:59:27AM -0400, Tom Lane wrote: > Luca Pireddu <[EMAIL PROTECTED]> writes: > > So, am I wrong in expecting each strain record to appear only once in the > > result set? Or is there something wrong with PostgreSQL? > > Could we see a self-contained example (table definit

Re: [SQL] problem (bug?) with "in (subquery)"

2005-07-15 Thread Tom Lane
Luca Pireddu <[EMAIL PROTECTED]> writes: > So, am I wrong in expecting each strain record to appear only once in the > result set? Or is there something wrong with PostgreSQL? Could we see a self-contained example (table definitions and sample data as a SQL script)? I don't really have time to

Re: [SQL] problem (bug?) with "in (subquery)"

2005-07-15 Thread Michael Fuhr
On Thu, Jul 14, 2005 at 01:34:21AM -0600, Luca Pireddu wrote: > I have the following query that isn't behaving like I would expect: > > select * from strains s where s.id in (select strain_id from pathway_strains); Any reason the subquery isn't doing "SELECT DISTINCT strain_id"? > I would expect

Re: [SQL] How to obtain the list of data table name only

2005-07-15 Thread Neil Dugan
On Thu, 2005-07-14 at 15:24 -0700, [EMAIL PROTECTED] wrote: > Hi, > > I am wondering if anyone can tell me how I can obtain only the list of > data table in postgresql without function and other ancillary tables. I > hope that I can add a tag that can filter only data table. > > I am using the fo

Re: [SQL] Yearly Archival System Using PostgreSQL

2005-07-15 Thread Michael Fuhr
On Thu, Jul 14, 2005 at 02:24:17AM -0700, Vivek wrote: > I am developing a database system using PostgreSQL in which I should be > able to delete redundant records once a year (Time specified by the > user). THe redundant records should be inserted into the archive table > which is part of the sam

Re: [SQL] difference between all RDBMSs

2005-07-15 Thread Kenneth Gonsalves
On Friday 15 Jul 2005 2:18 pm, Richard Huxton wrote: > Sorry if this isn't as much help as you'd like, but you'll need to > give more detail if you want a more detailed answer. looks like he needs the details for a project/report -- regards kg http://www.livejournal.com/users/lawgon tally ho! h

Re: [SQL] How to obtain the list of data table name only

2005-07-15 Thread Richard Huxton
[EMAIL PROTECTED] wrote: Hi, I am wondering if anyone can tell me how I can obtain only the list of data table in postgresql without function and other ancillary tables. I hope that I can add a tag that can filter only data table. I am using the following SQL Statement: "SELECT TABLE_NAME, TAB

Re: [SQL] Help With complex join

2005-07-15 Thread Richard Huxton
[EMAIL PROTECTED] wrote: Hi all, got a question as how to approach a somewhat complicated join query. The deal is I have three tables called attorney, lawOffice, and law_office_employment. The attorney and lawOffice tables hold attorney and lawOffice information respectively (obviously). The l

Re: [SQL] difference between all RDBMSs

2005-07-15 Thread Richard Huxton
Dhanashree wrote: hello sir, i m an engineering student and i m looking out for differrences between oracle v/s sybase v/s sql v/s plsql v/s mysql with respect to the following points Well, "sql" is a query language, and "plsql" is a procedural language, so I'm guessing you mean MS-Sql Server