Re: [GENERAL] Importing data

2003-08-14 Thread James Moe
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On Thu, 14 Aug 2003 18:48:43 -0500, Andrew L. Gould wrote: >> >> What you're looking for is COPY: >> >> http://www.postgresql.org/docs/7.3/static/sql-copy.html >> Thanks! That was it. - -- jimoe at sohnen-moe dot com pgp/gpg public key: http://www

Re: [GENERAL] Simple DBI question.

2003-08-14 Thread Thomas A. Lowery
On Tue, Aug 12, 2003 at 04:58:49PM -0400, David Siebert wrote: > How do I connect to a postgres sever across a network using DBI? > I can not find an example of it anywhere in any docs. connect string like "dbi:Pg:dbname=db;host=machine;port=5432" Example: use DBI; my $dbh = DBI->connect( "dbi:

Re: [GENERAL] XML?

2003-08-14 Thread Gavin M. Roy
Here's some PHP code I use to do just that: $record = $prepend . "\n"; for ( $y = 0; $y < pg_NumFields($resultid); $y++ ) { $record .= $prepend . "\t<" . pg_FieldName($resultid, $y) . ">"; $data = Trim(pg_Result($resultid, $row, $y)); $data = ereg_replace("&", "&", $data);

Re: [GENERAL] Anomaly with SUM().

2003-08-14 Thread Stephan Szabo
On Fri, 8 Aug 2003, Anthony Best wrote: > I've noticed that the SUM() seems to overflow under some situations. > > The only difference is the order that the data is retrived from the > database. Is amount a float type column (float4 or float8)? If so, you're probably just running into issues with

[GENERAL] FATAL: The database system is in recovery mode

2003-08-14 Thread Kenéz Attila
Hi, I have got a problem with PostgreSQL 7.3.2 with cygwin under Windows 98. At our clients sometimes during normal work the database goes into recovery mode. I do not know what couses it, but it seems that this happens when one of the client applications freeze (or the client application freeze w

[GENERAL] Resolved: PostGreSQL - Accessing It

2003-08-14 Thread Mel Roman
> test=# CREATE USER mel CREATEDB > test-# \q > bash-2.05b$ exit > exit > [EMAIL PROTECTED] mel]$ psql test > psql: FATAL 1: user "mel" does not exist > I just figured out my problem. As you can see from

[GENERAL] mod_auth_pgsql for Apache and limiting the number of login attempts

2003-08-14 Thread Holger Marzen
Hi all, for a long time I am using mod_auth_pgsql for Apache 1.3. But I always wished that I could limit the number of attempts, so no-one can try as often as he wants to. Unfortunately the author of mod_auth_pgsql didn't answer, so I had to do it by myself. But I didn't want to make major change

Re: [GENERAL] Continued mail server problems for all PGSQL mailing

2003-08-14 Thread Joshua D. Drake
207.173.200.206? We aren't using that server for relaying ... we *are* using: 207.173.200.143, which does reverse: %nslookup 207.173.200.143 Server: neptune.hub.org Address: 64.117.224.130 Name:hosting.commandprompt.com Address: 207.173.200.143 Joshua, are there multiple IPs on that box th

Re: [GENERAL] PostgreSQL

2003-08-14 Thread Alexander Litvinov
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 I confirm this behavour: cyrilic words are not changed by lower()/upper() functions, nor catched by ilike. I am using : => SELECT version(); version - --- Postgr

Re: [GENERAL] 7.4Beta1 "failed to create socket: Address family not supported by protocol"

2003-08-14 Thread Tom Lane
Robert Creager <[EMAIL PROTECTED]> writes: > Aug 10 14:11:27 thunder postgres[18613]: [1-1] LOG: failed to create > socket: Address family not supported by protocol It's normal for this to happen if you have userland (libc) code that supports IPv6 but your kernel isn't configured to do so. The p

Re: [GENERAL] postgesql-7.3.3 lo_create/lo_open fails

2003-08-14 Thread Tom Lane
Colm Dobbs <[EMAIL PROTECTED]> writes: > Oid lobjId = lo_creat(conn, INV_READ|INV_WRITE); > if (lobjId != -1) This coding is wrong --- lo_creat would return 0 (InvalidOid) on failure, not -1. As for *why* it's failing, PQerrorMessage might offer some hint. I'm a tad surprised by tha

[GENERAL] update system table?

2003-08-14 Thread Eric Anderson Vianet SAO
how could I fix this problem:   ERROR:  unexpected chunk number 8 (expected 0) for toast value 6935693   It appear to be simple: update chunk_seq from 8 to 0. how to do it?   in the stand alone postgres, could I copy a entire table? how to do it?   tnx   Eric  

[GENERAL] Commercial support?

2003-08-14 Thread Dustin Sallings
I'm assuming this has been beaten to death, but I'm looking for some companies offering commercial support contracts in SF bay area. The link for commercial support from the FAQ is broken, and my 3/4 ass search attempts came up with nothing. I'm a long-time postgres user leading a developmen

Re: [GENERAL] PostGreSQL - Accessing It

2003-08-14 Thread Mel Roman
In article <[EMAIL PROTECTED]>, Thomas Beutin wrote: >> I have the same problem as Michael. I've installed postgresql and am >> running the service, but I can't log in as postgres. I just tried the >> command line "psql -U postgres template1", but I get the message >> "authentication failed for u

Re: [GENERAL] OT: Address Fields

2003-08-14 Thread Karsten Hilbert
> Just wondering if anyone has any tips on the best way to represent > international addresses (ie from any country) in a database? Not the *best* way but here is how we do it in GnuMed (www.gnumed.org). Add in some convenient denormalizing views that I did not include. Full schema in CVS on gnu.o

Re: [GENERAL] extract and time zones

2003-08-14 Thread Oscar Estevez Lopez
El Fri, 01 Aug 2003 10:55:49 -0400 Tom Lane <[EMAIL PROTECTED]> escribio: thanks :) > Oscar Estevez Lopez <[EMAIL PROTECTED]> writes: > > d :1059744638 > > d::timestamp : 1059737438 > > ?? > > This is fixed as of PG 7.3.4 ... > > 2003-02-27 16:37 tgl > > * src/backend/utils/

Re: [GENERAL] How to prevent vacuum and reindex from deadlocking.

2003-08-14 Thread Robert Creager
On Mon, 11 Aug 2003 10:11:37 -0400 Tom Lane <[EMAIL PROTECTED]> said something like: > Robert Creager <[EMAIL PROTECTED]> writes: > > Opps, if it helps, the log of the deadlock: > > > Aug 10 14:19:36 thunder postgres[18735]: [2-1] ERROR: deadlock detected > > > Aug 10 14:19:36 thunder postgres[

Re: [GENERAL] public key functions for postgresql ?

2003-08-14 Thread Tom Lane
Bruce Momjian <[EMAIL PROTECTED]> writes: > I think you are right --- there are no public key functions in there. You're right. Now that I think about it, there was some discussion to the effect of we couldn't include any actual encryption (as distinct from crypto hashes) for fear of problems wi

Re: [GENERAL] Tsearch limitations

2003-08-14 Thread Oleg Bartunov
On Mon, 11 Aug 2003 [EMAIL PROTECTED] wrote: > Oleg, > > I understand (i think) how the parser breaks up the input into words > and builds ts_vector's. > > And i understand how to do queries as described into the documentation. > (I have read it!) > > SELECT * FROM vectors WHERE vector @@ to_tsque

Re: [GENERAL] Timestamp with zero precision

2003-08-14 Thread Tom Lane
"Vilson farias" <[EMAIL PROTECTED]> writes: > Is there a way to set a "timestamp compatibility mode" for PostgreSQL > 7.3.3's timestamp with older versions of database (like 7.1.2)? I'd like to > set all timestamps to have precision =3D zero (hh:mm:ss only, without any > millisecond). Create the

Re: [GENERAL] PL/C functions

2003-08-14 Thread Dennis Gearon
I haven't seen anything saying it's possible to use either default arguments or variable argument lists in C functions used iin PL/C, but otherwise: c++ http://www.google.com/search?hl=en&lr=&ie=UTF-8&oe=UTF-8&q=variable+argument+list+function+c%2B%2B&btnG=Google+Search php http://www.google.com/s

Re: [GENERAL] PostGreSQL - Accessing It

2003-08-14 Thread Joshua D. Drake
Michael wrote: I cannot access/create a database from root or any of the other accounts I have setup for RH9. I noticed that there is a user setup for postgres (I guess this part of the postgres install) but can’t login as that user. I can’t even read or change the password. How do I get at Po

Re: [GENERAL] 7.4Beta1 "failed to create socket: Address family not

2003-08-14 Thread Bruce Momjian
Tom Lane wrote: > Bruce Momjian <[EMAIL PROTECTED]> writes: > > Tom Lane wrote: > >> The real problem is perhaps that the message gives no hint that it's > >> talking about being unable to establish an IPv6 socket. With that hint, > >> perhaps people would realize that it's not a problem. > > > N

Re: [GENERAL] Sorting Problem

2003-08-14 Thread Dennis Gearon
You mean in his own local environment? So all his programs, console operations, etc, will have the new encoding? Or 'LANG/LC_ALL' for Posgres specifically? Tom Lane wrote: Dennis Gearon <[EMAIL PROTECTED]> writes: To help my understanding of this type of thing, when he reinits the database, can

Re: [GENERAL] Help! Can't pg_dump anything: handler procedure for procedural language plpgsql not found

2003-08-14 Thread Richard Huxton
On Tuesday 12 August 2003 01:41, Mark Mikulec wrote: > Hi there, > > I wonder if anyone can shed some light on a very frustrating problem. > > I'm running a debian linux 3.0 "woody" server, nothing special, with > the latest version of postres that apt-get will allow me, which I > *think* it;s 7.1

Re: [GENERAL] extract and time zones

2003-08-14 Thread Oscar Estevez Lopez
El Fri, 01 Aug 2003 08:19:25 -0700 Dennis Gearon <[EMAIL PROTECTED]> escribio: Cut'n paste :P > Don't know the answer to your question, but how did you type all those commands in > one second? :-) > > Oscar Estevez Lopez wrote: > > > Um, and what about this? > > > > $ uname -a > > FreeBSD can

Re: [GENERAL] Update of foreign key values

2003-08-14 Thread Roderick A. Anderson
On Tue, 12 Aug 2003, Dennis Gearon wrote: > Yuup, always name constraints so it's easier to remove them. And if > you name them meaningfully, then others might understand why they > exist! (or later after a coffeeless morning) This "application" has grown as a fungus: in the dark and nourished on

Re: [GENERAL] Sorting Problem

2003-08-14 Thread Kathy zhu
Do you mean that soring doesn't work for en_US locale ??? And, does encoding affect sorting at all ?? thanks, kathy Tom Lane wrote: "Tim Edwards" <[EMAIL PROTECTED]> writes: When I sort ASC on the varchar I get some strange results. Here a section of data cut after running a sort. It starts with

Re: [GENERAL] PL/C functions

2003-08-14 Thread Dennis Gearon
User defined functions written in C/C++? That's _NOT_ known as PL/C? sorry for the confusion. Tom Lane wrote: Dennis Gearon <[EMAIL PROTECTED]> writes: Uuuh, C++ can do it, PHP can do it, JAVA can do it, I just want to know if PL/C can do it for UDF's. We have no animal called "PL/C".

Re: [GENERAL] types of constraint deferment

2003-08-14 Thread Stephan Szabo
On 12 Aug 2003, Ron Johnson wrote: > On Tue, 2003-08-12 at 00:38, Stephan Szabo wrote: > > On 11 Aug 2003, Ron Johnson wrote: > > > > > v7.3.3 > > > http://www.postgresql.org/docs/7.3/static/sql-createtable.html > > > > > > Is "INITIALLY DEFERRED" a modifier of "NOT DEFERRABLE"? If so, > > > wha

Re: [GENERAL] PL/C functions

2003-08-14 Thread Dennis Gearon
This is where a variable argument list for a function would come in handy, if ISO C had such for 'strxfrm()'. The locale could be supplied INLINE, instead of taken from the machine LOCALE. Maybe I'll just copy the library functions and change them to use an extra argument for LOCALE. Tom Lane wrot

Re: [GENERAL] Update of foreign key values

2003-08-14 Thread Roderick A. Anderson
On Mon, 11 Aug 2003, Stephan Szabo wrote: > Yes. Either DEFERRABLE or INITIALLY DEFERRED must be given in order for > set constraints to be meaningful. This might be another good place to > consider a little clarification (or maybe a doc note in the interactive > docs) Phew. I thought I was goin

Re: [GENERAL] Help! Can't pg_dump anything: handler procedure for procedural language plpgsql not found

2003-08-14 Thread Tom Lane
[EMAIL PROTECTED] (Mark Mikulec) writes: > But i'd always get the following error message: > pg_dump: handler procedure for procedural language plpgsql not found Do you have any functions written in plpgsql? (I'm guessing not, or you would have other problems besides pg_dump not working.) If no

Re: [GENERAL] PostgreSQL

2003-08-14 Thread Dennis Gearon
I think if Postgres were to be completely UTF8 compatible, and as the default configuration, we'd do a lot better against 'the others', and take more of Oracle's market. Bruce Momjian wrote: Well, I have no mention of this problem in the TODO list, so I would like to get a good description of why

Re: [GENERAL] Importing data

2003-08-14 Thread Andrew L. Gould
oops. I forgot to reply to the list. On Thursday 14 August 2003 06:45 pm, you wrote: > On Thursday 14 August 2003 06:10 pm, you wrote: > > -BEGIN PGP SIGNED MESSAGE- > > Hash: SHA1 > > > > Hello, > > I have an old-ish Sybase dbms (SQL Anywhere v5.x) that does not offer a > > DUMP comman

[GENERAL] general database password

2003-08-14 Thread Daniel Seichter
Hello, I have maybe a strange question: Is it possible to configure a main password for a hole? For a better understand: Only my program knows this mainpassword and if my program can connect and is connected, the user can connect to database (with his own account). The user is only allowed to con

[GENERAL] How to get the total number of rows with a query "limit" ?

2003-08-14 Thread krystoffff
Hi I would like to paginate the results of a query on several pages. So I use a query with a limit X offset Y to display X results on a page, ok. But for the first page, I need to run the same query with a count(*) to know how many pages I will get (number total of rows/ X). The problem is my qu

[GENERAL] Searching Tables

2003-08-14 Thread w00t
I have 4 tables for example firstname | middlename | lastname | phonenumber Now I am trying to search for multiple entries for example SELECT * FROM phonenumbers; I am trying to use SELECT 'not sure what here' FROM phonenumbers; so that I can find any fields that have multiple information in

Re: [GENERAL] Update of foreign key values

2003-08-14 Thread Dennis Gearon
Yuup, always name constraints so it's easier to remove them. And if you name them meaningfully, then others might understand why they exist! (or later after a coffeeless morning) Roderick A. Anderson wrote: On Mon, 11 Aug 2003, Stephan Szabo wrote: Yes. Either DEFERRABLE or INITIALLY DEFERRED m

[GENERAL] FTI problems

2003-08-14 Thread psql-mail
I am trying to use the fti module to search my text. Searching through the raw text using ILIKE takes 3 seconds, searching using fti takes 212 seconds. Then i tried to turn off seq_scan to see what happens, the planner still does a seq_scan. Why does the planner not use the index? Are there any o

Re: [GENERAL] PostGreSQL - Accessing It

2003-08-14 Thread Mel Roman
In article <[EMAIL PROTECTED]>, "Joshua D. Drake" wrote: > Michael wrote: > >> I cannot access/create a database from root or any of the other >> accounts I have setup for RH9. I noticed that there is a user setup >> for postgres (I guess this part of the postgres install) but can’t >> login as

Support contracts (was Re: [GENERAL] Commercial support?)

2003-08-14 Thread Ron Johnson
On Wed, 2003-08-13 at 11:59, Dustin Sallings wrote: > On Tuesday, Aug 12, 2003, at 09:55 US/Pacific, Al Hulaton wrote: [snip] > We're looking at various databases for production use in our product > and pricing the various solutions. My personal preference is postgres, > but we're also loo

Re: [GENERAL] Sorting Problem

2003-08-14 Thread Tom Lane
"Tim Edwards" <[EMAIL PROTECTED]> writes: > When I sort ASC on the varchar I get some strange results. Here a section of > data cut after running a sort. It starts with RM- then does RMT- Then goes > back for more RM-. Sounds like you're in en_US locale, or at least something other than C locale

Re: [GENERAL] Timestamp with zero precision

2003-08-14 Thread Shridhar Daithankar
On 12 Aug 2003 at 11:02, Vilson farias wrote: > Is there a way to set a "timestamp compatibility mode" for PostgreSQL > 7.3.3's timestamp with older versions of database (like 7.1.2)? I'd like to > set all timestamps to have precision = zero (hh:mm:ss only, without any > millisecond). > > I'm as

Re: [GENERAL] Sorting Problem

2003-08-14 Thread Maksim Likharev
Agreement about what, necessity of collate per table and Unicode build in data type, hail yeah... but that's really change nothing unless I get big shovel and start "digging on" by my own producing in reasonable period of time something... and even for that, nobody guarantee that my exercise will

Re: [GENERAL] Sorting Problem

2003-08-14 Thread Dennis Gearon
To help my understanding of this type of thing, when he reinits the database, can he get the PG backend to be running with a different LOCALE than the machine's? Tom Lane wrote: "Tim Edwards" <[EMAIL PROTECTED]> writes: When I sort ASC on the varchar I get some strange results. Here a section of

Re: [GENERAL] Sorting Problem

2003-08-14 Thread Maksim Likharev
If you are talking about everything that lies under so called LATIN-1 ( ISO-8859-1 ) en_US encapsulates ( at least suppose to ) all those sorting rules, do not remember about accents tho. -Original Message- From: Kathy zhu [mailto:[EMAIL PROTECTED] Sent: Tuesday, August 12, 2003 4:43 PM

[GENERAL] optimisation of a code

2003-08-14 Thread krystoffff
Hi all I wrote a script in PHP with mysql (hum ... to be honnest, I wrote this script under PostGreSQL but we recently migrated to mysql, so I had to adapt my code to mysql ... sorry about that ... anyway, it is the same kind of query, with subqueries !) but this is a very very long script ... I

Re: [GENERAL] Commercial support?

2003-08-14 Thread scott.marlowe
On Wed, 13 Aug 2003, Dustin Sallings wrote: > > On Tuesday, Aug 12, 2003, at 09:55 US/Pacific, Al Hulaton wrote: > > > That's something we do here at Command Prompt. Phone number's below or > > there's the guaranteed 4 hour response time form we have on our > > website. > > We're lookin

[GENERAL] Update of foreign key values

2003-08-14 Thread Roderick A. Anderson
I have two tables in two databases (Pg 7.2.1 - yes I need to upgrade but there are several other dependencies I have to resolve first) and I need to update one database's tables so they can be merged into the other database's table. I know I can drop the constraints and update the tables (primary

Re: [GENERAL] Sorting Problem

2003-08-14 Thread Dennis Björklund
On Tue, 12 Aug 2003, Maksim Likharev wrote: > If you are talking about everything that lies under so called LATIN-1 ( > ISO-8859-1 ) en_US encapsulates ( at least suppose to ) all those > sorting rules, do not remember about accents tho. It does not work like that. Different countries in europe t

Re: [GENERAL] PL/C functions

2003-08-14 Thread Tom Lane
Dennis Gearon <[EMAIL PROTECTED]> writes: > Uuuh, C++ can do it, PHP can do it, JAVA can do it, I just > want to know if PL/C can do it for UDF's. We have no animal called "PL/C". Kindly be more clear about what your question is. regards, tom lane ---

Re: [GENERAL] Sorting Problem

2003-08-14 Thread Tom Lane
Dennis Gearon <[EMAIL PROTECTED]> writes: > You mean in his own local environment? So all his programs, console operations, etc, > will have the new encoding? Or 'LANG/LC_ALL' for Posgres specifically? I mean he needs to run initdb with C as the selected locale. It has nothing to do with what en

Re: [GENERAL] types of constraint deferment

2003-08-14 Thread Stephan Szabo
On 11 Aug 2003, Ron Johnson wrote: > v7.3.3 > http://www.postgresql.org/docs/7.3/static/sql-createtable.html > > Is "INITIALLY DEFERRED" a modifier of "NOT DEFERRABLE"? If so, > what does it do, since they seem contradictory. It's not allowed. An INITIALLY DEFERRED constraint must not be defin

Re: [GENERAL] Sorting Problem

2003-08-14 Thread Tom Lane
Kathy zhu <[EMAIL PROTECTED]> writes: > Do you mean that soring doesn't work for en_US locale ??? Oh it works all right, it just doesn't agree with Tim's idea of what sorted order is ;-) regards, tom lane ---(end of broadcast)--

Re: [GENERAL] importing db as text files

2003-08-14 Thread expect
On Thu, 14 Aug 2003 07:34:55 +1000 Jason Godden <[EMAIL PROTECTED]> wrote: > Hi expect, > > Best way in my opinion is to use the copy table command. This way Pg will > actually 'massage' the data (string escapes and all) for you. I guess we're of the same opinion. I did use the copy table com

Re: [GENERAL] 7.4Beta1 "failed to create socket: Address family not

2003-08-14 Thread Tom Lane
Bruce Momjian <[EMAIL PROTECTED]> writes: > There was a big discussion over whether we should require IPv6 to be > enabled individually, and then throw a hard error if IPv6 fails, but at > this stage, it seemed best to most to just try IPv6 and soft-fail, while > throwing a message in the server lo

Re: [GENERAL] Sorting Problem

2003-08-14 Thread Bruce Momjian
I think the question is how often are you passing data around/storing it _in_ your application and how often are you processing it. --- Dennis Gearon wrote: > I agree with all of that except for one caveat: > > all my

Re: [GENERAL] 7.4Beta1 "failed to create socket: Address family not

2003-08-14 Thread Bruce Momjian
My original commit had a message stating it was an IPv6 and the kernel didn't support it. I don't see that message in CVS anymore, but I think we need something similar. There was a big discussion over whether we should require IPv6 to be enabled individually, and then throw a hard error if IPv6

[GENERAL] {REPOST, CLARIFIED} How to recognize PG SQL files?

2003-08-14 Thread Joel Burton
On Wed, Aug 06, 2003 at 12:55:52PM -0400, Joel Burton wrote: Reposting, with some clarification to my request. Thanks to the several responses I received originally. Yes, I know that a perfectly vaild PGSQL SQL file could contain only ANSI SQL and therefore not be recognized as PG-related. In tha

[GENERAL] The database is very slow !

2003-08-14 Thread krystoffff
I currently have PostgreSQL 7.1 installed on a server with about 700 Mb of RAM. I have many problems of speed with a database I created. For example, it took almost 12 sec to run the query "select * from table" directly from PostgreSQL, on a table with 4000 records and 60 fields ... And the whole

Re: [GENERAL] Sorting Problem

2003-08-14 Thread Gianni Mariani
Dennis Gearon wrote: Got a link to that section of the standard, or better yet, to a 'interpreted' version of the standard? :-) Stephan Szabo wrote: On Wed, 13 Aug 2003, Dennis Gearon wrote: Dennis Bj?rklund wrote: In the future we need indexes that depend on the locale (and a lot of other

Re: [GENERAL] unexpected chunk number

2003-08-14 Thread Eric Anderson Vianet SAO
sorry about dumb ´lenght´ instead ´length´. the length of chunk_data is 255. tnx. Eric - Original Message - From: "Eric Anderson Vianet SAO" <[EMAIL PROTECTED]> To: "PostgreSQL general" <[EMAIL PROTECTED]> Sent: Friday, August 08, 2003 1:14 PM Subject: Re: [GENERAL] unexpected chunk num

[GENERAL] postgesql-7.3.3 lo_create/lo_open fails

2003-08-14 Thread Colm Dobbs
Hi Guys, I'm currenlty involved in a port of our gateway code from a Solaris 8 environment to a HP-UX11.11 incorporating postgresql-7.3.3. We're having some problems with creation and opening of large objects and was hoping that you may be able to shed some light on them. I extracted the LO co

Re: [GENERAL] Commercial support?

2003-08-14 Thread Josh Berkus
Folks, > Josh Berkus <[EMAIL PROTECTED]> does PostgreSQL support, and he is in > SF. I am CC'ing him. What kind of support is requested? -- Josh Berkus Aglio Database Solutions San Francisco ---(end of broadcast)--- TIP 7: don't forget to inc

Re: [GENERAL] Sorting Problem

2003-08-14 Thread Dennis Gearon
Dennis Björklund wrote: In the future we need indexes that depend on the locale (and a lot of other changes). I agree. I've been looking at the web on this subject a lot lately. I am **NOT** a microslop fan, but SQL-SERVER even lets a user define a language(maybe encoding) down to the column leve

Re: [GENERAL] How to prevent vacuum and reindex from deadlocking.

2003-08-14 Thread Tom Lane
Robert Creager <[EMAIL PROTECTED]> writes: > Opps, if it helps, the log of the deadlock: > Aug 10 14:19:36 thunder postgres[18735]: [2-1] ERROR: deadlock detected > Aug 10 14:19:36 thunder postgres[18735]: [2-2] DETAIL: Proc 18735 waits > for AccessExclusiveLock on relation 18028 of database 17

[GENERAL] Viewing Client Connections..

2003-08-14 Thread Jerome Macaranas
Is there a way in postgres to view current client connections? including statistics.. how long did it take for him to connect and disconnect.. etc TIA ---(end of broadcast)--- TIP 8: explain analyze is your friend

[GENERAL] PostgreSQL

2003-08-14 Thread Eugeny Balakhonov
Hello, all!   I have a good question for PostgreSQL FAQ.   How to use string functions (like UPPER()/LOWER()) for non-latin strings? Why UPPER() function doesn't work with my UNICODE PostgreSQL database which contains non-latin characters (like cyrillic)? How to make case insensetive search

Re: [GENERAL] Sorting Problem

2003-08-14 Thread Gianni Mariani
Dennis Gearon wrote: I agree with all of that except for one caveat: all my reading, and just general off the cuff thinking, says that processing variable width characters SIGNIFICANTLY slows an application. It seems better to PROCESS fixed width characters (1,2,4 byte), and TRANSMIT varia

[GENERAL] Join faster than single table query

2003-08-14 Thread ruben
Hi: I must have missed something, but how is it possible that a join on tables A and B is faster (a lot faster) than a query to one of the tables with the same conditions? The problem seems to be with the query plan, in the case os a query to table_a only, the planner executes a "Seq Scan", in

Re: [GENERAL] The database is very slow !

2003-08-14 Thread Tom Lane
[EMAIL PROTECTED] (krysto) writes: > I have many problems of speed with a database I created. For example, > it took almost 12 sec to run the query "select * from table" directly > from PostgreSQL, on a table with 4000 records and 60 fields ... When did you last VACUUM this table?

[GENERAL] Sorting Problem

2003-08-14 Thread Tim Edwards
Currently I'm running PostgreSQL 7.2.3 and having a problem sorting. I've got two colums of data, one Int4 one Varchar. When I sort ASC on the varchar I get some strange results. Here a section of data cut after running a sort. It starts with RM- then does RMT- Then goes back for more RM-. I've

[GENERAL] problem with timeofday() function in cvs PostgreSQL

2003-08-14 Thread Pavel Stehule
Hello In this version I can't convert returned value to time. timeofday() return text. I need convert to timestamp before. It is normal behavior? I expected timestamp as returned type. regards Pavel Stehule ---(end of broadcast)--- TIP 8: expla

Re: [GENERAL] Continued mail server problems for all PGSQL mailing lists I'm on

2003-08-14 Thread HansH
In response to "Phil Howard": >> 207.173.200.206? We aren't using that server for relaying ... we >> *are* using: 207.173.200.143, which does reverse: >> %nslookup 207.173.200.143 >> Server: neptune.hub.org >> Address: 64.117.224.130 >> Name:hosting.commandprompt.com >> Address: 207.173.200

Re: [GENERAL] postmaster(s) have high load average

2003-08-14 Thread Chris Webster
Martijn van Oosterhout wrote: Have you run VACUUM and/or VACUUM FULL and/or ANALYZE recently? a) yes. I have it run analyze every 30 minutes or 1600 record additions. Records are never updated or deleted so I assume I don't need vacuum. b) It does it even at start up when there are fewer t

Re: v7.4 on Windows ... (Was: Re: [GENERAL] v7.4 Beta 1 Bundle ...)

2003-08-14 Thread Bruce Momjian
It compiles, but does not link because of the missing fork/exec and signals. --- The Hermit Hacker wrote: > On Wed, 6 Aug 2003, Robert Treat wrote: > > > depends on what you mean by any. I believe that the standard tarball

[GENERAL] locale and encoding

2003-08-14 Thread Kathy zhu
Hi all, What are the relationship/dependencies between encoding and locale settings ?? thanks, kathy ---(end of broadcast)--- TIP 8: explain analyze is your friend

Re: [GENERAL] like performance w/o wildcards.

2003-08-14 Thread scott.marlowe
On Mon, 4 Aug 2003, Joseph Shraibman wrote: > Tom Lane wrote: > > Joseph Shraibman <[EMAIL PROTECTED]> writes: > > > >>What percentage of locales have this problem? Does latin1 have this problem? > > > > > > Latin1 is an encoding, not a locale. To a first approximation, I'd say > > *all* non-

[GENERAL] Could not receive data from server

2003-08-14 Thread Amin Abdulghani
Hi, Running Postgres 7.2.1 with python/psycopg (python interface for postgres using libpq)/webware application server on Solaris, I get a postgres error "could not receive data from server Error 0 " when I try to retrieve a large text column (16 K) from a table. The query I use is "select col

[GENERAL] postmaster(s) have high load average

2003-08-14 Thread Chris Webster
I have one process which writes a single float into 300 columns once per second. I then run 4 process, from remote computers, to query a small subset of the latest row. I have even commented out everything in the query programs, all they do is sleep, and the associated postmaster still sucks u

Re: [GENERAL] One table into two different databases

2003-08-14 Thread Jonathan Gardner
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On Monday 11 August 2003 09:32, Marcelo Soares wrote: > Hi all, > > I would like to know if its possible to have the SAME TABLE into two > different databases (but in the same server). Or to create a view of a > table of database X at the database Y. >

Re: [GENERAL] How to prevent vacuum and reindex from deadlocking.

2003-08-14 Thread Dennis Gearon
Postgres itself doesn't support nested transactions. Robert Creager wrote: On Mon, 11 Aug 2003 11:05:57 -0400 Tom Lane <[EMAIL PROTECTED]> said something like: If you really want to rebuild only the one index, I think this will work: begin; lock table tab; reindex index ndx; commit; Figures.

[GENERAL] Installing DBD::Pg Perl module locally

2003-08-14 Thread Envex Developments
Hey guys, I have a need to install the DBD::Pg Perl module on many shared web servers, which do not have PostgreSQL installed. Then the DBD::Pg module will just connect to a remote PostgreSQL database, hosted elsewhere. I'm having some problems doing this. First off, I modified the Makefile.PL

Re: [GENERAL] INSERT RULE QUERY ORDER

2003-08-14 Thread Tom Lane
Justin Tocci <[EMAIL PROTECTED]> writes: > Thanks for the reply Tom, here's the rule that works: > CREATE RULE tquotehistory_update AS ON UPDATE TO vtquotehistory DO INSTEAD > ( > INSERT INTO tquotehistory_log ("ID", "Item", "Quote1", "DemandCost1", > "Quote2", "DemandCost2", "DueDate", "POIntoI

[GENERAL] Column number 4 is out of range 0..3 ?

2003-08-14 Thread Bjorn T Johansen
I just got this message for all the records returned by "select * from table", what does this mean? (I don't have any restriction on the values in column 4...) Regards, BTJ --- Bjørn T Johansen (BSc,MNIF

Re: [GENERAL] Continued mail server problems for all PGSQL mailing

2003-08-14 Thread Martijn van Oosterhout
On Sat, Aug 09, 2003 at 08:05:58PM -0300, The Hermit Hacker wrote: > On Sat, 9 Aug 2003, Phil Howard wrote: > > Then is 207.173.200.206 a spammer running Sendmail and faking these mailing > > lists? > > My first guess is that the machine we are using @ CommandPrompt as a relay > point has multiple

Re: [GENERAL] Sorting Problem

2003-08-14 Thread Dennis Gearon
Danke, Spacibo, gracias, thanks. Tom Lane wrote: Dennis Gearon <[EMAIL PROTECTED]> writes: You mean in his own local environment? So all his programs, console operations, etc, will have the new encoding? Or 'LANG/LC_ALL' for Posgres specifically? I mean he needs to run initdb with C as the sel

Re: [GENERAL] multiple insert into's (may be NEWBIE question)

2003-08-14 Thread Williams, Travis L, NPONS
Didn't know if it would be any faster.. Travis -Original Message- From: Ron Johnson [mailto:[EMAIL PROTECTED] Sent: Tuesday, August 05, 2003 3:00 PM To: PgSQL General ML Subject: Re: [GENERAL] multiple insert into's (may be NEWBIE question) On Tue, 2003-08-05 at 14:42, Stephan Szabo wro

Re: [GENERAL] OT: Address Fields

2003-08-14 Thread 2trax
On Thu, 31 Jul 2003 11:19:25 +0100, David W Noon wrote: > On Thursday 31 Jul 2003 10:39 in > <[EMAIL PROTECTED]>, 2trax > ([EMAIL PROTECTED]) wrote: > >> It seems to me that the most flexible way is to use a text field to hold >> everything, apart from the country which suits a varchar? and perha

Re: [GENERAL] XML?

2003-08-14 Thread Jonathan Bartlett
What would be really cool (although a lot harder to implement) would be the ability to generate a hierarchical XML document when using foreign key relationships. Trying to tell PG how to format that might be a bit of an issue, though. Jon On Thu, 7 Aug 2003, Gavin M. Roy wrote: > Add an > ech

[GENERAL] public key functions for postgresql ?

2003-08-14 Thread Gianni Mariani
I need to store some sensitive data and I want to use public keys so anyone can encrypt the data but can only be decrupted by certain users. Anyhow, are there any loadable modules that do public key encryption for Postgresql ? I'd like to access these functions in plpgsql. It's probably not th

Re: [GENERAL] PostGreSQL - Accessing It

2003-08-14 Thread Thomas Beutin
On Wed, Aug 13, 2003 at 01:34:00AM +, Mel Roman wrote: > I have the same problem as Michael. I've installed postgresql and am > running the service, but I can't log in as postgres. I just tried the > command line "psql -U postgres template1", but I get the message > "authentication failed for

Re: [GENERAL] postmaster(s) have high load average

2003-08-14 Thread Martijn van Oosterhout
On Sat, Aug 09, 2003 at 05:45:59PM -0300, Claudio Lapidus wrote: > > Run VACUUM VERBOSE on it; you'll no doubt see that some internal > > tables such as pg_activity, pg_statistic, and such have a lot of dead > > tuples. Establishing a connection leads to _some_ DB activity, and > > probably a dead

Re: [GENERAL] Sorting Problem

2003-08-14 Thread Jeffrey Melloy
It does if you look at the original email. Maksim must've just transposed a couple letters when he was writing his demo. Jeff Kathy zhu wrote: If it skips "-", then RMT-* should come before RM-V*, but they don't, why ?? Maksim Likharev wrote: en_US locale skips? punctuation from sorting in

Re: [GENERAL] Update of foreign key values

2003-08-14 Thread Stephan Szabo
On Tue, 12 Aug 2003, Roderick A. Anderson wrote: > On Mon, 11 Aug 2003, Stephan Szabo wrote: > > > Yes. Either DEFERRABLE or INITIALLY DEFERRED must be given in order for > > set constraints to be meaningful. This might be another good place to > > consider a little clarification (or maybe a doc n

Re: [GENERAL] Trying to create a GiST index in 7.3

2003-08-14 Thread Tom Lane
Dmitry Tkach <[EMAIL PROTECTED]> writes: > I am trying to create a custom GiST index in 7.3, but getting an error, > ... > I have done all the setup that was required in 7.2.4: You should not be using the 7.2 methods anymore --- there is a CREATE OPERATOR CLASS, use that instead. (See the contri

Re: [GENERAL] unexpected chunk number

2003-08-14 Thread Tom Lane
"Eric Anderson Vianet SAO" <[EMAIL PROTECTED]> writes: > pg_dump: dumping out the contents of table tbdmovimento > pg_dump: ERROR: unexpected chunk number 8 (expected 0) for toast value 6935= > 693 Hm. Could we see the results of select chunk_seq,length(chunk_data) from where chunk_id = 6935693

Re: [GENERAL] PL/C functions

2003-08-14 Thread Joe Conway
Tom Lane wrote: 1. There is no provision for a single pg_proc entry to have a variable number of arguments. 2. You can make multiple pg_proc entries referencing the same C function. The C function can find out how many arguments it was actually passed (use PG_NARGS()). So you could make several di

Re: [GENERAL] Continued mail server problems for all PGSQL mailing

2003-08-14 Thread The Hermit Hacker
On Sat, 9 Aug 2003, Phil Howard wrote: > | %nslookup 207.173.200.143 > | Server: neptune.hub.org > | Address: 64.117.224.130 > | > | Name:hosting.commandprompt.com > | Address: 207.173.200.143 > | > | Joshua, are there multiple IPs on that box that he might be seeing? > > Then is 207.173.20

  1   2   >