Re: [GENERAL] Which schema I am woking on??

2003-07-11 Thread Alvaro Herrera
On Fri, Jul 11, 2003 at 10:45:57AM +0800, Harry Yau wrote: > Firstly, is there anyway to find out which Schema I am working on, so I > could query the pg_tables with a specified schemaname?? > I have tried to select current_schema. However, it always return > "public" to me. Actually, the temp sc

Re: [GENERAL] PG crash on simple query, story continues

2003-07-11 Thread Maksim Likharev
So following modification seems to fixed all PG (7.3/7.3.3)crashes on Solaris ( NON C LOCALE ) selfuncs.c line 2356: I changed: xfrmsize = strlen(val) + 32;/*arbitrary pad value here...*/ to xfrmsize = strxfrm(NULL, val, 0) + 32; so basically instead of wild guess of transformed string size

[GENERAL] Which schema I am woking on??

2003-07-11 Thread Harry Yau
Hi all, I am writing a pl/psql function with a temp table right now. It creates the temp table inside. Whenever I call this function in a session for the first time, it creates a shema, namely pg_temp_number, automatically and it creates the temp table within the schema. I've tried to add a check

Re: [GENERAL] Am I using the SERIAL type properly?

2003-07-11 Thread Jeffrey Melloy
drop table A; create table A ( id SERIAL PRIMARY KEY, foo int default 5, bar int default 10 ); insert into A (id, foo, bar) values (1, 1, 1); insert into A (id, foo, bar) values (2, 2, 2); insert into A (id, foo, bar) values (3, 3, 3); insert into A (id, foo, bar) v

Re: [GENERAL] Am I using the SERIAL type properly?

2003-07-11 Thread Martijn van Oosterhout
On Thu, Jul 10, 2003 at 12:10:31AM -0700, Chad N. Tindel wrote: > I tried doing numerous searches to see if this has been discussed before, > but I couldn't find anything. If it has, perhaps my question can be > answered simply by a pointer to a previous thread. > > I'm trying to convert a progra

Re: [GENERAL] PostgreSQL, Cygwin - setting locales

2003-07-11 Thread Jason Tishler
Ivan, On Thu, Jul 10, 2003 at 08:06:41AM +0200, [EMAIL PROTECTED] wrote: > anybody help with my problem, please? Cygwin does not fully support locales. Hence, Cygwin PostgreSQL in turn does not either. Jason -- PGP/GPG Key: http://www.tishler.net/jason/pubkey.asc or key servers Fingerprint: 7

[GENERAL] PL/pgSQL CASE Support

2003-07-11 Thread Raymond
Is the PL/SQL CASE control structure supported in the Postgres implmentation? ---(end of broadcast)--- TIP 1: subscribe and unsubscribe commands go to [EMAIL PROTECTED]

Re: [GENERAL] This works in 7.2.1, not in 7.3.2

2003-07-11 Thread Tom Lane
"Frank Millman" <[EMAIL PROTECTED]> writes: > The following works in 7.2.1 - > 1. select count(*) from SysUsersCompanies where UserRowId =3D 3 ; > 2. select substring('NY',(select count(*) from SysUsersCompanies where User= > RowId =3D 3)+1,1) ; > The first select returns either 1 or 0 > The seco

Re: [GENERAL] [CYGWIN] pg_restore very slow

2003-07-11 Thread Michael Adler
First, I'd recommend sticking to Debian. You are probably already aware of the differences. If you are stuck in WinWorld, try using the "-h `hostname`" option. It was consistently faster for me. On Mon, 7 Jul 2003, Laurent Michel wrote: > Date: Mon, 7 Jul 2003 17:10:15 +0200 > From: Laurent Mic

[GENERAL] Am I using the SERIAL type properly?

2003-07-11 Thread Chad N. Tindel
I tried doing numerous searches to see if this has been discussed before, but I couldn't find anything. If it has, perhaps my question can be answered simply by a pointer to a previous thread. I'm trying to convert a program from mysql to postgres (yes, I've seen the light). I'm running into som

Re: [GENERAL] This works in 7.2.1, not in 7.3.2

2003-07-11 Thread Stephan Szabo
On Thu, 10 Jul 2003, Frank Millman wrote: > Hi all > > The following works in 7.2.1 - > > 1. select count(*) from SysUsersCompanies where UserRowId = 3 ; > 2. select substring('NY',(select count(*) from SysUsersCompanies where UserRowId = > 3)+1,1) ; > > The first select returns either 1 or 0 > T

Re: [GENERAL] corrupt data

2003-07-11 Thread Alvaro Herrera
On Fri, Jul 11, 2003 at 09:32:12AM +0200, Zeno R.R. Davatz wrote: > Out of some reason our data of our postgresql database has been corrupted. When we > try to connect to the database we get: > > psql: ERROR: _mdfd_getrelnfd: cannot open relation pg_type_oid_index: > No such file or directory >

[GENERAL] PostgreSQL, Cygwin - setting locales

2003-07-11 Thread icaplovic
Hello, I have a some problem with using PostgreSQL on Cygwin. I download and setup Cygwin instalation of PSQL. When I try initdb with options -E LATIN2 --locale=sk. I cannot start PostgreSQL server in log I read a message cannot locate sk. In directory \usr\share\locale I see directory

[GENERAL] This works in 7.2.1, not in 7.3.2

2003-07-11 Thread Frank Millman
Hi all   The following works in 7.2.1 -   1. select count(*) from SysUsersCompanies where UserRowId = 3 ; 2. select substring('NY',(select count(*) from SysUsersCompanies where UserRowId = 3)+1,1) ;   The first select returns either 1 or 0 The second one uses the result in a more complex _expre

[GENERAL] corrupt data

2003-07-11 Thread Zeno R.R. Davatz
Hi List Out of some reason our data of our postgresql database has been corrupted. When we try to connect to the database we get: psql: ERROR: _mdfd_getrelnfd: cannot open relation pg_type_oid_index: No such file or directory REINDEX does not work. We get the same error. pgfsck gives us: wro