[GENERAL] Re: [HACKERS] SPI example does not work for 7.1beta4

2001-03-23 Thread Limin Liu
> > --- > >SPI_connect(); > >SPI_exec("create temp table tbl_tmp (n int);",0); > >SPI_exec("insert into tbl_tmp values (1);",0); > >SPI_finish(); > > --- > > after InitPostgres and before setsigjmp(). > > I doubt this will work correctly without a transaction around it ... Thanks

[GENERAL] Re: Can I use SPI in postgres.c

2001-03-21 Thread Limin Liu
Currently I am using 7.1beta4, but I just learned that these SPI code works fine in 7.02. We can issue "select * from tbl_tmp" and psql will return the correct information in the temp table! > I need to create a temp table for each db connection. So, I add the > dollowing code into postgres.c >

[HACKERS] Can I use SPI in postgres.c

2001-03-21 Thread Limin Liu
Helper, I need to create a temp table for each db connection. So, I add the dollowing code into postgres.c SPI_connect(); SPI_exec("create temp table tbl_tmp (n int);",0); SPI_exec("insert into tbl_tmp values (1);",0); SPI_finish(); right after -

Re: [GENERAL] display temp table structure?

2001-03-13 Thread Limin Liu
Bruce Momjian wrote: > > Tom Lane wrote: > > > > > > Bruce Momjian <[EMAIL PROTECTED]> writes: > > > > There is no user-visible mapping, though the number is the process id. > > > > You could use that. I think you can get the backend process id somehow, > > > > but I am not sure how. Anyone? I

Re: [GENERAL] display temp table structure?

2001-03-12 Thread Limin Liu
Bruce Momjian wrote: > [ Charset ISO-8859-1 unsupported, converting... ] > > > > I was trying to check my temp table structure, but failed (7.1 beta4) > > and I found the following item in the TODO list (without '-'). > > > > * allow psql \d to show temporary table structure > > > > Is there any

[GENERAL] how to find DB names in Postgres 7.1?

2001-03-06 Thread Limin Liu
In Postgres 7.1, ${PGDATA}/base contains directories named by numbers!! They used to be database names. If a user created a db, can the db admin know what is that db name (without sending any query to db server)? I believe there must have some kind of mapping table exist. Can anyone tell me

[GENERAL] Re: Daily Digest V1 #377

2001-03-05 Thread Limin Liu
> > I'm writing a very robust validation script in perl for database entry. One > of the things I'd like to do is check how large a field is, and make sure > that the entry into that field isn't too big. Problem is, for variable length > fields, DBD::Pg returns a -1 size, using the pg_size attribu

[GENERAL] download postgres 7.0.3

2000-11-20 Thread Limin Liu
Hi, I read several mails here regarding to 7.0.3, but I can find 7.0.2 from www.postgresql.org.  Can anyone please tell me where I can get 7.0.3? Thanx --  Limin Liu  

[GENERAL] (download ANSI SQL benchmark?) Re: Postgres article

2000-11-20 Thread Limin Liu
enchmark I have read so far that Postgres out perform MySQL. Thanx in advance. > > Did someone read bout this? > > http://www.angelfire.com/nv/aldev/pgsql/GreatBridge.html >   --  Limin Liu  

[GENERAL] database name.

2000-11-07 Thread Limin Liu
possible? Thanks in advance. Limin Liu