Ralph Smith <[EMAIL PROTECTED]> writes:
> DECLARE
>achar character := '' ;
Use varchar or text. character is weird about trailing spaces.
regards, tom lane
--
Sent via pgsql-general mailing list (pgsql-general@postgresql.org)
To make changes to your subscription:
h
"Charles F. Munat" <[EMAIL PROTECTED]> writes:
> Using pseudocode from Celko's "SQL for Smarties" book, I wrote the
> following function that builds a path enumeration table. I hope to
> trigger this function on the rare occasions that the organizations table
> is updated. But when I run this funct
CODE:
===
CREATE OR REPLACE FUNCTION find_next_delim(invar varchar, delimlist
varchar) RETURNS integer AS
$$
/* OVERLOADED Function. The other version takes a 3rd parameter as
the
starting position in invar.
*/
DECLARE
achar character := '
Hi all,
I'm checking out some features in pgsql and found out about an array
datatype. As I'm curious to find out how well it performs, I've created
a table that contains an integer[] column and a script to insert about
500K rows in it. The length for the integer[] column is random (can be
10, can
Ati Rosselet escribió:
> Using postgresql 8.3 on windows 2003 server. I keep seeing this message in
> my system log. Checking the times, it seems to coincide with a log
> rollover each time, almost as though the db were trying to log something at
> precisely the same time as it is closing access
"Kevin Hunter" <[EMAIL PROTECTED]> writes:
> Or, assuming the REINDEX is for speed/bloat, not for corruption, perhaps
> an option to use the old index as a basis, rather than scanning the
> entire table multiple times as with a CREATE INDEX CONCURRENTLY.
That's been mentioned, it ought to be on t
Roberts, Jon wrote:
Based on this, I have the fillfactor set lower than the default 90 but
this will fill up and it will run slower over time. I want to automate
the reindex process but only reindex when needed. I have a pretty large
database so I can't reindex everything regardless if it need
"Zoltan Boszormenyi" <[EMAIL PROTECTED]> writes:
> Also, VACUUM FULL also takes too much time, on an otherwise idle database, I
> worked on a copy of their live database. During VACUUM, _bt_getbuf() was
> also called repeatedly with the block number jumping up and down.
VACUUM or VACUUM FULL? VA
At 2:02p -0400 on Fri, 06 Jun 2008, Jon Roberts wrote:
> Based on this, I have the fillfactor set lower than the default 90 but
> this will fill up and it will run slower over time. I want to automate
> the reindex process but only reindex when needed. I have a pretty large
> database so I can't
Gary Fu <[EMAIL PROTECTED]> writes:
> Thanks for the response. Yes, normally it will be okay. However, when
> I tried PgAdmin with Pgpool, it will cause problem. The PgAdmin will
> try to access pg_namespace when making a connection to a db, if the
> temporary schemas are different between the b
Sam Mason <[EMAIL PROTECTED]> writes:
> I'm seeing big memory leaks when doing a query like:
> SELECT d.source_loc_id, d.movement_date - '2006-1-1',
> array_to_string(int_array_aggregate(l.source_ls_id),' ') AS livestockids
> FROM movedates d, livestock_locations l
> WHERE l.source_loc_i
> 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 indicate at which point an index should
be
> >
Tom Lane wrote:
Gary Fu <[EMAIL PROTECTED]> writes:
My question now is why those temporary schemas won't be cleaned
after I restart the db ?
Just leave them alone and you'll be fine. These tools actually have
had most of the bugs worked out of them ;-) ... if you think pg_dump is
omitting som
On Thu, 2008-06-05 at 22:28 -0400, Merlin Moncure wrote:
> As others have noted, you have tabs in your sql source. I'd advise if
> possible, not to use the tab character in sql, for this and other
> reasons.
Tabs in SQL are a problem only if you copy-paste. If your editor and
psql can see the s
On Fri, Jun 6, 2008 at 6:12 AM, Merlin Moncure <[EMAIL PROTECTED]> wrote:
> On Fri, Jun 6, 2008 at 12:39 AM, Gurjeet Singh <[EMAIL PROTECTED]> wrote:
>> On Fri, Jun 6, 2008 at 7:58 AM, Merlin Moncure <[EMAIL PROTECTED]> wrote:
>>> As others have noted, you have tabs in your sql source. I'd advise
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 indicate at which point an index should be
> rebuilt other
Alexandr Popov <[EMAIL PROTECTED]> writes:
> CREATE OR REPLACE VIEW v1 AS SELECT DISTINCT a,b, -1 AS d, -1 AS e FROM t1;
> After this i dump database with pg_dump and have following output.
> CREATE VIEW v1 AS
> SELECT DISTINCT t1.a, t1.b, -1 AS d, -1 AS e FROM t1 ORDER BY t1.a, t1.b,
> -1::
Ken Winter wrote:
Thanks, Joshua ~
What you suggest is basically what I'm trying to do. Where I'm stuck is in
finding a construct (a CAST or whatever) to turn the existing "money" column
data (directly or indirectly) into numeric. I've tried to convert a column
named "amount" in the following
On Friday 06 June 2008 8:49 am, Adrian Klaver wrote:
> On Friday 06 June 2008 8:25 am, Ken Winter wrote:
> > Thanks, Joshua ~
> >
> > What you suggest is basically what I'm trying to do. Where I'm stuck is
> > in finding a construct (a CAST or whatever) to turn the existing "money"
> > column data
Thanks Adrian ~ See comments at end.
> -Original Message-
> From: [EMAIL PROTECTED] [mailto:pgsql-general-
> [EMAIL PROTECTED] On Behalf Of Adrian Klaver
> Sent: Friday, June 06, 2008 11:49 AM
> To: pgsql-general@postgresql.org
> Cc: Ken Winter
> Subject: Re: [GENERAL] Extracting data from
On Friday 06 June 2008 8:25 am, Ken Winter wrote:
> Thanks, Joshua ~
>
> What you suggest is basically what I'm trying to do. Where I'm stuck is in
> finding a construct (a CAST or whatever) to turn the existing "money"
> column data (directly or indirectly) into numeric. I've tried to convert a
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 indicate at which point an index should be
rebuilt other than corruption.
http://www.postgresql.org/docs/8.3/interactive/routine-reindex
Thanks, Joshua ~
What you suggest is basically what I'm trying to do. Where I'm stuck is in
finding a construct (a CAST or whatever) to turn the existing "money" column
data (directly or indirectly) into numeric. I've tried to convert a column
named "amount" in the following ways, with the follo
Hi,
I've been using the intagg code to perform aggregations under the
assumption that it's going to be more efficient than the array_accum
documented elsewhere[1].
I'm seeing big memory leaks when doing a query like:
SELECT d.source_loc_id, d.movement_date - '2006-1-1',
array_to_string(int
Hi,
we have a customer with PostgreSQL 8.0.3 with a quite interesting problem.
They have around 24 identical databases and all but one is working nicely.
The one that doesn't work nicely show this problem: INSERT "hangs"
on an apparently empty table where "select count(*)" returns 0 quite
quickly.
On Friday 06 June 2008 2:32 am, Hermann Muster wrote:
> Does no one have any idea about that?
>
> Regards.
>
> Hermann Muster wrote:
> > Hi,
> >
> > I have the following problem when trying to access other PostgreSQL
> > databases with DBLink. I followed the instructions on
> > http://www.postgreso
Hello,
I found small problem and doesn't know where to dig.
Ok let's start.
postgresql 8.2.7
OS - linux
Create table and view.
CREATE TABLE t1 (
a integer NOT NULL,
b integer NOT NULL
);
CREATE OR REPLACE VIEW v1 AS SELECT DISTINCT a,b, -1 AS d, -1 AS e FROM t1;
After this i dump da
On Fri, Jun 6, 2008 at 12:39 AM, Gurjeet Singh <[EMAIL PROTECTED]> wrote:
> On Fri, Jun 6, 2008 at 7:58 AM, Merlin Moncure <[EMAIL PROTECTED]> wrote:
>> As others have noted, you have tabs in your sql source. I'd advise if
>> possible, not to use the tab character in sql, for this and other
>> rea
Hi,
I have a query with the following joins:
annotations2.attribute = 'pos' AND
annotations2.value = 'KOUS' AND
annotations4.span = 'man' AND
annotations6.span = 'sich' AND
annotations2.text_ref = annotations4.text_ref AND
annotations2.right = anno
Tomasz Ostrowski wrote:
On 2008-06-06 07:25, Brent Wood wrote:
Would "real" tables in a tablespace defined on a ramdisk meet this
need?
Bad idea. This would mean an unusable database after a restart.
Funnily, I was thinking the same this night, somehow defining a
tablespace on tmpfs or som
Does no one have any idea about that?
Regards.
Hermann Muster wrote:
Hi,
I have the following problem when trying to access other PostgreSQL
databases with DBLink. I followed the instructions on
http://www.postgresonline.com/journal/index.php?/archives/44-Using-DbLink-to-access-other-Postg
On 2008-06-06 07:25, Brent Wood wrote:
> Would "real" tables in a tablespace defined on a ramdisk meet this
> need?
Bad idea. This would mean an unusable database after a restart.
> You could also mount a tablespace on a physical disk with a
> filesystem which has delayed/deferred writes to disk
On 2008-06-04 23:18, Jason Long wrote:
> I have a query that takes 2.5 sec if I run it from a freshly restored
> dump. If I run a full vacuum on the database it then takes 30 seconds.
1. Don't run "vacuum full", run plain "vacuum". If you run "vacuum full"
then "reindex" afterwards.
2. Run "an
33 matches
Mail list logo