Re: [GENERAL] JDBC Connection Errors

2011-08-24 Thread Thomas Markus
Hi, - check for open server socket: netstat -tulpen | grep postgres - try to force ipv4 for java with system property (a recent jre prefers ipv6): -Djava.net.preferIPv4Stack=true regards Thomas Am 24.08.2011 00:47, schrieb Sam Nelson: Hi list, A client is hitting an issue with JDBC

Re: [GENERAL] How to tame a gigantic (100+ lines) query in a web app?

2011-08-15 Thread Thomas Markus
Hi, use WITH queries, I use this regularly and it works fine. http://www.postgresql.org/docs/9.0/static/queries-with.html regards Thomas Am 14.08.2011 16:39, schrieb W. Matthew Wilson: I'm sure I'm not the first person to end up with a gigantic query that does lots of left joins

Re: [GENERAL] Filling null values

2011-08-08 Thread Thomas Markus
a Thomas Am 05.08.2011 18:32, schrieb jeffrey: I have a table that looks like this: homeidcity date measurement pre/post 123 san francisco 1/2/2003 1458 pre 123 san francisco NULL 1932 post 124 los angeles2/4/2005 938

Re: [GENERAL] variant column type

2011-07-26 Thread Thomas Kellerer
salah jubeh, 26.07.2011 19:02: Hello, suppose the following scenario the car speed is 240 the car has an airbag Here the first value is integer and the second value is boolean. Consider that I have this table structure feature (feature id feature name) car (car id, ) car_feature (car

Re: [GENERAL] Is there a way to 'unrestrict' drop view?

2011-07-22 Thread Thomas Pasch
again at the end of transaction (even thus Oracle DB doesn't impose that either), but drop and re-create the objects in correct order is painful. The heart of the my pain is that a program I use works like this. I would like to migrate the DB beneath it... Cheers, Thomas Am 22.07.2011 10:26

[GENERAL] Is there a way to 'unrestrict' drop view?

2011-07-21 Thread Thomas Pasch
Hello, I would like to recreate/replace a view, but there are 'dependant objects' on it. Is there a way to 'unrestrict' the dependant check in the current transaction, like it could be done with certain constraints? Kind regards, Thomas -- Sent via pgsql-general mailing list (pgsql-general

Re: [GENERAL] An example for WITH QUERY

2011-06-22 Thread Thomas Kellerer
Durumdara, 22.06.2011 12:35: Hi! I have 3 tables. I want to run a query that collect some data from them, and join into one result table. I show a little example, how to do this in another DB with script: with tmp_a as ( select id, name, sum(cost) cost from items ... ), temp_b as (

Re: [GENERAL] Problems with to_number

2011-06-10 Thread Thomas Kellerer
Chrishelring wrote on 10.06.2011 22:45: HI all, below is the view i´ve tried to create on a table. The purpose was to do some math on one of the columns (retning). The column is a double precision number. The result is that the function is not recognized (ERROR: function to_number(double

Re: [GENERAL] Recurring events

2011-06-07 Thread Thomas Guettler
On 07.06.2011 09:57, Vincent Veyron wrote: Le lundi 06 juin 2011 à 12:59 +0200, Thomas Guettler a écrit : how do you store recurring events in a database? Selecting all events in a week/month should be fast (comming from an index). My solution looks like this: Table event: Columns

Re: [GENERAL] Recurring events

2011-06-07 Thread Thomas Guettler
Hi Craig and mailing list On 07.06.2011 00:54, Craig Ringer wrote: On 06/06/2011 06:59 PM, Thomas Guettler wrote: Hi, how do you store recurring events in a database? I use two tables: one table that stores the recurring event, and another that's essentially a materialized view containing

[GENERAL] Recurring events

2011-06-06 Thread Thomas Guettler
in a time frame like above (last three year, next three years). If a recurring event gets altered, all its serialized events need to be updated. Any feedback? Thomas Güttler -- Thomas Guettler, http://www.thomas-guettler.de/ E-Mail: guettli (*) thomas-guettler + de -- Sent via pgsql-general

Re: [GENERAL] Access to postgres conversion

2011-06-02 Thread Thomas Harold
On 5/25/2011 3:42 PM, akp geek wrote: Dear all - I would like to know if any one has migrated database from MS access to Postgres . We use postgres 9.0.2 on solaris . Are there any open source tools that you have used to do this task. Can you please share your experiences ? I

Re: [GENERAL] database field list

2011-05-29 Thread Thomas Kellerer
. information_schema.columns is probably easier to look at: http://www.postgresql.org/docs/current/static/infoschema-columns.html Thomas -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-general

[GENERAL] Documentation suggestion

2011-05-11 Thread Thomas Kellerer
restriction to those listed on that page: that a file system backup will only work between the same OS and architecture and is not suited to migrate between different types of systems. Regards Thomas -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your

[GENERAL] Error in the 9.1 documentation?

2011-05-07 Thread Thomas Kellerer
[ ... ] ] Regards Thomas -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-general

Re: [GENERAL] Error in the 9.1 documentation?

2011-05-07 Thread Thomas Kellerer
the DEFAULT to be listed as a constraint...) Regards Thomas -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-general

Re: [GENERAL] histogram

2011-05-01 Thread Thomas Markus
the following? group by 1 order by 1 On Apr 30, 2011, at 5:48 PM, Thomas Markus wrote: Hi, try something like this: select trunc(random() * 10.)/10. , count(*) from generate_series(1,200) group by 1 order by 2

Re: [GENERAL] histogram

2011-04-30 Thread Thomas Markus
Hi, try something like this: select trunc(random() * 10.)/10. , count(*) from generate_series(1,200) group by 1 order by 2 regards Thomas Am 30.04.2011 18:37, schrieb Joel Reymont: I have a column of 2 million float values from 0 to 1. I would like to figure out how many

[GENERAL] Converting between varchar and float when updating

2011-04-28 Thread Thomas Larsen Wessel
How is that done? I know that the bar attribute ought to have type FLOAT, but I have to work with this legacy database. And anyway this table will rarely be updated. Sincerely, Thomas

Re: [GENERAL] Converting between varchar and float when updating

2011-04-28 Thread Thomas Larsen Wessel
specify how many decimals I want to be stored back from the result? E.g. 2 / 3 = 0. but I want to just save 0.66. 2) Can I make a criteria that it should only update on the strings that can be converted. Maybe smth. like: UPDATE foo SET bar = (bar::numeric * 2) WHERE bar::is_numeric; Thomas

Re: [GENERAL] Converting between varchar and float when updating

2011-04-28 Thread Thomas Larsen Wessel
I appreciate the advice. But in this particular case, other people have decided for me that I should not change the schema. I guess they have their reasons :) On Thu, Apr 28, 2011 at 5:40 PM, Alban Hertroys dal...@solfertje.student.utwente.nl wrote: On 28 Apr 2011, at 15:26, Thomas Larsen

[GENERAL] Re: Create Database automatacally after silent installation of postgresql. ?

2011-04-27 Thread Thomas Kellerer
hirenlad, 27.04.2011 09:47: Hiii Hey i m using postgresql 8.4. now i m install postgresql8.4 silently and it work properly, no issue during this process. Now problem is i want to create one database automatically after install postgresql 8.4. Can u plz inform me is it possible ? and if

[GENERAL] PHP and PostgreSQL 9.0, pg_connect fails to connect

2011-04-27 Thread Thomas Harold
I'm having trouble figuring out where this one is going wrong. It's a brand new install of PostgreSQL 9.0 from PGDG on a RHEL5 box, running Apache 2.2 and PHP 5.3 (from IUS). - PostgreSQL 9.0 is running and listening on the localhost. I can run pgAdmin III and connect to it over a SSH

Re: [GENERAL] PHP and PostgreSQL 9.0, pg_connect fails to connect

2011-04-27 Thread Thomas Harold
On 4/27/2011 9:16 AM, Thomas Harold wrote: - SELinux is running, but there are no denied messages in /var/log/audit/audit.log and no setroubleshooting alerts in /var/log/messages either. Well, interestingly enough it is SELinux getting in the way, but not logging anything. Temporarily

Re: [GENERAL] PHP and PostgreSQL 9.0, pg_connect fails to connect

2011-04-27 Thread Thomas Harold
On 4/27/2011 11:42 AM, Thomas Harold wrote: On 4/27/2011 9:16 AM, Thomas Harold wrote: - SELinux is running, but there are no denied messages in /var/log/audit/audit.log and no setroubleshooting alerts in /var/log/messages either. Well, interestingly enough it is SELinux getting in the way

Re: [GENERAL] PHP and PostgreSQL 9.0, pg_connect fails to connect

2011-04-27 Thread Thomas Harold
On 4/27/2011 12:24 PM, Michael Nolan wrote: On Wed, Apr 27, 2011 at 10:42 AM, Thomas Harold thomas-li...@nybeta.com mailto:thomas-li...@nybeta.com wrote: On 4/27/2011 9:16 AM, Thomas Harold wrote: - SELinux is running, but there are no denied messages in /var/log/audit

Re: [GENERAL] Table lock while adding a column and clients are logged in

2011-04-03 Thread Thomas Kellerer
perform DDL in Oracle all your currently running transactions are implicitly rolled back. Not quite. The current transaction is committed, not rolled back. http://download.oracle.com/docs/cd/B19306_01/server.102/b14200/statements_1001.htm#i2099120 Regards Thomas -- Sent via pgsql-general

Re: [GENERAL] Table lock while adding a column and clients are logged in

2011-04-03 Thread Thomas Kellerer
Alban Hertroys wrote on 03.04.2011 11:17: On 2 Apr 2011, at 12:44, Thomas Kellerer wrote: Even after a plain SELECT you should issue a COMMIT (or ROLLBACK) to end the transaction that was implicitely started with the SELECT. Sorry, but you're wrong about that. A statement that implicitly

Re: [GENERAL] Table lock while adding a column and clients are logged in

2011-04-03 Thread Thomas Kellerer
Sven Haag wrote on 03.04.2011 16:13: Original-Nachricht Datum: Sun, 03 Apr 2011 15:37:17 +0200 Von: Thomas Kellererspam_ea...@gmx.net An: pgsql-general@postgresql.org Betreff: Re: [GENERAL] Table lock while adding a column and clients are logged in Alban Hertroys wrote

Re: [GENERAL] Table lock while adding a column and clients are logged in

2011-04-02 Thread Thomas Kellerer
not be a problem if you only see IDLE sessions. Regards Thomas -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-general

Re: [GENERAL] Install issues

2011-03-22 Thread Thomas Kellerer
Alex, 22.03.2011 17:33: Using Windows 7 64 bit. Tried to install 8.4 and 9.0and it fails right near the end when it tries to create or read the conf file. If I transfer my postgres 8.4 file over the upgrade takes but the postgres service doesn't exist so no communication occurs. Is there

Re: [GENERAL] Create unique index or constraint on part of a column

2011-03-07 Thread Thomas Kellerer
help. Ruben, CREATE UNIQUE INDEX idx_cons ON invoices (EXTRACT(YEAR FROM invoice_date), innvoice_number); The only difference to a unique constraint is, that it cannot be used as the target of a foreign key constraint. Regards Thomas -- Sent via pgsql-general mailing list (pgsql-general

Re: [GENERAL] select DISTINCT not ordering the returned rows

2011-03-02 Thread Thomas Kellerer
efficient and you may never rely on any implicit ordering. If you need your rows sorted in a specific way, you have to use an ORDER BY clause. Everything else is doomed to fail someday. Regards Thomas -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your

Re: [GENERAL] why is there no TRIGGER ON SELECT ?

2011-02-22 Thread Thomas Kellerer
. The function needs to be created with SECURITY DEFINER though. The downside of this is, that this only works if the result set isn't too large. Because all rows that are returned by the function will be first buffered on the the server before they are returned to the client. Regards Thomas

Re: [GENERAL] Hide db name and user name in process list arguments

2011-02-16 Thread Thomas Kellerer
://www.postgresql.org/docs/current/static/runtime-config-statistics.html#GUC-UPDATE-PROCESS-TITLE Regards Thomas -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-general

Re: [GENERAL] Schema version control

2011-02-10 Thread Thomas Kellerer
it to Version x.y As it keeps track of all changes applied it automatically knows what to do. I can handle static data as well as stored procedure and any custom SQL. Regards Thomas -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription: http

Re: [GENERAL] Schema version control

2011-02-10 Thread Thomas Kellerer
differences? Regards Thomas -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-general

Re: [GENERAL] Schema version control

2011-02-10 Thread Thomas Kellerer
but simply let the software find them seems like a very nifty feature. I wonder how you detect renaming a table or a column? On which programming language is dbstewart based? Regards Thomas -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your

Re: [GENERAL] many schemas or many databases

2011-02-08 Thread Thomas Markus
hi, i would prefer many schemas. advantages: - one backup/restore for all (or selective) - one connection pool - simple access to all schemas regards thomas Am 08.02.2011 09:30, schrieb Szymon Guz: Hi, is there any noticeable difference between a cluster with many databases and a database

Re: [GENERAL] many schemas or many databases

2011-02-08 Thread Thomas Kellerer
and disadvantages (as described by the other posters) Regards Thomas -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-general

Re: [GENERAL] How to extract a value from a record using attnum or attname?

2011-02-04 Thread Thomas Kellerer
. If you don't really need the key = value pairs, you can simply use: payload := payload || 'values: ' || ROW(old.*); this will append everything in one operation, but not in the col=value format Regards Thomas -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes

Re: [GENERAL] Subselect AS and Where clause

2011-01-26 Thread Thomas Kellerer
the column alias: SELECT * FROM ( SELECT a, b, c, (select problem from other_table where id=a) as problem FROM mytable ) t WHERE a=1 AND problem = 3 Regards Thomas -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your

Re: [GENERAL] How can I find a schema that a table belong to?

2011-01-19 Thread Thomas Kellerer
Jerry LeVan, 19.01.2011 17:35: So I guess the question is: Given a bare table name, how can I recover the schema qualified name with whatever the current search path happens to be? SELECT table_schema FROM information_schema.tables WHERE table_name = 'your_table' ; -- Sent via

Re: [GENERAL] How can I find a schema that a table belong to?

2011-01-19 Thread Thomas Kellerer
quick with my answer. Regards Thomas -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-general

Re: [GENERAL] How can I find a schema that a table belong to?

2011-01-19 Thread Thomas Kellerer
of the schema in the search path in the order of the schemas listed in the search path. The only thing I'm unsure about is whether unnest() will always preserve the order of the array. Regards Thomas -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes

Re: [GENERAL] How to generate unique invoice numbers for each day

2011-01-16 Thread Thomas Kellerer
as far as I know. A deadlock can only happen between two different transactions (T1 locks R1, waits for R2, T2 locks R2 waits for R1) Regards Thomas -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql

Re: [GENERAL] Query to find sum of grouped counts from 2 tables

2011-01-07 Thread Thomas Kellerer
Satish Burnwal (sburnwal) wrote on 07.01.2011 11:15: I have 2 tables containing the data for same items: STORE1 - Id typeitems - 1 FOOD10 2 FOOD15 3 SOAP20 STORE2

Re: [GENERAL] OOO and postgres

2011-01-07 Thread Thomas Kellerer
;) Regards Thomas -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-general

pgloader an Indexes / was: Re: [GENERAL] CSV-bulk import and defaults

2011-01-03 Thread Thomas Schmidt
Hello, Am 03.01.11 00:06, schrieb Adrian Klaver: On Sunday 02 January 2011 2:22:14 pm Thomas Schmidt wrote: well, I'm new to postgres and this is my post on this list :-) Anyway, I've to batch-import bulk-csv data into a staging database (as part of an ETL-like pocess). The data ought

Re: [GENERAL] Need advise for database structure for non linear data.

2011-01-03 Thread Thomas Schmidt
key/value store is not the idea behind DBMS like postgres ... See: http://en.wikipedia.org/wiki/NoSQL http://en.wikipedia.org/wiki/Relational_database_management_system Thomas -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription: http

Re: [GENERAL] Need advise for database structure for non linear data.

2011-01-03 Thread Thomas Kellerer
, car and km. I don't know If I explain weel my problem. My english is not very good. That's exactly what the hstore data type supports: http://www.postgresql.org/docs/current/static/hstore.html Regards Thomas -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes

Re: [GENERAL] Need advise for database structure for non linear data.

2011-01-03 Thread Thomas Schmidt
- it all depends on the usage :-) Thomas -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-general

Re: [GENERAL] Need advise for database structure for non linear data.

2011-01-03 Thread Thomas Schmidt
Hello, Am 03.01.11 14:14, schrieb Andre Lopes: Hi, Thanks for the reply's. I was tempted to accept the Rodoslaw Smogura proposal. There will be about 100 websites to capture data on daily basis. Each website adds per day(average) 2 articles. Thomas talked about the noSQL possibility. What do

[GENERAL] CSV-bulk import and defaults

2011-01-02 Thread Thomas Schmidt
in advance, Thomas [1] http://www.postgresql.org/docs/9.0/static/sql-copy.html [2] http://pgbulkload.projects.postgresql.org/pg_bulkload.html -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-general

Re: [GENERAL] 2 versions of an entity worth distinct table?

2010-12-27 Thread Thomas Kellerer
:N relationship for that. Especially because guaranteeing that there will never be more than two in the N part is quite complicated. Regards Thomas -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql

Re: [GENERAL] Constraining overlapping date ranges

2010-12-22 Thread Thomas Kellerer
Thomas -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-general

Re: [GENERAL] A cronjob for copying a table from Oracle

2010-12-10 Thread Thomas Kellerer
if there is maybe a cleverer way to do this? And I'm not sure how to copy the Oracle's strange DATE column best into PostgreSQL, without losing precision? Oracle's DATE includes a time part as well. So simply use a timestamp in PostgreSQL and everything should be fine. Regards Thomas -- Sent via pgsql

Re: [GENERAL] A cronjob for copying a table from Oracle

2010-12-10 Thread Thomas Kellerer
Alexander Farber, 10.12.2010 12:53: On Fri, Dec 10, 2010 at 12:33 PM, Thomas Kellererspam_ea...@gmx.net wrote: And I'm not sure how to copy the Oracle's strange DATE column best into PostgreSQL, without losing precision? Oracle's DATE includes a time part as well. So simply use a timestamp

Re: [GENERAL] alter table add column - specify where the column will go?

2010-11-24 Thread Thomas Kellerer
Alexander Farber, 24.11.2010 08:49: Why do you want to do anything like that? Easier to read... login, logout I understand the easier to read part. But what do you mean with login, logout? Thomas -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your

Re: [GENERAL] alter table add column - specify where the column will go?

2010-11-24 Thread Thomas Kellerer
of this as well, but when they ask me under which circumstances this could happen, I can't think of a proper example. Does anybody have an example that would show this? Regards Thomas -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription

Re: [GENERAL] alter table add column - specify where the column will go?

2010-11-23 Thread Thomas Kellerer
Alexander Farber, 24.11.2010 08:42: is there a syntax to add a column not at the last place No, because the order of the column is irrelevant (just as there is no order on the rows in a table) Simply select them in the order you like to have. Thomas -- Sent via pgsql-general mailing list

[GENERAL] Table name with umlauts

2010-11-22 Thread Thomas Kellerer
this on the JDBC mailing list because I noticed this with Java, but it seems that it's not a JDBC problem. Could this be a Windows problem? Note: I don't really want to use such a table name, I'm just wondering if this _should_ work. Regards Thomas -- Sent via pgsql-general mailing list

Re: [GENERAL] Table name with umlauts

2010-11-22 Thread Thomas Kellerer
Tom Lane wrote on 22.11.2010 19:25: Thomas Kellererspam_ea...@gmx.net writes: I'm curious why the following is not working: postgres=# show client_encoding; client_encoding - UTF8 (1 row) postgres=# create table umlaut_test_ö (id integer); ERROR: invalid byte

Re: [GENERAL] Table name with umlauts

2010-11-22 Thread Thomas Kellerer
1252 before running psql (I tried several other encodings as well) Try set client_encoding = win1252, then. Thanks for the hint, unfortunately psql still shows the same behaviour. Regards Thomas -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your

Re: [GENERAL] newbie question - delete before insert

2010-11-20 Thread Thomas Kellerer
to send the INSERT Regards Thomas -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-general

Re: [GENERAL] More then 1600 columns?

2010-11-12 Thread Thomas Kellerer
. Thomas -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-general

Re: [GENERAL] Schema tool

2010-11-11 Thread Thomas Kellerer
if you post your experience using those tools together with PostgreSQL Actually I think it would be worthwhile documenting your experience in the PostgreSQL Wiki as well: http://wiki.postgresql.org/wiki/Community_Guide_to_PostgreSQL_GUI_Tools Regards Thomas -- Sent via pgsql-general mailing list

Re: [GENERAL] Syntax of: alter table ... add constraint ...

2010-11-08 Thread Thomas Kellerer
, but can't find the correct syntax That should work: alter table pref_users add constraint pref_users_medals_check check check (medals = 0); Thomas -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref

Re: [GENERAL] 8.4 Data Not Compatible with 9.0.1 Upgrade?

2010-11-02 Thread Thomas Kellerer
Carlos Mennens, 02.11.2010 22:37: Before I move or rename '/var/lib/postgres/data', what version of PostgreSQL should I be at? 8.4 or 9.0? Actually both, because pg_upgrade needs the binaries of the old *and* new version. -- Sent via pgsql-general mailing list

Re: [GENERAL] 8.4 Data Not Compatible with 9.0.1 Upgrade?

2010-11-02 Thread Thomas Kellerer
will not include e.g. users and roles. So if he needs to restore users and privileges from the original 8.4 installation there is no way around re-installing the 8.4 binaries. Regards Thomas -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your

[GENERAL] Temporary schemas

2010-11-01 Thread Thomas Kellerer
retrieve the schema name for temporary tables? Regards Thomas -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-general

Re: [GENERAL] Temporary schemas

2010-11-01 Thread Thomas Kellerer
Thom Brown wrote on 01.11.2010 12:33: You can use: SELECT nspname FROM pg_namespace WHERE oid = pg_my_temp_schema(); to get the name of the current temporary schema for your session. Thanks that's what I was looking for. Regards Thomas -- Sent via pgsql-general mailing list (pgsql

Re: [GENERAL] Replication

2010-11-01 Thread Thomas Kellerer
-REPLICATION Regards Thomas -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-general

Re: [GENERAL] Replication

2010-11-01 Thread Thomas Kellerer
-only. Once the failover has happened the standby is the new master and will allow read/write access. Thomas -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-general

Re: [GENERAL] Temporary schemas

2010-11-01 Thread Thomas Kellerer
Merlin Moncure wrote on 01.11.2010 21:13: On Mon, Nov 1, 2010 at 6:46 AM, Thomas Kellererspam_ea...@gmx.net wrote: Hello, I have created a temporary table using create temporary table foo ( id integer ); and noticed this was created in a schema called pg_temp_2 My question

Re: [GENERAL] Temporary schemas

2010-11-01 Thread Thomas Kellerer
Merlin Moncure wrote on 01.11.2010 23:13: On Mon, Nov 1, 2010 at 4:27 PM, Thomas Kellererspam_ea...@gmx.net wrote: The problem is, that the JDBC driver only returns information about the temp tables, if I specify that schema directly. Have you filed a bug report to jdbc yet? :-D. I thought

Re: [GENERAL] Implementing replace function

2010-10-31 Thread Thomas Kellerer
-structures.html#PLPGSQL-UPSERT-EXAMPLE Here is another solution based on triggers: http://database-programmer.blogspot.com/2009/06/approaches-to-upsert.html Regards Thomas -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription: http

[GENERAL] Re: Updates, deletes and inserts are very slow. What can I do make them bearable?

2010-10-21 Thread Thomas Kellerer
the difference? Regards Thomas -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-general

Re: [GENERAL] Generate a dynamic sequence within a query

2010-10-21 Thread Thomas Kellerer
there since 8.4 ;) Look into the windowing functions (in Oracle they are called analytical functions) http://www.postgresql.org/docs/current/static/tutorial-window.html Thomas -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription: http

Re: [GENERAL] Adding a New Column Specifically In a Table

2010-10-14 Thread Thomas Kellerer
order in your SELECT statement. Thomas -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-general

[GENERAL] IEEE 754-2008 decimal numbers

2010-10-10 Thread Thomas Munro
than NUMERIC. I was thinking I would start out by defining types DECIMAL32 and DECIMAL64 and some casts between those types and NUMERIC. (A more ambitious project for later would be defining arithmetic operators etc using compiler/hardware support). Thanks Thomas -- Sent via pgsql-general

Re: [GENERAL] How to I relocate the Postgresql data directory

2010-10-07 Thread Thomas Kellerer
is starting the service) has full access to the new directory? Regards Thomas -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-general

Re: [GENERAL] Trying to figure out why these queries are so slow

2010-10-05 Thread Thomas Guettler
Hi, just a guess: Counting is slow, since it needs to check all rows. Explained here: http://wiki.postgresql.org/wiki/Slow_Counting Thomas Güttler Tim Uckun wrote: I have two tables. Table C has about 300K records in it. Table E has about a million records in it. Today I tried to run

Re: [GENERAL] PG website testing

2010-10-04 Thread Thomas Kellerer
bit large on the live site. Regards Thomas -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-general

Re: [GENERAL] PG website testing

2010-10-04 Thread Thomas Kellerer
Thom Brown wrote on 04.10.2010 23:24: Do you see the reduction in size compared to the live site an issue? No, not at all. I just wanted to mention it, in case you are interested. I think both sizes are just fine. Regards Thomas -- Sent via pgsql-general mailing list (pgsql-general

Re: [GENERAL] PostgreSQL 9.0 (x86-64) and Windows 7 (x86-64) - Unable to install

2010-10-01 Thread Thomas Kellerer
very simple batch files to be able to easily repeat these steps Regards Thomas -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-general

[GENERAL] Documentation enhancement

2010-09-28 Thread Thomas Kellerer
because the example does use SELECT * to create the view. Regards Thomas -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-general

Re: [GENERAL] Post Install / Secure PostgreSQL

2010-09-10 Thread Thomas Kellerer
the superuser is called postgres. I don't think there is a account named root after a default installation. Regards Thomas -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-general

[GENERAL] PostgreSQL article online - PDF

2010-09-08 Thread Thomas Uzunoff
and to read it. Its available here: http://www.linuxtechnicalreview.de/Vorschau/%28show%29/Themen/Datenbanken/PostgreSQL-erweitern Bests Thomas -- Thomas Uzunoff Linux New Media AG, Putzbrunnerstr. 71, 81739 München, Germany Phone: +49 89 9934 1137 Fax: +49 89 9934 1199 tuzun...@linuxnewmedia.de

Re: [GENERAL] Jira and PostgreSQL

2010-08-30 Thread Thomas Kellerer
that is) Regards Thomas -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-general

Re: [GENERAL] Jira and PostgreSQL

2010-08-30 Thread Thomas Kellerer
with it, so it's definitely not 24*7 We have about 250 users, but of course not all of them are active all the time Regards Thomas -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-general

Re: [GENERAL] Too much logging

2010-08-27 Thread Thomas Kellerer
= default log_min_error_statement = error log_min_duration_statement = 3000 log_statement = 'all' Pretty much everything else log related is commented out.. What am I doing wrong? Thanks! log_statement = 'all' should be log_statement = 'none' Regards Thomas -- Sent via pgsql-general mailing

Re: [GENERAL] Wrong ORDER BY on a numeric value result

2010-08-15 Thread Thomas Kellerer
! That was the point. The real question is: what did you try to accomplish with the UPPER() on a numeric column? Regards Thomas -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-general

Re: [GENERAL] MySQL versus Postgres

2010-08-09 Thread Thomas Kellerer
to learn Hibernate Regards Thomas -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-general

Re: [GENERAL] Using AND in query

2010-08-08 Thread Thomas Kellerer
Alban Hertroys wrote on 08.08.2010 10:46: On 7 Aug 2010, at 23:18, Thomas Kellerer wrote: Or as an alternative: SELECT tid, purchase_date FROM orders WHERE item in ('Laptop', 'Desktop') GROUP BY tid, purchase_date HAVING count(*) = 2 This one is incorrect, it will also find people who

Re: [GENERAL] Using AND in query

2010-08-07 Thread Thomas Kellerer
ON l.tid = d.tid AND l.purchase_date = d.purchase_date AND d.item = 'Desktop' WHERE l.item = 'Laptop' Or as an alternative: SELECT tid, purchase_date FROM orders WHERE item in ('Laptop', 'Desktop') GROUP BY tid, purchase_date HAVING count(*) = 2 Regards Thomas -- Sent via pgsql-general

Re: [GENERAL] MySQL versus Postgres

2010-08-06 Thread Thomas Kellerer
. Learn what youare doing (or dealing with) is a strategy that applies to everything you do. Do take the time to read the manuals - including the MySQL manual (because just plunging into MySQL simply doesn't work either) It'll make you a lot more proficient in the long run. Regards Thomas -- Sent

Re: [GENERAL] Comparison of Oracle and PostgreSQL full text search

2010-07-28 Thread Thomas Kellerer
)? Regards Thomas -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-general

Re: [GENERAL] pg_dump and --inserts / --column-inserts

2010-07-17 Thread Thomas Kellerer
Craig Ringer wrote on 17.07.2010 03:13: On 17/07/10 04:26, Thomas Kellerer wrote: Hmm. For years I have been advocating to always use fully qualified column lists in INSERTs (for clarity and stability) And now I learn it's slower when I do so :( If you're not doing hundreds of thousands

Re: [GENERAL] pg_dump and --inserts / --column-inserts

2010-07-17 Thread Thomas Kellerer
Tom Lane wrote on 17.07.2010 16:36: Thomas Kellererspam_ea...@gmx.net writes: I'm till a bit surprised that parsing the statement _with_ a column list is mesurably slower than withou a column list. Well, nobody's offered any actual *numbers* here. It's clear that parsing the column list

<    3   4   5   6   7   8   9   10   11   12   >