Re: [SQL] transposing data for a view

2001-10-31 Thread Aasmund Midttun Godal
I think this might do the trick... CREATE FUNCTION hori_view() RETURNS BOOLEAN AS ' DECLARE view_select TEXT; view_from TEXT; view_where TEXT; column_name TEXT; last_column_name TEXT; g_row generalized_table%ROWTYPE; BEGIN

Re: [SQL] Primary key with oid + name : error, which solution ?

2001-10-31 Thread Stephan Szabo
On Wed, 31 Oct 2001, [ISO-8859-1] Stéphane Chomat wrote: > Yes, name is an internal type. The problem is in the type of the table > repertory. If it is not > possible to use this syntaxe, i will take the type char. I just try the > new possibility of postgressql. Yeah. I think the problem is th

Re: [SQL] Primary key with oid + name : error, which solution ?

2001-10-31 Thread Stéphane Chomat
Yes, name is an internal type. The problem is in the type of the table repertory. If it is not possible to use this syntaxe, i will take the type char. I just try the new possibility of postgressql. thanks. steph. Le mercredi 31 octobre 2001, à 11:08 , Stephan Szabo a écrit : On Wed, 31 Oct 2001

Re: [SQL] Primary key with oid + name : error, which solution ?

2001-10-31 Thread Stephan Szabo
On Wed, 31 Oct 2001, [ISO-8859-1] Stéphane Chomat wrote: > I create two table repertory and person. And i have an error : > > > CREATE TABLE repertory (name_rep name, attribut text[], PRIMARY > KEY(name_rep)); > > CREATE TABLE person (nam_rep repertory, name_pers text, url text, eadr > text, te

Re: [SQL] transposing data for a view

2001-10-31 Thread Josh Berkus
Jeremy, First, to do a pivot table, you have to be using Postgres 7.1.x. 7.0.x will not do it. So upgrade now. > I want to create a flattened out view that looks like the following: > > scanid | A_volume | B_volume | C_volume > > 134.4

Re: [SQL] Primary key with oid + name : error, which solution ?

2001-10-31 Thread Roberto Mello
On Wed, Oct 31, 2001 at 10:06:22AM +0100, St?phane Chomat wrote: > I create two table repertory and person. And i have an error : > > > CREATE TABLE repertory (name_rep name, attribut text[], PRIMARY > KEY(name_rep)); > > CREATE TABLE person (nam_rep repertory, name_pers text, url text, > e

Re: [SQL] transposing data for a view

2001-10-31 Thread James Orr
- Original Message - From: "H Jeremy Bockholt" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Tuesday, October 30, 2001 7:36 PM Subject: [SQL] transposing data for a view > I have a generalized table: > > scanid | region | volume > - > 1 A 34.4

Re: [SQL] postgresql error

2001-10-31 Thread sharmad
Sir, I m getting an error that say pg_ReadData and also after which then database connection is lost/disconnected . Can anybody tell me more about this error ? My problem is that i have a databasee with huge no. of records but if i go to take query/backup of the database the pg_Readdata error

[SQL] transposing data for a view

2001-10-31 Thread H Jeremy Bockholt
I have a generalized table: scanid | region | volume - 1 A 34.4 1 B 32.1 1 C 29.1 2 A 32.4 2 B 33.2 2 C 35.6 . . . I want to create a flattened out view that looks like the following: sca

[SQL] Primary key with oid + name : error, which solution ?

2001-10-31 Thread Stéphane Chomat
I create two table repertory and person. And i have an error : > CREATE TABLE repertory (name_rep name, attribut text[], PRIMARY KEY(name_rep)); > CREATE TABLE person (nam_rep repertory, name_pers text, url text, eadr text, tel text, attribut text[], PRIMARY KEY(name_pers,nam_rep)); NOTICE: CRE