Re: [GENERAL] [ADMIN] Priorities for users or queries?

2007-02-10 Thread Joshua D. Drake
Benjamin Arai wrote: > Just to clarify, there is no way to throttle specific queries or users > in PostgreSQL? That is correct. Sincerely, Joshua D. Drake > > Benjamin > > Joshua D. Drake wrote: >> Benjamin Arai wrote: >> >>> Hi, >>> >>> Is there a way to give priorities to queries or use

Re: [GENERAL] Priorities for users or queries?

2007-02-10 Thread Adam Rich
There is a function pg_backend_pid() that will return the PID for the current session. You could call this from your updating app to get a pid to feed to the NICE command. -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Benjamin Arai Sent: Saturday, Feb

Re: [GENERAL] [ADMIN] Priorities for users or queries?

2007-02-10 Thread Benjamin Arai
Just to clarify, there is no way to throttle specific queries or users in PostgreSQL? Benjamin Joshua D. Drake wrote: Benjamin Arai wrote: Hi, Is there a way to give priorities to queries or users? Something similar to NICE in Linux. My goal is to give the updating (backend) application

Re: [GENERAL] does anyone have a tool to convert SP'sT-SQL to Postgres

2007-02-10 Thread Denis Lussier
Pavel is doing nice work on Orafce & the EnterpriseDB PG Community Fund is now sponsoring him to do more. On 2/10/07, Joshua D. Drake <[EMAIL PROTECTED]> wrote: Denis Lussier wrote: > Oracle provides a free tool for converting TSQL into PL/SQL. > > You can then use the PL/SQL on an EnterpriseDB

Re: [GENERAL] does anyone have a tool to convert SP'sT-SQL to Postgres

2007-02-10 Thread Joshua D. Drake
Denis Lussier wrote: > Oracle provides a free tool for converting TSQL into PL/SQL. > > You can then use the PL/SQL on an EnterpriseDB database, if this doesn't > work for ya... PL/SQL is quite a bit closer to PLpgSQL than TSQL is so > you'll be well on your way. There is also the open source O

Re: [GENERAL] does anyone have a tool to convert SP'sT-SQL to Postgres

2007-02-10 Thread Denis Lussier
Oracle provides a free tool for converting TSQL into PL/SQL. You can then use the PL/SQL on an EnterpriseDB database, if this doesn't work for ya... PL/SQL is quite a bit closer to PLpgSQL than TSQL is so you'll be well on your way. --Luss http://www.enterprisedb.com On 2/9/07, johnf <[EMAIL

[GENERAL] win32 install fail

2007-02-10 Thread marcelo Cortez
oblfolks I can't install postgresql on winxp profesional Installer fail ( creating cluster) Installer with out cluster . ok creating cluster on hand .fail initdb The files belonging to this database system will be owned by user "postgres". This user must also own the server process. T

Re: [GENERAL] [ADMIN] Priorities for users or queries?

2007-02-10 Thread Joshua D. Drake
Benjamin Arai wrote: > Hi, > > Is there a way to give priorities to queries or users? Something > similar to NICE in Linux. My goal is to give the updating (backend) > application a very low priority and give the web application a high > priority to avoid disturbing the user experience.\ Nope :

[GENERAL] Problem indexing large database with large number of inserts (partial index building?)

2007-02-10 Thread Benjamin Arai
Hi, I have a database (200GB+), I need to upload about 10GB of data each week. There are no deletions. My problem is that inserting takes a very long time due to the indexes. I can speedup inserting the data insertion if I drop the indexes but then I am left with the problem of rebuilding

[GENERAL] Priorities for users or queries?

2007-02-10 Thread Benjamin Arai
Hi, Is there a way to give priorities to queries or users? Something similar to NICE in Linux. My goal is to give the updating (backend) application a very low priority and give the web application a high priority to avoid disturbing the user experience. Thanks in advance! Benjamin

Re: [GENERAL] Password Policy

2007-02-10 Thread Ezequias Rodrigues da Rocha
Hi list (my first post), Is there any password polity that postgresql implement ? It is possible to put a set all no administrators passwords to = '123456' from times and times ? Has anyone implement a dinamic password autentication (the password changes according the date/month etc of a day )

Re: [GENERAL] drop table if exists mytable;

2007-02-10 Thread Anton Melser
> I need to do a "drop table if exists" type thing. I realise I can Install 8.2 or use this function, posted by David Fetter: Thanks for your answers... so this really was something that was missing (I think it a little rich to come out with a "are you using a version without this" when it has

[GENERAL] MOVE cursor in plpgsql?

2007-02-10 Thread Webb Sprague
Hi all, Is there a way to move a cursor in plpgsql in the same way as in regular sql? The function below would like to move the cursor back to the start each time the cursor runs out of rows, creating pairs of integers that are randomly put together. The "motivation" for this is to randomly ass

Re: [GENERAL] Adding TEXT columns tanks performance?

2007-02-10 Thread Tom Lane
Arturo Perez <[EMAIL PROTECTED]> writes: > Saturday I changed a table to add a varchar(24) and a TEXT column. You didn't actually say which of these tables you changed? > I'm not very good at reading these but it looks like sort memory might > be too low? The runtime seems to be entirely in the

Re: [GENERAL] Trouble w/plperl sproc on red hat 9

2007-02-10 Thread Tom Lane
Kenneth Downs <[EMAIL PROTECTED]> writes: > Eventually we pinned it down to a failed load of a sproc written in > plperl. He says he's running a Red Hat 9 system with Postgres 8.1 and > perl is 5.8.5. When he takes the plperl sproc and attempts to load it > through pgsql he gets: > SQL ER

Re: [GENERAL] Trouble w/plperl sproc on red hat 9

2007-02-10 Thread Douglas McNaught
Kenneth Downs <[EMAIL PROTECTED]> writes: > Not sure if this one is fixable, but a user of my GPL'd package was > unable to run our install. > > Eventually we pinned it down to a failed load of a sproc written in > plperl. He says he's running a Red Hat 9 system with Postgres 8.1 and > perl is 5.

Re: [GENERAL] drop table if exists mytable;

2007-02-10 Thread Andreas Kretschmer
Anton Melser <[EMAIL PROTECTED]> schrieb: > Hi, > I need to do a "drop table if exists" type thing. I realise I can Install 8.2 or use this function, posted by David Fetter: -- -- posted by David Fetter -- CREATE OR REPLACE FUNCTION drop_table(TEXT) RETURNS VOID STRICT LANGUAGE plpgsql AS $$ BEG

Re: [GENERAL] drop table if exists mytable;

2007-02-10 Thread Gurjeet Singh
I am not sure if I understood the problem correctly!!! Can you not use the standard command "DROP TABLE IF EXISTS table1" that PG provides? http://www.postgresql.org/docs/8.2/interactive/sql-droptable.html Or is it that you are on a version of PG where "IF EXISTS" syntax is not available? Rega

[GENERAL] drop table if exists mytable;

2007-02-10 Thread Anton Melser
Hi, I need to do a "drop table if exists" type thing. I realise I can easily look in pg_tables, but for testing (if), don't I need to use a procedural language? In which case, I will need to install it if it doesn't exist - but I don't know how to test to see whether a language exists without usin

Re: [GENERAL] Adding TEXT columns tanks performance?

2007-02-10 Thread Arturo Perez
On Feb 9, 2007, at 11:43 AM, Merlin Moncure wrote: On 2/8/07, Arturo Perez <[EMAIL PROTECTED]> wrote: Hi all, Saturday I changed a table to add a varchar(24) and a TEXT column. It's used for some reporting purposes (small potatoe stuff really) and the TEXT column remains mostly empty. Howeve

[GENERAL] Trouble w/plperl sproc on red hat 9

2007-02-10 Thread Kenneth Downs
Not sure if this one is fixable, but a user of my GPL'd package was unable to run our install. Eventually we pinned it down to a failed load of a sproc written in plperl. He says he's running a Red Hat 9 system with Postgres 8.1 and perl is 5.8.5. When he takes the plperl sproc and attempts

Re: [GENERAL] bytea characteristics

2007-02-10 Thread Peter Eisentraut
jws wrote: > Do the images take up a certain percentage more space due to the on- > disk format when stored this way? Bytes are pretty much stored just as bytes, with four bytes of overhead for the length field. Larger values (> 2kB) are stored out of line, so there really shouldn't be much con