[GENERAL] Function TOP

2001-01-02 Thread Tomasz Janyska
Is there in Postgres such a function like TOP in MSSQL?

Re: [GENERAL] How to drop a NOT NULL column constraint?

2001-01-02 Thread Ed Loehr
Tom Lane wrote: > > Ed Loehr <[EMAIL PROTECTED]> writes: > > I need to alter the table to get rid of the "NOT NULL" constraint on the > > 'id' column. Can I do this using ALTER TABLE? > > There isn't an ALTER TABLE variant for this at the moment, but you can > do it the hard way: reach in and c

Re: [GENERAL] How to drop a NOT NULL column constraint?

2001-01-02 Thread Tom Lane
Ed Loehr <[EMAIL PROTECTED]> writes: > I need to alter the table to get rid of the "NOT NULL" constraint on the > 'id' column. Can I do this using ALTER TABLE? There isn't an ALTER TABLE variant for this at the moment, but you can do it the hard way: reach in and change the attnotnull boolean in

Re: [GENERAL] How to drop a NOT NULL column constraint?

2001-01-02 Thread Brett W. McCoy
On Tue, 2 Jan 2001, Ed Loehr wrote: > I have a table created like so: > > CREATE TABLE foo ( > id INTEGER NOT NULL > ... > ); > > I need to alter the table to get rid of the "NOT NULL" constraint on the > 'id' column. Can I do this using ALTER TABLE? Or d

[GENERAL] How to drop a NOT NULL column constraint?

2001-01-02 Thread Ed Loehr
I have a table created like so: CREATE TABLE foo ( id INTEGER NOT NULL ... ); I need to alter the table to get rid of the "NOT NULL" constraint on the 'id' column. Can I do this using ALTER TABLE? Or do I have to dump/recreate/reload the table?

Re: [GENERAL] System Tables Questions

2001-01-02 Thread Peter Eisentraut
Colin Taylor writes: > Hi, > Anyone know where I can get a decent description of the system tables and > their contents? > Thanks in advance, > Colin http://www.postgresql.org/devel-corner/docs/postgres/catalogs.htm -- Peter Eisentraut [EMAIL PROTECTED] http://yi.org/peter-e/

Re: [GENERAL] Possible "off-topic"

2001-01-02 Thread Tom Lane
Tulio Oliveira <[EMAIL PROTECTED]> writes: > 1) The arrows-keys (up,down,left,right) don't work in PSQL prompt. > Instead this keys, it returns ^[[A , ^[[B , ^[[C , ^[[D > And when I access the notebook from other machine via TELNET, the > BACKSPACE don't works too. (^H isntead). Sounds li

[GENERAL] Re: pg_dump/psql < db.out issue

2001-01-02 Thread Tom Lane
Michael Davis <[EMAIL PROTECTED]> writes: > I have several tables with text fields that contain single quotes ('). > Pg_dump exports these tables and the single quotes (') okay. Psql, > however, will not import the data into the tables because of the single > quote (') in one of the columns i

Re: [GENERAL] Two tables refenceing each other's columns

2001-01-02 Thread Stephan Szabo
You can use ALTER TABLE ADD CONSTRAINT to add foreign key constraints after table creation. On Tue, 2 Jan 2001, GH wrote: > > Is something like the following allowed (or is not a Bad Idea)? > > table1 > -+- > id1 |serial primary key > col2 |int referen

Re: [GENERAL] Re: Possible "off-topic"

2001-01-02 Thread Zachary Beane
On Tue, Jan 02, 2001 at 05:01:56PM +0100, François LODIER wrote: > Hi all, > > happy new year , > > sorry to disturb you but I am trying to create a trigger but it doesn't seems to be >working. > > I have got a function called halloworld that takes one argument and I am trying to >trigger it

[GENERAL] Re: Possible "off-topic"

2001-01-02 Thread François LODIER
Hi all, happy new year , sorry to disturb you but I am trying to create a trigger but it doesn't seems to be working. I have got a function called halloworld that takes one argument and I am trying to trigger it : so I write somethig like : CREATE TRIGGER helloworld_trigger AFTER INSERT    

[GENERAL] Possible "off-topic"

2001-01-02 Thread Tulio Oliveira
Hi, ALL I just install: Postgres 7.0.2 Apache 1.3.14 PHP4 Over RedHat Linux 6.2 On a Notebook Toshiba Satellite Pro It's working fine, but I have 2 problems. 1) The arrows-keys (up,down,left,right) don't work in PSQL prompt. Instead this keys, it returns ^[[A , ^[[B , ^[[C , ^[[D And w

Re: [GENERAL] How passwords can be crypted in postgres?

2001-01-02 Thread Karl DeBisschop
Jens Hartwig wrote: > > > [...] > > Isn't this just as bad? If you store the encrypted password, that doesn't > > help you in the slightest in this case, because if you can breach the list > > of encrypted passwords, you still know what you need to send as the > > "password" from the front end t

[GENERAL] Hierarchical queries in pgsql

2001-01-02 Thread Betsemes
Do pgsql features an equivalent to Oracle's hierarchical queries? Those that can be done with "start with" and "connect to" clauses. Thanks. Efrain Caro Try Ematic.com Where everyone can buy, or sell, new or used, products online in safe and secure manner. Accept credit cards on your web si

Re: [GENERAL] How passwords can be crypted in postgres?

2001-01-02 Thread Gordan Bobic
> > [...] > > Isn't this just as bad? If you store the encrypted password, that doesn't > > help you in the slightest in this case, because if you can breach the list > > of encrypted passwords, you still know what you need to send as the > > "password" from the front end to let you into the data

[GENERAL] System Tables Questions

2001-01-02 Thread Colin Taylor
Hi, Anyone know where I can get a decent description of the system tables and their contents? Thanks in advance, Colin

Re: [GENERAL] How passwords can be crypted in postgres?

2001-01-02 Thread Jens Hartwig
> [...] > Isn't this just as bad? If you store the encrypted password, that doesn't > help you in the slightest in this case, because if you can breach the list > of encrypted passwords, you still know what you need to send as the > "password" from the front end to let you into the database. > [

Re: SV: [GENERAL] MySQL and PostgreSQL speed compare

2001-01-02 Thread Gordan Bobic
> Advanced tools do have advanced safety features, but are sold "ready > for most use", not "safely disabled until you read all of the manuals > so you can figure out how to make it work decently". I agree that > reading the manuals is an important part of learning a new tool, > but it shouldn't b

Re: [GENERAL] How passwords can be crypted in postgres?

2001-01-02 Thread Gordan Bobic
> I usually just run 'crypt()' on the clear text before storing it to the > backend ... Isn't this just as bad? If you store the encrypted password, that doesn't help you in the slightest in this case, because if you can breach the list of encrypted passwords, you still know what you need to send

Re: SV: [GENERAL] MySQL and PostgreSQL speed compare

2001-01-02 Thread Gordan Bobic
[tuning analogies snipped] > > Likewise with self-proclaimed computer tuners. You have no idea how much I agree with you there. > > I really don't understand why people expect computers to do everything > > for them, the burden of using tools properly belongs to the user. > > I of course agree i

Re: [GENERAL] MySQL and PostgreSQL speed compare

2001-01-02 Thread Gordan Bobic
> >>>Actually, if he ran Postgresql with WAL enabled, fsync shouldn't > >>>make much of a difference. > > WAL seems to be enabled by default. What WAL is good for I do not know. But > if I start PostgreSQL without the -S I see a lot of info about WAL this and > WAL that. You seem to be too hung u

[GENERAL] pg_dump/psql < db.out issue

2001-01-02 Thread Michael Davis
I have several tables with text fields that contain single quotes ('). Pg_dump exports these tables and the single quotes (') okay. Psql, however, will not import the data into the tables because of the single quote (') in one of the columns in one of the records. Any idea how to work aroun

Re: [GENERAL] Performance Tuning, hardware-wise

2001-01-02 Thread Gordan Bobic
> As for the drive in that machine, doing inserts on it was SLOW. Slower > even than on our beater development machine. I suppose I could have fiddled > with hdparm to increase the disk I/O, but that would have been a temporary > fix at best. Our CGI applications were eating lots of CPU time,