[GENERAL] Prepared statements aren't working with parameters with PQexecParams

2008-09-04 Thread Subspace god
The following works executed in the query browser: PREPARE myquery (text) AS INSERT INTO myTable (word) VALUES ($1); EXECUTE myquery('blah'); The following works in C++, executed as two statements with PQexecParams using PQEXECPARAM_FORMAT_BINARY PREPARE myquery AS INSERT INTO myTable (word) VAL

[GENERAL] Cannot connect to server

2008-09-04 Thread Paul Shapley
Hi, I am attempting to 'add a connection' to the postgres database using pgadminlll v_1.8.4, postgresql v 8.3.3 - 1 with PostGis 1.3.3 on Mac OS 10.5.4. After an initial installation it may connect successfully for a couple of days before I'm unable to connect anymore. It is always the same

[GENERAL] Seeking for vacuum advise

2008-09-04 Thread Yogesh Sharma
Hello, We are using postgres for one of our application. Currently using Postgres 8.3 with CentOS 5.3 x86_64 We are using inherited tables. Base table has 3 columns: entry_date timestamp with time zone nametext valuetext pk is timestamp data tables are derived from this base table wit

Re: [GENERAL] You need to rebuild PostgreSQL using --with-libxml.

2008-09-04 Thread Devrim GÜNDÜZ
Hi, Please CC your replies to the list, too: On Thu, 2008-09-04 at 12:20 -0430, Ricardo Antonio Yepez Jimenez wrote: > Gracias Devrim , ya instale la librería libxml2, pero sigue sin > funcional cuando ejecuto un select xmlelement, arroja el siguente > error > > You need to rebuild PostgreSQL us

Re: [GENERAL] Postgres does not start, gives no error

2008-09-04 Thread Akhtar Yasmin-B05532
Hi, I 've finally been able to solve my problem. There were two errors, 1) The postgres in the data directory had gotten overwritten, so none of the scripts were running. I found out this, when I tried making another instance of data. The initdb was not working. As well asa other scipts. Had to

Re: [GENERAL] Getting affected rows in pgplsql

2008-09-04 Thread Artacus
That's just what I needed. Thanks guys! Artacus On Thu, Sep 04, 2008 at 02:07:01AM -0700, Artacus wrote: I'm writing some ETL procedures in pgplsql. After each insert/update/delete, I'd like to log how many rows were affected. http://www.postgresql.org/docs/current/interactive/plpgsql-state

Re: [GENERAL] Oracle and Postgresql

2008-09-04 Thread Artacus
So that is for real huh? I've been to that web site before and figured it was more marketing talk about what they wanted to do rather than a product that was already to market. 2008/9/4 Artacus <[EMAIL PROTECTED]>: Oh, as I was writing a CUBE query today and realized that I forgot to mention

Re: [GENERAL] Oracle and Postgresql

2008-09-04 Thread Artacus
I'm running all 8.3. But I don't think it makes a difference. There is some geometry type cube function but its not at all like the OLAP cube that I'm talking about. What version of Postgres are you running? On Wed, Sep 3, 2008 at 10:21 PM, Artacus <[EMAIL PROTECTED]

[GENERAL] postgres silent install bug?

2008-09-04 Thread Mike Gagnon
Hello everyone, I am trying to run a silent install of Postgres 8.3 using the following command line: MSIEXEC /i "postgresql-8.3-int.msi" /qb /log "c:\mydir\logfile.txt" ADDLOCAL="server,nls,psql,pgadmin,includefiles,libfiles,binfiles" INTERNALLAUNCH=1 DOSERVICE=1 CREATESERVICEUSER=0 DOINITDB=

Re: [GENERAL] Oracle and Postgresql

2008-09-04 Thread Robert Treat
On Wednesday 03 September 2008 09:17:54 Asko Oja wrote: > On Wed, Sep 3, 2008 at 5:56 AM, Robert Treat > > <[EMAIL PROTECTED]>wrote: > > On Tuesday 02 September 2008 17:21:12 Asko Oja wrote: > > > On Tue, Sep 2, 2008 at 2:09 AM, Michael Nolan <[EMAIL PROTECTED]> wrote: > > > > Oracle handles connec

Re: [GENERAL] Postgres does not start, gives no error

2008-09-04 Thread Adrian Klaver
On Thursday 04 September 2008 3:32:55 pm Christophe wrote: > On Sep 4, 2008, at 11:34 AM, Akhtar Yasmin-B05532 wrote: > > I am really stuck here. And need to get a way thru all of this. > > Any suggestions will be really appreciated. > > Have you confirmed that the user that you are logged in as wh

Re: [GENERAL] offtopic, about subject prefix

2008-09-04 Thread Fernando Moreno
2008/9/3 brian <[EMAIL PROTECTED]> > Fernando Moreno wrote: > >> Hello, I'm new to this mailing list, and I have a couple of questions: >> >> Is it really necessary to add the [GENERAL] prefix? >> > > The prefix is added by the mailing list software. It's there so that people > subscribed to multi

[GENERAL] Large Selects and cursors..

2008-09-04 Thread Ow Mun Heng
Hi, I frequently query PG for between 10k - 65k rows of data and was wondering if I should be considering usage of cursors. I’m not too well versed with it’s purpose but based on the docs, it is supposed to be more efficient and also gives the impression of responsiveness. Currently, when I do t

Re: [GENERAL] Postgres does not start, gives no error

2008-09-04 Thread Christophe
On Sep 4, 2008, at 11:34 AM, Akhtar Yasmin-B05532 wrote: I am really stuck here. And need to get a way thru all of this. Any suggestions will be really appreciated. Have you confirmed that the user that you are logged in as when you attempt to start Postgres has write access to /home/data/www

Re: [GENERAL] Postgres does not start, gives no error

2008-09-04 Thread Akhtar Yasmin-B05532
> Maybe you have it configured to log to syslog? Look in postgresql.conf. > regards, tom lane HI, This is regarding the postgres issue.. We are not maintaining any logs for the postgres stop/start. So it becomes a bit problematic, to debug.. These are the steps we are fol

Re: [GENERAL] Full outer join? Cross product? How to blend two queries into single row?

2008-09-04 Thread Sam Mason
On Thu, Sep 04, 2008 at 02:58:39PM -0700, Richard Broersma wrote: > On Thu, Sep 4, 2008 at 2:54 PM, Sam Mason <[EMAIL PROTECTED]> wrote: > > SELECT * FROM foo FULL OUTER CROSS JOIN bar; > > > > Admittedly, there aren't too many use cases for this! But it would make > > things a bit more regular.

Re: [GENERAL] Full outer join? Cross product? How to blend two queries into single row?

2008-09-04 Thread Richard Broersma
On Thu, Sep 4, 2008 at 2:54 PM, Sam Mason <[EMAIL PROTECTED]> wrote: > SELECT * FROM foo FULL OUTER CROSS JOIN bar; > > Admittedly, there aren't too many use cases for this! But it would make > things a bit more regular. SELECT * FROM foo, bar; Isn't this have the same results, but with out th

Re: [GENERAL] Full outer join? Cross product? How to blend two queries into single row?

2008-09-04 Thread Sam Mason
On Thu, Sep 04, 2008 at 03:26:39PM -0600, Scott Marlowe wrote: > On Thu, Sep 4, 2008 at 3:22 PM, Sam Mason <[EMAIL PROTECTED]> wrote: > > The "ON" clause is just a normal expression, so you can just put a > > "TRUE" in there if you want a cross join. I.e. the following is a > > minimal full outer

[GENERAL] Java class to manage a hstore?

2008-09-04 Thread ries van Twisk
Hey All, anybody happen to know if there is a java class 'somewhere' to insert/ update a hstore field in PostgreSQL? Ries -- 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] Full outer join? Cross product? How to blend two queries into single row?

2008-09-04 Thread Richard Broersma
On Thu, Sep 4, 2008 at 2:22 PM, Sam Mason <[EMAIL PROTECTED]> wrote: > This still seems a little nasty and I'd prefer to do something like: my idea seems nastiest of all: SELECT * FROM ( SELECT COUNT(*) AS rownbr, A1.col1, A1.col2 FROM Mytable AS A1 INNER JOIN Mytable A

Re: [GENERAL] Full outer join? Cross product? How to blend two queries into single row?

2008-09-04 Thread Scott Marlowe
On Thu, Sep 4, 2008 at 3:22 PM, Sam Mason <[EMAIL PROTECTED]> wrote: > On Thu, Sep 04, 2008 at 03:43:33PM -0500, D. Dante Lorenso wrote: >> I came up with this query that works, but seems overly complicated: >> >> SELECT a.col1, a.col2, b.col3, b.col4 >> FROM >> (SELECT col1, col3, TRUE AS

Re: [GENERAL] Full outer join? Cross product? How to blend two queries into single row?

2008-09-04 Thread Sam Mason
On Thu, Sep 04, 2008 at 03:43:33PM -0500, D. Dante Lorenso wrote: > I came up with this query that works, but seems overly complicated: > > SELECT a.col1, a.col2, b.col3, b.col4 > FROM > (SELECT col1, col3, TRUE AS join_column > FROM mytable > WHERE uid = 'abc') a > FULL O

Re: [GENERAL] Postgres does not start, gives no error

2008-09-04 Thread Scott Marlowe
On Thu, Sep 4, 2008 at 12:53 PM, Akhtar Yasmin-B05532 <[EMAIL PROTECTED]> wrote: > >> exist the file postmaster.pid in your directory? >No the postmaster.pid does not exist in the directory, even when > I start the server, it does not appear, I am assuming, that this file is > present only

[GENERAL] Full outer join? Cross product? How to blend two queries into single row?

2008-09-04 Thread D. Dante Lorenso
All, I want to do something simple and the terminology is slipping me. I want to execute two separate queries that should return 0 or 1 rows and I want to join the results of those queries into a single row. SELECT a.col1, a.col2 FROM mytable a WHERE a.uid = 'abc'; SELECT b.col3, b.

Re: [GENERAL] How to test something using ROLLBACK TRANSACTION

2008-09-04 Thread Richard Broersma
On Thu, Sep 4, 2008 at 12:28 PM, Scott Marlowe <[EMAIL PROTECTED]> wrote: > Have you tried psql? That's all I usually use. Here's what I get The only problem with psql is that it is addictive. Once your hooked, it is hard to use anything else. :o) -- Regards, Richard Broersma Jr. Visit the

Re: [GENERAL] Postgres does not start, gives no error

2008-09-04 Thread Akhtar Yasmin-B05532
> exist the file postmaster.pid in your directory? No the postmaster.pid does not exist in the directory, even when I start the server, it does not appear, I am assuming, that this file is present only when postmaster in running. > check the log of the OS and the permissions of th

Re: [GENERAL] How to test something using ROLLBACK TRANSACTION

2008-09-04 Thread Scott Marlowe
On Thu, Sep 4, 2008 at 1:17 PM, William Garrison <[EMAIL PROTECTED]> wrote: > Coming from MS SQL server, if I ever change anything vital on a production > system, or do any kind of major hackery on my own, I wrap it in a > transaction first: > > BEGIN TRANSACTION; > DELETE FROM vital_information WH

[GENERAL] How to test something using ROLLBACK TRANSACTION

2008-09-04 Thread William Garrison
Coming from MS SQL server, if I ever change anything vital on a production system, or do any kind of major hackery on my own, I wrap it in a transaction first: BEGIN TRANSACTION; DELETE FROM vital_information WHERE primary_key = 10; ROLLBACK TRANSACTION; I then make sure that the result comes

Re: [GENERAL] Postgres does not start, gives no error

2008-09-04 Thread Lennin Caro
--- On Wed, 9/3/08, Akhtar Yasmin-B05532 <[EMAIL PROTECTED]> wrote: > From: Akhtar Yasmin-B05532 <[EMAIL PROTECTED]> > Subject: [GENERAL] Postgres does not start, gives no error > To: pgsql-general@postgresql.org > Date: Wednesday, September 3, 2008, 7:11 PM > HI, > > I am facing this pecilia

Re: [GENERAL] Oracle and Postgresql

2008-09-04 Thread Lars Haugseth
* [EMAIL PROTECTED] ("Richard Broersma") wrote: > > On Sun, Aug 31, 2008 at 1:50 PM, Kevin Hunter <[EMAIL PROTECTED]> wrote: > > > 7. Though I don't personally buy it, I have heard others complain > > loudly that there is no print-version of Postgres documentation. > > > This one should be ta

Re: [GENERAL] Postgres does not start, gives no error

2008-09-04 Thread Lennin Caro
--- On Wed, 9/3/08, Akhtar Yasmin-B05532 <[EMAIL PROTECTED]> wrote: > From: Akhtar Yasmin-B05532 <[EMAIL PROTECTED]> > Subject: Re: [GENERAL] Postgres does not start, gives no error > To: "Tom Lane" <[EMAIL PROTECTED]> > Cc: "Joshua Drake" <[EMAIL PROTECTED]>, pgsql-general@postgresql.org > Dat

Re: [GENERAL] Changes for version 8.4

2008-09-04 Thread Devrim GÜNDÜZ
On Thu, 2008-09-04 at 10:45 -0400, Alvaro Herrera wrote: > Joao Ferreira gmail escribió: > > Is there a date for the release of 8.4 ? > > http://wiki.postgresql.org/wiki/PostgreSQL_8.4_Development_Plan /me notes that noone responded like "It will be released when it is ready". -- Devrim GÜNDÜZ,

Re: [GENERAL] You need to rebuild PostgreSQL using --with-libxml.

2008-09-04 Thread Devrim GÜNDÜZ
Hi, On Thu, 2008-09-04 at 10:18 -0430, Ricardo Antonio Yepez Jimenez wrote: > Buenos Dias, necesito saber los pasos para recompilar con soporte > para > xml, en redhat 4 entreprise y postgres 8.3. You cannot compile PostgreSQL 8.3 on RHEL 4 with xml support -- unless you install libxml2 from sou

[GENERAL] You need to rebuild PostgreSQL using --with-libxml.

2008-09-04 Thread Ricardo Antonio Yepez Jimenez
Buenos Dias, necesito saber los pasos para recompilar con soporte para xml, en redhat 4 entreprise y postgres 8.3. Gracias, .

Re: [GENERAL] Changes for version 8.4

2008-09-04 Thread Alvaro Herrera
Joao Ferreira gmail escribió: > Is there a date for the release of 8.4 ? http://wiki.postgresql.org/wiki/PostgreSQL_8.4_Development_Plan -- Alvaro Herrerahttp://www.CommandPrompt.com/ PostgreSQL Replication, Consulting, Custom Development, 24x7 support -- Sent v

Re: [GENERAL] Changes for version 8.4

2008-09-04 Thread Joao Ferreira gmail
Is there a date for the release of 8.4 ? joao On Thu, 2008-09-04 at 10:09 -0400, Alvaro Herrera wrote: > paul tilles wrote: > > Where can I find a list of changes for Version 8.4 of postgres? > > It's not officially written anywhere. As a starting point you can look > here: > http://wiki.postgr

Re: [GENERAL] Changes for version 8.4

2008-09-04 Thread Alvaro Herrera
paul tilles wrote: > Where can I find a list of changes for Version 8.4 of postgres? It's not officially written anywhere. As a starting point you can look here: http://wiki.postgresql.org/wiki/Category:CommitFest Then look at each Commitfest:2008:xx page, and see the list of committed patches.

[GENERAL] Changes for version 8.4

2008-09-04 Thread paul tilles
Where can I find a list of changes for Version 8.4 of postgres? Paul Tilles -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-general

[GENERAL] xpath_bool_ns() and xml2

2008-09-04 Thread Tobias Anstett
Hi, does anybody know how to use the xml2 function xpath_bool with namespaces. I have used this function successfully as long as my xml documents haven't contained namespaces. I searched with google and found some readme file where the function xpath_bool_ns was available that would probably

[GENERAL] xml2 vs XMLFunctions

2008-09-04 Thread Tobias Anstett
Hi, I am currently using xml2 functionality in PostgreSQL 8.3.x and want to substitute it by the newer API as mentioned here: >From PostgreSQL 8.3 on, there is XML-related functionality based on the SQL/XML standard in the core server. That functionality covers XML syntax checking and XPath

Re: [GENERAL] Oracle and Postgresql

2008-09-04 Thread Roberts, Jon
> > Oh, as I was writing a CUBE query today and realized that I forgot to > mention this. And unlike most gripes, like MERGE INTO or CTE's which are > really convenience things, this is key piece of functionality that you > just can't reproduce in Postgres. > > That said, there's not the same s

Re: [GENERAL] Getting affected rows in pgplsql

2008-09-04 Thread hubert depesz lubaczewski
On Thu, Sep 04, 2008 at 02:07:01AM -0700, Artacus wrote: > I'm writing some ETL procedures in pgplsql. After each > insert/update/delete, I'd like to log how many rows were affected. http://www.postgresql.org/docs/current/interactive/plpgsql-statements.html search for "GET DIAGNOSTICS" Best reg

Re: [GENERAL] Getting affected rows in pgplsql

2008-09-04 Thread Blazej
Maybe this will be helpfull: http://www.postgresql.org/docs/8.3/interactive/plpgsql-statements.html#PLPGSQL-STATEMENTS-DIAGNOSTICS Regards, Blazej Oleszkiewicz 2008/9/4 Artacus <[EMAIL PROTECTED]>: > I'm writing some ETL procedures in pgplsql. After each insert/update/delete, > I'd like to log h

[GENERAL] Getting affected rows in pgplsql

2008-09-04 Thread Artacus
I'm writing some ETL procedures in pgplsql. After each insert/update/delete, I'd like to log how many rows were affected. I'm not finding anything on Google. Does anyone know how to get this? -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscript