Re: [GENERAL] Chained slaves smaller?

2017-06-23 Thread Jon Erdman
Nevermind. Turns out it was on the wrong timeline and replication was broken. It was smaller because it was 77 days behind. (facepalm) > On Jun 23, 2017, at 2:40 PM, Jon Erdman wrote: > > Hi, > > I have SR set up in a couple of datacenters, where there’s a master in DC_A >

[GENERAL] Chained slaves smaller?

2017-06-23 Thread Jon Erdman
to me since I thought SR replicas are bit for bit copies, so I’m somewhat concerned. Any ideas how this could be? — Jon Erdman Postgres Zealot -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql

Re: [GENERAL] Shared WAL archive between master and standby: WALs not always identical

2017-02-28 Thread Jon Nelson
the master and from a standby have different contents? It surprises me. I would love to know if the differences are due to some oversight in the WAL archiving mechanism chosen by the OP or if, in fact, a master and a standby generate different WAL files! What does pg_xlogdump say about the differences in the files? -- Jon

Re: [GENERAL] Using the database to validate data

2015-07-25 Thread Jon Lapham
o validate data integrity *before* putting it into the database. If there is a problem with any part of the data, I don't want any of it in the database. -Jon -- -**-*-*---*-*---*-*---*-*-*-*---*-*---*-*-*-*-*--- Jon Lapham Rio de Janeiro, Brasil

Re: [GENERAL] Incomplete startup packet help needed

2014-11-06 Thread Jon Erdman
is because many of them just test to see if something is listening on the port, without opening a proper postgres connection (i.e. telnet localhost 5432). The just connect to the port then disconnect without sending any data of any kind. -- Jon Erdman (aka StuckMojo) PostgreSQL Zealot pgpgN7OK4rPmE.pgp Description: PGP signature

[GENERAL] PLV8 and JS exports / referencing

2014-11-05 Thread Jon Erdman
So, I was trying to use mustache.js in PG by defining a V8 function that imports it. Older versions worked fine, but in newer versions they use a class factory and I can't figure out how to reference the mustache stuff that it creates. Apparently I need to know how our V8 implementation does ex

Re: [GENERAL] Joining on CTE is unusually slow?

2014-08-04 Thread Jon Rosebaugh
On Mon, Aug 4, 2014, at 06:40 PM, Jon Rosebaugh wrote: > On Tue, Jul 29, 2014, at 05:38 PM, David G Johnston wrote: > > You should at least provide some explain a/o explain analyse results. > > > > Not to sound pedantic here but you are not JOINing on the CTE, you are >

Re: [GENERAL] Joining on CTE is unusually slow?

2014-08-04 Thread Jon Rosebaugh
On Tue, Jul 29, 2014, at 05:38 PM, David G Johnston wrote: > You should at least provide some explain a/o explain analyse results. > > Not to sound pedantic here but you are not JOINing on the CTE, you are > pushing it into WHERE clause via a pair of sub-selects. Fair criticisms. Okay, here we go

[GENERAL] Joining on CTE is unusually slow?

2014-07-29 Thread Jon Rosebaugh
I have a CTE that produces some row ids. I want to do a query with a complicated join based on those row ids. I've tried running them split into two (run CTE query, collect row ids, then run the complicated query with id IN (id_1, id_2, id_3)) and it takes only a few seconds to run, but when I run

Re: [GENERAL] Why does PostgreSQL ftruncate before unlink?

2014-02-24 Thread Jon Nelson
On Sun, Feb 23, 2014 at 10:07 PM, Tom Lane wrote: > Jon Nelson writes: >> On Sun, Feb 23, 2014 at 9:49 PM, Tom Lane wrote: >>> If memory serves, the inode should get removed during the next checkpoint. > >> I was moments away from commenting to say that I had traced

Re: [GENERAL] Why does PostgreSQL ftruncate before unlink?

2014-02-23 Thread Jon Nelson
to solve the underlying issue without relying on ftruncate (which seems to be somewhat expensive). -- Jon -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-general

[GENERAL] Why does PostgreSQL ftruncate before unlink?

2014-02-21 Thread Jon Nelson
When dropping lots of tables, I noticed postgresql taking longer than I would have expected. strace seems to report that the largest contributor is the ftruncate and not the unlink. I'm curious what the logic is behind using ftruncate before unlink. I'm using an ext4 filesystem

[GENERAL] Re: After dump/restoring from 32bit 8.4-windows to 64bit 9.2.4-linux experiencing 10x slowdown on queries

2013-12-19 Thread jon@stylesage
Hi, did you find a resolution to this issue? I'm running into the same problem now! -- View this message in context: http://postgresql.1045698.n5.nabble.com/After-dump-restoring-from-32bit-8-4-windows-to-64bit-9-2-4-linux-experiencing-10x-slowdown-on-queries-tp5751526p5784087.html Sent from the

Re: [GENERAL] Normal errors codes in serializable transactions

2013-05-09 Thread Jon Smark
Thank you very much for the prompt and informative reply! That clears up my doubt.  For future reference: both 40001 and 40P01 are "normal" errors when issuing SERIALIZABLE transactions in a concurrent setting... Best, Jon -- Sent via pgsql-general mailing list (pgsql-general@postgresq

Re: [GENERAL] Normal errors codes in serializable transactions

2013-05-09 Thread Jon Smark
Hi, > 40P01 is mentioned in the manual. See "A. PostgreSQL Error Codes" of > Appendixes. I meant "mentioned in the manual in the section about concurrency control". Since I alluded to class 40 errors, I think it was safe to assume that I was familiar with Appendix A

[GENERAL] Normal errors codes in serializable transactions

2013-05-08 Thread Jon Smark
27;s reasonable for the client to retry) when issuing SERIALIZABLE transactions, and which ones (within the scope of class 40, of course) are to be considered real errors? Thanks in advance! Best, Jon -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to you

[GENERAL] Best approach for query with optional constraints

2013-01-27 Thread Jon Smark
And if not, from which solution should I expect better results when a) there are no constraints, b) there are only user constraints, c) there are only tag constraints, and d) there are both user and tag constraints? Thank you in advance for any light you might be able to shed! Best, Jon P.S. Oth

[GENERAL] replicate or multi-master for 9.1 or 9.2

2012-09-27 Thread Jon Hancock
California db? 3 - Would trying this on 9.2 be a better place to start? I don't think there is any reason we couldn't migrate up at this point. Although I've used pg for quite a few years, this is my first trip in replication land…any advice would be appreciated. thanks -- Jon Hancock

Re: [GENERAL] Fetching multiple rows in single round trip

2012-05-18 Thread Jon Smark
u are going to be filtering one. Thanks for the reply.  The number of widgets is variable, but should not be higher than about 20 in the worst case, with 10 being a more average number.  Which solution should I opt for in these circumstances? Cheers, Jon -- Sent via pgsql-general mailing list (pgsql-

[GENERAL] Fetching multiple rows in single round trip

2012-05-18 Thread Jon Smark
performance difference for PostgreSQL between solutions 1 and 2? (Solution  1 seems more efficient, though solution 2 is actually a better fit for the client-side bindings I'm using). Thanks in advance! Jon -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make c

Re: [GENERAL] views, queries, and locks

2012-04-04 Thread Jon Nelson
On Wed, Apr 4, 2012 at 12:51 PM, Thomas Kellerer wrote: > Jon Nelson wrote on 04.04.2012 19:47: > >>> What about a set-returning function that builds the query dynamically and >>> wrapping that into a view? >>> >>> That way the view would ne

Re: [GENERAL] views, queries, and locks

2012-04-04 Thread Jon Nelson
On Wed, Apr 4, 2012 at 11:22 AM, Thomas Kellerer wrote: > Jon Nelson wrote on 04.04.2012 15:50: > >> I need to have something table-like from the client's perspective for >> a bunch of reasons. >> For now, assume that I want to keep using the view and that I

Re: [GENERAL] views, queries, and locks

2012-04-04 Thread Jon Nelson
On Wed, Apr 4, 2012 at 10:43 AM, Tom Lane wrote: > Jon Nelson writes: >> On Wed, Apr 4, 2012 at 9:01 AM, Tom Lane wrote: >>> Why aren't you using a standard partitioned table, cf >>> http://www.postgresql.org/docs/9.1/static/ddl-partitioning.html > >> Be

Re: [GENERAL] views, queries, and locks

2012-04-04 Thread Jon Nelson
ave to be held after the query rewrite takes place" (since views are little more than rules?). -- Jon -- 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] views, queries, and locks

2012-04-04 Thread Jon Nelson
On Tue, Apr 3, 2012 at 8:58 PM, Scott Marlowe wrote: > On Tue, Apr 3, 2012 at 7:21 PM, Jon Nelson wrote: >> On Tue, Apr 3, 2012 at 2:45 PM, Thomas Kellerer wrote: >>> Jon Nelson wrote on 03.04.2012 20:41: >>> >>>> Close, but not quite. It's not rot

Re: [GENERAL] views, queries, and locks

2012-04-03 Thread Jon Nelson
On Tue, Apr 3, 2012 at 2:45 PM, Thomas Kellerer wrote: > Jon Nelson wrote on 03.04.2012 20:41: > >> Close, but not quite. It's not rotation but every N minutes a >> newly-built table appears. I'd like that table to appear as part of >> the view as soon as p

Re: [GENERAL] views, queries, and locks

2012-04-03 Thread Jon Nelson
On Tue, Apr 3, 2012 at 1:36 PM, Merlin Moncure wrote: > On Tue, Apr 3, 2012 at 12:30 PM, Jon Nelson wrote: >> On Tue, Apr 3, 2012 at 12:16 PM, Merlin Moncure wrote: >>> On Tue, Apr 3, 2012 at 12:01 PM, Jon Nelson >>> wrote: >>>> I have a situation that I

Re: [GENERAL] views, queries, and locks

2012-04-03 Thread Jon Nelson
On Tue, Apr 3, 2012 at 12:16 PM, Merlin Moncure wrote: > On Tue, Apr 3, 2012 at 12:01 PM, Jon Nelson wrote: >> I have a situation that I'd like some help resolving. >> Using PostgreSQL 8.4. on Linux, I have three things >> coming together that cause me pain. I have

[GENERAL] views, queries, and locks

2012-04-03 Thread Jon Nelson
E VIEW (by canceling the query) after a short duration, but is there a better way? -- Jon -- 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] what Linux to run

2012-03-03 Thread Jon Nelson
fferings and generally prefer them. openSUSE has an 8 month release cycle and as a consequence I'm rarely too far behind the latest _stable_ release, while still being able to run the last-most-recent stable release for, I think, 3 years. If I want more, that's what the commercial offerings are for. -- Jon -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-general

[GENERAL] Let-bindings in SQL statements

2012-01-26 Thread Jon Smark
t;= start AND ... In PL/pgSQL this is easy, but I wonder about SQL... Thanks in advance! Jon -- 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] Duplicated entries are not ignored even if a "do instead nothing" rule is added.

2012-01-08 Thread Jon Nelson
distinct. insert into ... select DISTINCT where not exists. -- Jon -- 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] bytea columns and large values

2011-09-29 Thread Jon Nelson
/docs/8.4/static/storage-toast.html -- Jon -- 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] bytea columns and large values

2011-09-29 Thread Jon Nelson
ething worth of usage. I'm not saying that placing such large values in a table (or LO) is a good idea, but - if I had managed to put data *in* to a table that I couldn't get back out, I'd be a bit cranky, especially if my attempt to do so kills the backend I am using (which triggers

Re: [GENERAL] \d+ not showing TOAST table size?

2011-09-20 Thread Jon Nelson
On Tue, Sep 20, 2011 at 2:09 PM, Josh Kupershmidt wrote: > On Tue, Sep 20, 2011 at 1:26 PM, Jon Nelson wrote: >> I have a table with a fair bit of TOAST data in it. >> I noticed that \d+ does /not/ include that information (but >> pg_total_relation_size does). > >

[GENERAL] \d+ not showing TOAST table size?

2011-09-20 Thread Jon Nelson
f the data is in TOAST then the *real* data stored is much more than displayed. -- Jon -- 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] Alarm function in PL/pgSQL

2011-07-18 Thread Jon Smark
called with a given periodicity must be so from *outside* PG, ie, from the client application, right? I mean, there is no way strictly internal to PG to have a function be called every given number of seconds? Cheers, Jon -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) T

[GENERAL] Alarm function in PL/pgSQL

2011-07-18 Thread Jon Smark
te" column of a given table row to "temporary". After a predefined period (say, one hour), function BAR should then automatically be invoked; this latter function would among other things change the "state" column to "permanent". Thanks in advance! Jon --

[GENERAL] Converting an hstore into a key/value record

2011-06-04 Thread Jon Smark
gSQL to do this task, but I suspect there must be some much simpler SQL statement that does the same... Thanks in advance! Jon -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-general

[GENERAL] Short-circuit boolean evaluation

2011-04-30 Thread Jon Smark
d = $1) is false? SELECT count(*) FROM foobar WHERE foobar.id = $1 AND do_stuff (foobar.name); Thanks! Jon -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-general

[GENERAL] Functions as first-class values

2011-04-06 Thread Jon Smark
thoughts? Thanks in advance! Jon CREATE FUNCTION f1 (int) RETURNS boolean ... CREATE FUNCTION f2 (int) RETURNS boolean ... CREATE FUNCTION f3 (int) RETURNS boolean ... CREATE FUNCTION do_stuff ... BEGIN CASE cond WHEN 'a' THEN func := f1; WHE

Re: [GENERAL] postgres conferences missing videos?

2011-03-21 Thread Jon Nelson
to be done, > and its all quite time consuming. Somebody ought to talk to the folks that run PyCon - the videos there are excellent and typically available within hours or less. Perhaps they have some useful insight or advice? -- Jon -- Sent via pgsql-general mailing list (pgsql-gener

[GENERAL] Passing a table as parameter

2011-03-21 Thread Jon Smark
function parameterised on the id and table. Is this possible? Thanks in advance! Jon CREATE TABLE data1 (id int4, content text); CREATE TABLE data2 (id int8, content text); CREATE FUNCTION get_from_data1 (int4) RETURNS SETOF text LANGUAGE sql STABLE AS $$ SELECT content FROM data1 WHERE id

[GENERAL] regarding ROW comparisons

2011-03-06 Thread Jon Nelson
TEXT, sometimes INET). There are indexes on tableA but not on table B. I am using postgresql 8.4.5 and I have tried on both CentOS and openSUSE with the same results. -- Jon -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription: http://www.pos

Re: [GENERAL] Using Bitmap scan instead of Seq scan

2011-02-14 Thread Jon Nelson
Does this suggest that the config items "disable_seqscan" (and friends) should be renamed to "avoid_seqscan" ? -- Jon

Re: [GENERAL] varchar (no 'N') vs. text

2011-02-04 Thread Jon Nelson
On Fri, Feb 4, 2011 at 1:18 PM, Tom Lane wrote: > Jon Nelson writes: >> I thought 'character varying' (aka varchar) sans length was an alias >> for text. Is it not? > > It has the same behavior, but it is a distinct type, so dummy coercions > are needed. Are

[GENERAL] varchar (no 'N') vs. text

2011-02-04 Thread Jon Nelson
like this: Merge Cond: (a.t = (b.v)::text) I thought 'character varying' (aka varchar) sans length was an alias for text. Is it not? -- Jon -- 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] resizing a varchar column on 8.3.8

2011-01-27 Thread Jon Hoffman
This was originally discussed on this list here: http://postgresql.1045698.n5.nabble.com/Smartest-way-to-resize-a-column-td1915892.html Tom Lane suggested doing the resize in a BEGIN block at least to verify that "\d tablename" reflects the catalog update. - Jon On Thu, Jan 27, 2011

Re: [GENERAL] resizing a varchar column on 8.3.8

2011-01-27 Thread Jon Hoffman
Hi, I was able to do this without any issues, though I don't have any views. - Jon On Thu, Jan 27, 2011 at 9:52 AM, Emi Lu wrote: > On 01/15/2011 04:22 PM, Jon Hoffman wrote: > >> Hi, >> >> I found a post with some instructions for resizing without locking up &g

Re: [GENERAL] Record with a field consisting of table rows

2011-01-16 Thread Jon Smark
'name', and 'age'; 'page_t' is defined as a tuple consisting of an integer and a list of 'user_t'). Moreover, we've already established that PL/pgSQL also allows the return of a tuple consisting of an integer and an array of tuples. All I wanted was to

[GENERAL] resizing a varchar column on 8.3.8

2011-01-15 Thread Jon Hoffman
on existing rows? The table has around 6MM rows and is very heavily queried. I'm also using skytools londiste for replication, so I assume that I would run the resize on the subscriber first. Thanks for help, Jon

Re: [GENERAL] Record with a field consisting of table rows

2011-01-15 Thread Jon Smark
on to loop > through the refcursor to fetch the results, but you would > sort of get what you apparently want. I can't see why you'd > want that though. Yes, the alternatives are indeed more cumbersome than they're worth. I might as well split the original function into

Re: [GENERAL] Record with a field consisting of table rows

2011-01-15 Thread Jon Smark
I still haven't found a solution to the original problem. The best I can do so far is to create a function that returns a tuple consisting of an int and the first row of table results (see below). Any more thoughts? Best regards, Jon create table users ( uid

Re: [GENERAL] Record with a field consisting of table rows

2011-01-14 Thread Jon Smark
! Jon -- 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] Record with a field consisting of table rows

2011-01-13 Thread Jon Smark
ect users from users limit 10); The above does work, thanks. There is however one drawback: the type associated with _page.users is now an array. Is there a way to make it a 'SETOF user_t'? Best regards, Jon -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org)

[GENERAL] Record with a field consisting of table rows

2011-01-13 Thread Jon Smark
s not work (see function 'get_page') below. Am I missing something obvious here? Thanks in advance! Jon create table users ( uid int4 not null, nametext not null, age int4 not null, primary key (uid) ); create type user_t AS

Re: [GENERAL] ERROR: could not open relation base/2757655/6930168: No such file or directory -- during warm standby setup

2010-12-31 Thread Jon Nelson
t the day. We're going to try again > overnight when those tables are not truncated and see if that gives us > a correctly-working standby. > > From what I could find from posts to these lists, TRUNCATE commands do > reset the relfilenode, and that could account for the issue we are > ex

Re: [GENERAL] How to obtain the maximum value of a date, between 3 tables...

2010-12-08 Thread Jon Nelson
3 If you don't need to know which table it came from I would probably try select a.last_refresh_date as d1, NULL as d2, NULL as d3 FROM tbl1 as a UNION ALL ... -- Jon -- 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] dotted quad netmask conversion

2010-12-07 Thread Jon Nelson
('1.2.3.4' AS INET) & CAST('255.255.128.0' AS INET); Be aware that CIDR representation is not as granular as netmask. http://www.postgresql.org/docs/8.4/interactive/functions-net.html -- Jon -- 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] Regarding EXPLAIN and width calculations

2010-11-19 Thread Jon Nelson
On Fri, Nov 19, 2010 at 1:09 PM, Tom Lane wrote: > Jon Nelson writes: >> On Fri, Nov 19, 2010 at 12:14 PM, Tom Lane wrote: >>> Hard to comment about this with such an incomplete view of the situation >>> --- in particular, data types would be a critical factor, and

Re: [GENERAL] Regarding EXPLAIN and width calculations

2010-11-19 Thread Jon Nelson
On Fri, Nov 19, 2010 at 12:14 PM, Tom Lane wrote: > Jon Nelson writes: >> What influences the calculation of the 'width' value in query plans? > > It's generally the sum of the estimated column widths for all the > columns needed at that particular level of th

[GENERAL] Regarding EXPLAIN and width calculations

2010-11-19 Thread Jon Nelson
nd (11). What's going on there? Why did the UNION ALL Append operation get a rather larger (more than 3x) row width when, at that state of the query execution, the contents should be identical to the UNION variation? Why did the row count go to 200? -- Jon -- Sent via pgsql-general mailing

[GENERAL] plpgsql question

2010-08-27 Thread Jon Griffin
I am trying to calculate a value from a current record in a query and can't seem to get it working. Here is the shortened query; SELECT s.id, r.the_date_time, s.open_price, s.high_price, s.low_price, s.close_price, thesheet_onepair.symbol, r.buy_l

Re: [GENERAL] Piping CSV data to psql when executing COPY .. FROM STDIN (Solved)

2008-10-30 Thread Roberts, Jon
r but it is easier to maintain and looks to be more secure. Jon -- 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] Oracle and Postgresql

2008-09-16 Thread Roberts, Jon
asn't kidding up there. Setting view permissions on plpgsql (or > any pl code really) would be understandable. If you're not a super > user or the owner, you need permission to see it. > How can I make that a feature request? Jon -- Sent via pgsql-general mailing

Re: [GENERAL] Oracle and Postgresql

2008-09-04 Thread Roberts, Jon
That said, there's not the same sense of community when it comes to > Oracle. And how many of you have ever asked a question and had it > answered by the Oracle equivalent of Tom Lane? I have. http://asktom.oracle.com But I've had better luck with Tom. :) Jon -- Sen

Re: [GENERAL] plpgsql returning resultset

2008-09-02 Thread Roberts, Jon
/ecpg-dynamic.html Jon > -Original Message- > From: [EMAIL PROTECTED] [mailto:pgsql-general- > [EMAIL PROTECTED] On Behalf Of Thomas Finneid > Sent: Tuesday, September 02, 2008 4:19 PM > To: pgsql-general@postgresql.org > Cc: [EMAIL PROTECTED] > Subject: Re: [GENERAL] p

Re: [GENERAL] Foreign Key normalization question

2008-09-02 Thread Roberts, Jon
, location_id int references location (id) ); Jon > -Original Message- > From: [EMAIL PROTECTED] [mailto:pgsql-general- > [EMAIL PROTECTED] On Behalf Of Matthew Wilson > Sent: Tuesday, September 02, 2008 3:35 PM > To: pgsql-general@postgresql.org > Subject: Re: [GENERAL] Foreign

Re: [GENERAL] temp schemas

2008-08-29 Thread Roberts, Jon
> On Fri, Aug 29, 2008 at 1:40 PM, Roberts, Jon <[EMAIL PROTECTED]> > wrote: > > >> Why have you got thousands of them? If you are running with thousands > >> of active backends, may I suggest a connection pooler? > >> > > > > I don&#x

Re: [GENERAL] temp schemas

2008-08-29 Thread Roberts, Jon
> -Original Message- > > "Roberts, Jon" <[EMAIL PROTECTED]> writes: > > I am noticing a large number of temp schemas in my database. We use > > temp tables but it doesn't appear that the schemas get dropped for some > > reason. > >

[GENERAL] temp schemas

2008-08-28 Thread Roberts, Jon
on commit" and see that the tables are gone after the transaction is complete. Any ideas why we have so many temp schemas? Is it safe to just drop them all? Jon -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription: http://www.postgres

Re: [GENERAL] Howto disable login?

2008-08-04 Thread Roberts, Jon
it to: host all all 0.0.0.0/0 md5 Jon From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Teemu Juntunen Sent: Monday, August 04, 2008 12:20 PM To: PostgreSQL Subject: [GENERAL] Howto disable login? Hi all, is there some way to

Re: [GENERAL] Substitute a variable in PL/PGSQL.

2008-07-25 Thread Roberts, Jon
coalesce(col3, '') || coalesce(col4, '') || coalesce(col5, '') || coalesce(col6, '') || coalesce(col7, '') || coalesce(col8, '') || coalesce(col9, '') || coalesce(col10, '') as col_data from test) t on t2.col_data = t.col_data where t.col_data is null Jon -- 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] Default fill factor for tables?

2008-07-16 Thread Roberts, Jon
E.HOT > I'm using 8.3.1 on Solaris and I just tried this: CREATE TABLE test (a int) WITH (hot_update='true'); It fails with: ERROR: unrecognized parameter "hot_update" Is a hot update automatic in 8.3.x and that is why there isn't any formal documentation other than wha

Re: [GENERAL] Default fill factor for tables?

2008-07-11 Thread Roberts, Jon
> Roberts, Jon escribió: > > > Why would you set the fillfactor to anything other than 100 for a > > PostgreSQL table? > > To favor HOT updates. > > -- I can find very little information on hot updates but I found this: http://archives.postgresql.org/pgsql-pa

Re: [GENERAL] Default fill factor for tables?

2008-07-11 Thread Roberts, Jon
lfactor to anything other than 100 for a PostgreSQL table? http://www.postgresql.org/docs/8.3/static/routine-vacuuming.html I thought an updated record always got a new row in a table. Setting a lower fillfactor for a table suggests that PostgreSQL behaves like Oracle in terms of filling blocks up and having c

Re: [GENERAL] pg crashing

2008-07-08 Thread Roberts, Jon
> Roberts, Jon wrote: > >> Not having looked at the internals of db_link, I'd say it's certainly > >> possible that this is the reason for the failed restart. If db_link is > >> blocking something, the postmaster can't kill it off, and it'll stil

Re: [GENERAL] pg crashing

2008-07-02 Thread Roberts, Jon
he shared memory segment. > > That said, it shouldn't be the reason why it's crashing in the first > place - just the reason why it won't restart properly. > Is this a problem in Unix? We are about 1 - 2 weeks away from moving this database to Solaris. Jon -- Sen

Re: [GENERAL] pg crashing

2008-07-02 Thread Roberts, Jon
> Roberts, Jon wrote: > >> Tom Lane wrote: > >>> "Roberts, Jon" <[EMAIL PROTECTED]> writes: > >>>> Version: "PostgreSQL 8.3.0, compiled by Visual C++ build 1400" > >>> Well, there are plenty of known bugs in 8.3.0 by now.

Re: [GENERAL] pg crashing

2008-07-02 Thread Roberts, Jon
e a running syslogger (and maybe others) > > processes, just no postmaster? > > Not great, maybe, but what it looks to me is that the current system > guarantees that a postmaster with a syslogger child will never recover > from a backend-child crash. That's not better. >

Re: [GENERAL] pg crashing

2008-07-02 Thread Roberts, Jon
> Tom Lane wrote: > > "Roberts, Jon" <[EMAIL PROTECTED]> writes: > >> Version: "PostgreSQL 8.3.0, compiled by Visual C++ build 1400" > > > > Well, there are plenty of known bugs in 8.3.0 by now. You really > > should update before

Re: [GENERAL] pg crashing

2008-07-02 Thread Roberts, Jon
> "Roberts, Jon" <[EMAIL PROTECTED]> writes: > > Version: "PostgreSQL 8.3.0, compiled by Visual C++ build 1400" > > Well, there are plenty of known bugs in 8.3.0 by now. You really > should update before complaining, not after. I'm not complai

Re: [GENERAL] simple tool for building web forms

2008-07-02 Thread Roberts, Jon
http://www.sqlmaestro.com/products/postgresql/ I've used the PHP Code Generator with great success for simple stuff like you describe. You could then write a function to do email notifications or whatever you want. Jon > -Original Message- > From: [EMAIL PROTECTED] [m

[GENERAL] pg crashing

2008-07-01 Thread Roberts, Jon
8-07-01 10:46:31 CDT HINT: Check if there are any old server processes still running, and terminate them. Is this problem fixed in 8.3.3 and/or fixed by moving to a Unix environment like Solaris? Jon -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make chang

Re: [GENERAL] Data Types

2008-06-23 Thread Roberts, Jon
and text values. Jon From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Mike Gould Sent: Monday, June 23, 2008 1:01 PM To: pgsql-general General Subject: [GENERAL] Data Types We are converting our system from using Sybase'

[GENERAL] "connect by"

2008-06-09 Thread Roberts, Jon
I need a high performing version of Oracle's connect by functionality in PostgreSQL. I saw some dispute about attempts to add this in the archives and a reference to an ANSI alternative "with" statement. Is either of these functions available yet? I'm using 8.3. Jon

Re: [GENERAL] when to reindex?

2008-06-06 Thread Roberts, Jon
> On Fri, Jun 6, 2008 at 9:36 AM, Roberts, Jon <[EMAIL PROTECTED]> > wrote: > > In Oracle, there is a method to determine when it is advisable to > > rebuild indexes. Are there any guidelines for this in PostgreSQL? > > > > I found this but it doesn't i

[GENERAL] when to reindex?

2008-06-06 Thread Roberts, Jon
utine-reindex.html Jon -- 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] does postgresql works on distributed systems?

2008-06-04 Thread Roberts, Jon
> -Original Message- > From: [EMAIL PROTECTED] [mailto:pgsql-general- > [EMAIL PROTECTED] On Behalf Of Guy Rouillier > Sent: Wednesday, June 04, 2008 1:33 AM > To: pgsql-general@postgresql.org > Subject: Re: [GENERAL] does postgresql works on distributed systems? >

Re: [GENERAL] does postgresql works on distributed systems?

2008-06-03 Thread Roberts, Jon
high-availability.html Greenplum and EnterpriseDB are both based on PostgreSQL and use a shared nothing architecture to achieve and active-active system. Jon -- 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] Mediawiki 1.10 and PG 8.3 upgrade

2008-05-30 Thread Jon Lapham
Tom Lane wrote: Jon Lapham <[EMAIL PROTECTED]> writes: Have I (very possible) missed some official PostgreSQL instructions? http://www.postgresql.org/docs/8.3/static/textsearch-migration.html http://www.postgresql.org/docs/8.3/static/tsearch2.html I haven't personally tried tha

Re: [GENERAL] Mediawiki 1.10 and PG 8.3 upgrade

2008-05-30 Thread Jon Lapham
Joshua D. Drake wrote: Jon Lapham wrote: How are we, Joe PostgreSQL users on the street, supposed to know which instructions to follow? Have I (very possible) missed some official That would be a question for mediawiki people not PostgreSQL people. Okay, makes sense. It just seemed to me

[GENERAL] Mediawiki 1.10 and PG 8.3 upgrade

2008-05-30 Thread Jon Lapham
ere are others. The one common thread shared by all the instructions are that they say different things. How are we, Joe PostgreSQL users on the street, supposed to know which instructions to follow? Have I (very possible) missed some official PostgreSQL instructions? How do we go about tri

Re: [GENERAL] Copying data from a table to another database

2008-05-25 Thread Roberts, Jon
You can do this with dblink http://www.postgresql.org/docs/8.3/interactive/contrib-dblink.html pretty easily. Jon > -Original Message- > From: [EMAIL PROTECTED] [mailto:pgsql-general- > [EMAIL PROTECTED] On Behalf Of Pedro Doria Meunier > Sent: Sunday, May 25, 2008

Re: [GENERAL] Results of stored procedures in WHERE clause

2008-05-23 Thread Roberts, Jon
ot;foo3" 3;1;"bar" It gets the direct child records and then it also gets the child's child (foo2) and then the child's child's child (foo3). It will go all of the way through the hierarchy too. Jon > -Original Message- > From: [EMAIL PROTECTED] [mailto:

Re: [GENERAL] Finding records that are not there

2008-05-22 Thread Roberts, Jon
er by commcost.maplot; select commcost.maplot, commcost.unitno from commcost except select bldg.maplot, bldg.unitno from bldg order by maplot; Jon > -Original Message- > From: [EMAIL PROTECTED] [mailto:pgsql-general- > [EMAIL PROTECTED] On Behalf Of Owen Hartnett &g

Re: [GENERAL] best er modeling tool for postgreSQL

2008-05-21 Thread Roberts, Jon
Thanks for posting this. I had been using DB Designer 4 which has tons of bugs in it. Power Architect is pretty nice. Jon > -Original Message- > From: [EMAIL PROTECTED] [mailto:pgsql-general- > [EMAIL PROTECTED] On Behalf Of Thomas Kellerer > Sent: Wednesday, May 21, 2008

Re: [GENERAL] SQL window functions

2008-05-04 Thread Roberts, Jon
Greenplum has it. Maybe they are planning on adding it to Bizgres or PostgreSQL. Jon > -Original Message- > From: [EMAIL PROTECTED] [mailto:pgsql-general- > [EMAIL PROTECTED] On Behalf Of Hannes Dorbath > Sent: Sunday, May 04, 2008 8:02 AM > To: pgsql-general@postgresq

Re: [GENERAL] passing a temporary table with more than one column to a stored procedure

2008-04-28 Thread Roberts, Jon
> -Original Message- > From: Viktor Rosenfeld [mailto:[EMAIL PROTECTED] > Sent: Monday, April 28, 2008 4:52 PM > To: Roberts, Jon > Cc: pgsql-general@postgresql.org > Subject: Re: [GENERAL] passing a temporary table with more than one column > to a stored procedure

Re: [GENERAL] passing a temporary table with more than one column to a stored procedure

2008-04-28 Thread Roberts, Jon
UNTION SELECT 20 AS min, 30 AS max, 3 AS text_ref ) AS boundaries JOIN struct ON (struct.text_ref = boundaries.text_ref) JOIN rank ON (rank.struct_ref = struct.id) ) AS graph Jon -- Sent via pgsql-general mailing list (pgsql-general@po

  1   2   3   >