Re: [GENERAL] How to add xml data to table

2011-10-09 Thread Andrus
There was dblink contrib module which reads data from other PostgreSql database using tcp/ip connection. Maybe there is similar for http/asmx data retrieval ? About periodic call of stored procedure, is there cron contrib for PosgreSql ? Or can we force some code call on autofacuum or after

Re: [GENERAL] How to restore a SQL-ASCII encoded database to a new UTF-8 db?

2011-10-09 Thread skmanji
You can do this by converting the characters in raw dump file directly. iconv -f 8859_1 -t UTF-8 backup.db.psql backup.db.psql.utf8 Then convert the line in backup.db.psql.utf8 from: SET client_encoding = 'SQL_ASCII'; to: SET client_encoding = 'UTF8'; -- View this message in context:

Re: [GENERAL] How to add xml data to table

2011-10-09 Thread Andrus
Thank you. I got also the following code: First import the XML into a staging table: CREATE TABLE xml_import ( xml_data xml ) with product_list as ( select unnest(xpath('/soap12:Envelope/soap12:Body/pl:GetProductListResponse/pl:GetProductListResult/pl:ProductList/pl:Product', xml_data,

Re: [GENERAL] [9.2devel] why it doesn't do index scan only?

2011-10-09 Thread Thom Brown
On 9 October 2011 04:35, Pavel Stehule pavel.steh...@gmail.com wrote: 2011/10/8 Thom Brown t...@linux.com: On 8 October 2011 21:13, Pavel Stehule pavel.steh...@gmail.com wrote: 2011/10/8 Thom Brown t...@linux.com: On 8 October 2011 19:47, Pavel Stehule pavel.steh...@gmail.com wrote: I did it.

Re: [GENERAL] [9.2devel] why it doesn't do index scan only?

2011-10-09 Thread Pavel Stehule
2011/10/9 Thom Brown t...@linux.com: On 9 October 2011 04:35, Pavel Stehule pavel.steh...@gmail.com wrote: 2011/10/8 Thom Brown t...@linux.com: On 8 October 2011 21:13, Pavel Stehule pavel.steh...@gmail.com wrote: 2011/10/8 Thom Brown t...@linux.com: On 8 October 2011 19:47, Pavel Stehule

Re: [GENERAL] [9.2devel] why it doesn't do index scan only?

2011-10-09 Thread Thom Brown
On 9 October 2011 11:51, Pavel Stehule pavel.steh...@gmail.com wrote: 2011/10/9 Thom Brown t...@linux.com: On 9 October 2011 04:35, Pavel Stehule pavel.steh...@gmail.com wrote: 2011/10/8 Thom Brown t...@linux.com: On 8 October 2011 21:13, Pavel Stehule pavel.steh...@gmail.com wrote: 2011/10/8 

Re: [GENERAL] [9.2devel] why it doesn't do index scan only?

2011-10-09 Thread Tom Lane
Pavel Stehule pavel.steh...@gmail.com writes: 2011/10/9 Thom Brown t...@linux.com: On 9 October 2011 04:35, Pavel Stehule pavel.steh...@gmail.com wrote: It has a sense - index only scan  it is faster (and significantly faster) on wider tables - or tables with strings where TOAST is not

Re: [GENERAL] [9.2devel] why it doesn't do index scan only?

2011-10-09 Thread Pavel Stehule
2011/10/9 Tom Lane t...@sss.pgh.pa.us: Pavel Stehule pavel.steh...@gmail.com writes: 2011/10/9 Thom Brown t...@linux.com: On 9 October 2011 04:35, Pavel Stehule pavel.steh...@gmail.com wrote: It has a sense - index only scan  it is faster (and significantly faster) on wider tables - or tables

Re: [GENERAL] [9.2devel] why it doesn't do index scan only?

2011-10-09 Thread Pavel Stehule
2011/10/9 Pavel Stehule pavel.steh...@gmail.com: 2011/10/9 Tom Lane t...@sss.pgh.pa.us: Pavel Stehule pavel.steh...@gmail.com writes: 2011/10/9 Thom Brown t...@linux.com: On 9 October 2011 04:35, Pavel Stehule pavel.steh...@gmail.com wrote: It has a sense - index only scan  it is faster (and

[GENERAL] how to save a bytea value into a file?

2011-10-09 Thread fanlijing
Hello PostgreSQL members: I'm a user of PostgreSQL. Now I have a question when using it. When I want to save a bytea value into a file, what should I do? Is there any function dealing with that in PostgreSQL? (like lo_export() to deal with the large-object) (# I didn't find any) Sorry for

Re: [GENERAL] [9.2devel] why it doesn't do index scan only?

2011-10-09 Thread Thom Brown
On 9 October 2011 18:38, Pavel Stehule pavel.steh...@gmail.com wrote: 2011/10/9 Pavel Stehule pavel.steh...@gmail.com: 2011/10/9 Tom Lane t...@sss.pgh.pa.us: Pavel Stehule pavel.steh...@gmail.com writes: 2011/10/9 Thom Brown t...@linux.com: On 9 October 2011 04:35, Pavel Stehule

Re: [GENERAL] Best PostGIS function for finding the nearest line segment to a given point

2011-10-09 Thread Filip Rembiałkowski
2011/10/8 René Fournier renefourn...@gmail.com Thanks. Based on some further reading, this is what I came up with, in order to hopefully use the GiST index to greatest benefit: gc3=# SELECT datasetnam, r_hnumf, r_hnuml, r_stname_c, r_placenam, ST_Distance(ST_GeomFromText('POINT(-114.053205

Re: [GENERAL] Trigger/Query Warnings

2011-10-09 Thread Jake Stride
Hi David, Thanks, that's exactly what it was. Jake On 9 October 2011 10:05, David Johnston pol...@yahoo.com wrote: On Oct 8, 2011, at 21:45, Jake Stride j...@stride.me.uk wrote: Hi, I've been staring at this for hours and was hoping somebody could point me in the right direction. I have

[GENERAL] could not create file base/16384/11500: File exists

2011-10-09 Thread Harshitha S
Hi, We are the following msg in the postgres logs. could not create file base/16384/11500: File exists Some links indicate that the issue is related to OIDs. Please help me in understanding why the message is appearing and how the issue can be resolved. Regards, Harshitha