[GENERAL] bug?: permission denied for schema on on delete set null

2009-03-10 Thread Ivan Sergio Borgonovo
) on delete set null, ... ); I'm on PostgreSQL 8.3.6 (Debian Lenny). thanks -- Ivan Sergio Borgonovo http://www.webthatworks.it -- 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] bug?: permission denied for schema on on delete set null

2009-03-10 Thread Ivan Sergio Borgonovo
to the single users -- Ivan Sergio Borgonovo http://www.webthatworks.it -- 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] bug?: permission denied for schema on on delete set null

2009-03-10 Thread Ivan Sergio Borgonovo
On Tue, 10 Mar 2009 13:12:03 -0400 Tom Lane t...@sss.pgh.pa.us wrote: Ivan Sergio Borgonovo m...@webthatworks.it writes: I get a Query failed: ERROR: permission denied for schema user_test CONTEXT: SQL statement UPDATE ONLY user_test.shop_commerce_baskets SET sid = NULL WHERE $1

[GENERAL] in role, ownership and permissions was: grant everything on everything and then revoke

2009-03-09 Thread Ivan Sergio Borgonovo
On Tue, 03 Mar 2009 09:29:17 -0800 John R Pierce pie...@hogranch.com wrote: Ivan Sergio Borgonovo wrote: I'd like to have different users mainly to have a different search schema path. Things may evolve so this is not going to be the only reason to have more than one user. But I'm

Re: [GENERAL] What is the difference?

2009-03-06 Thread Ivan Sergio Borgonovo
. The first is comparing your needle with an array/recordset of just one element '95b5a221aeba15c','fb4e7219ab898ce','b08586cb81059f9' -- Ivan Sergio Borgonovo http://www.webthatworks.it -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription: http

[GENERAL] merging 2 databases

2009-03-05 Thread Ivan Sergio Borgonovo
Sergio Borgonovo http://www.webthatworks.it -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-general

[GENERAL] grant everything on everything and then revoke

2009-03-03 Thread Ivan Sergio Borgonovo
it is easier to revoke than to grant. Any advice even with completely different approach? thanks -- Ivan Sergio Borgonovo http://www.webthatworks.it -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref

Re: [GENERAL] grant everything on everything and then revoke

2009-03-03 Thread Ivan Sergio Borgonovo
On Tue, 03 Mar 2009 09:29:17 -0800 John R Pierce pie...@hogranch.com wrote: Ivan Sergio Borgonovo wrote: I'd like to have different users mainly to have a different search schema path. Things may evolve so this is not going to be the only reason to have more than one user. But I'm

Re: [GENERAL] where to divide application and database

2009-02-25 Thread Ivan Sergio Borgonovo
On Sat, 21 Feb 2009 15:02:55 -0800 Ron Mayer rm...@cheapcomplexdevices.com wrote: Ivan Sergio Borgonovo wrote: I was wondering if checks may have an impact on performances and if pg does some optimisation over them. Are you suggesting thee would be a positive or negative impact

Re: [GENERAL] where to divide application and database

2009-02-25 Thread Ivan Sergio Borgonovo
On Fri, 20 Feb 2009 20:45:20 + Sam Mason s...@samason.me.uk wrote: On Fri, Feb 20, 2009 at 04:51:33PM +0100, Ivan Sergio Borgonovo wrote: What I find a bit annoying is politely deal with the error once it is reported back to the application *and* connection and *bandwidth* costs

Re: [GENERAL] where to divide application and database

2009-02-20 Thread Ivan Sergio Borgonovo
easier to keep in sync those checks otherwise it is a really boring job and DB checks becomes just one more security net to maintain. In some places you REALLY appreciate/need that layer... sometimes it just get in the way. -- Ivan Sergio Borgonovo http://www.webthatworks.it -- Sent via pgsql

Re: [GENERAL] transfering tables into other schema

2009-02-18 Thread Ivan Sergio Borgonovo
in a new schema? The manual says: Associated indexes, constraints, and sequences owned by table columns are moved as well. But at my eyes I still can grasp the extent of the change. So I wouldn't like to be bitten by something I didn't take into account. -- Ivan Sergio Borgonovo http

Re: [GENERAL] transfering tables into other schema

2009-02-17 Thread Ivan Sergio Borgonovo
in application select x.a, y.b from x join y on x.xid=y.xid; -- following in the DB create or replace function xy() as $$ begin select x.a, y.b from x join y on x.xid=y.xid; ... end; $$ ... ALTER TABLE y SET SCHEMA new_schema; What should I change by hand? thanks -- Ivan Sergio

Re: [GENERAL] transfering tables into other schema

2009-02-17 Thread Ivan Sergio Borgonovo
On Tue, 17 Feb 2009 17:36:32 + Sam Mason s...@samason.me.uk wrote: On Tue, Feb 17, 2009 at 06:20:54PM +0100, Ivan Sergio Borgonovo wrote: I can't get how this really work. You're saying that constraint, fk/pk relationships will be preserved automatically... what else? OK BEFORE

[GENERAL] idle DB and resources

2009-02-16 Thread Ivan Sergio Borgonovo
it on another box or leave it there since once the editors job will be finished the DB will be much smaller. Meanwhile we will have 2 large DB, one of them being nearly idle. Is the idle DB going to have any impact on performance? thanks -- Ivan Sergio Borgonovo http://www.webthatworks.it -- Sent

[GENERAL] transfering tables into other schema

2009-02-16 Thread Ivan Sergio Borgonovo
running a well crafted set of SQL statement may do... But sed and plain text backup may do as well. Any other options? Any advices on how to procede once an option is the clear winner? thanks -- Ivan Sergio Borgonovo http://www.webthatworks.it -- Sent via pgsql-general mailing list (pgsql

Re: [GENERAL] TSearch queries with multiple languages

2009-02-13 Thread Ivan Sergio Borgonovo
of good programmers ;) Not only Oleg write very valuable code, but he really cares about his users base. I'm still sorry I haven't been able to track down the origin of a very slow gin index creation I reported months ago. -- Ivan Sergio Borgonovo http://www.webthatworks.it -- Sent via pgsql

Re: [GENERAL] [findings] minimal open source e-commerce software for pg

2009-02-13 Thread Ivan Sergio Borgonovo
won't see a too fast improvement I can't handle on the project that originated all this. So, sooner or later there will be one more Free e-commerce project based on postgresql around. -- Ivan Sergio Borgonovo http://www.webthatworks.it -- Sent via pgsql-general mailing list (pgsql-general

[GENERAL] [findings] minimal open source e-commerce software for pg

2009-02-08 Thread Ivan Sergio Borgonovo
On Sat, 7 Feb 2009 01:43:10 +0100 Ivan Sergio Borgonovo m...@webthatworks.it wrote: I need to build up a minimal e-commerce website on a host that is already running postgresql. Requirement is minimal. Usual configurable pretty standard couple of paying/shipping system and popular enough

Re: [GENERAL] [findings] minimal open source e-commerce software for pg

2009-02-08 Thread Ivan Sergio Borgonovo
://ofbiz.apache.org/ and actually I used it to learn something already... but well neither this fit the bill. thanks -- Ivan Sergio Borgonovo http://www.webthatworks.it -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription: http

[GENERAL] minimal open source e-commerce software for pg

2009-02-06 Thread Ivan Sergio Borgonovo
. This has to be a quick and dirty job and the actual requirement are just the above. thanks -- Ivan Sergio Borgonovo http://www.webthatworks.it -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql

Re: [GENERAL] Need some help converting MS SQL stored proc to postgres function

2009-02-01 Thread Ivan Sergio Borgonovo
://www.postgresql.org/docs/8.3/interactive/sql-createtableas.html not everything is yet as we dream it, but there is still a lot of syntactic sugar available to exploit. -- Ivan Sergio Borgonovo http://www.webthatworks.it -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes

Re: [GENERAL] ssl to more than one server

2009-01-30 Thread Ivan Sergio Borgonovo
On Thu, 29 Jan 2009 21:56:05 +0100 Ivan Sergio Borgonovo m...@webthatworks.it wrote: On Thu, 29 Jan 2009 12:53:20 -0500 Tom Lane t...@sss.pgh.pa.us wrote: Ivan Sergio Borgonovo m...@webthatworks.it writes: I succeded to connect to one postgresql server with ssl. Now it's the time

Re: [GENERAL] very long update gin index troubles back?

2009-01-29 Thread Ivan Sergio Borgonovo
On Wed, 28 Jan 2009 23:38:47 +0300 (MSK) Oleg Bartunov o...@sai.msu.su wrote: On Wed, 28 Jan 2009, Ivan Sergio Borgonovo wrote: On Tue, 27 Jan 2009 20:45:53 +0300 Teodor Sigaev teo...@sigaev.ru wrote: No matter if I drop the trigger that update agg content and the fact that I'm just

[GENERAL] ssl to more than one server

2009-01-29 Thread Ivan Sergio Borgonovo
-- Ivan Sergio Borgonovo http://www.webthatworks.it -- 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] ssl to more than one server

2009-01-29 Thread Ivan Sergio Borgonovo
On Thu, 29 Jan 2009 12:53:20 -0500 Tom Lane t...@sss.pgh.pa.us wrote: Ivan Sergio Borgonovo m...@webthatworks.it writes: I succeded to connect to one postgresql server with ssl. Now it's the time of the second... but postgresql clients (pgsql) just look at ~/.postgresql/postgresql.(key|crt

Re: [GENERAL] very long update gin index troubles back?

2009-01-28 Thread Ivan Sergio Borgonovo
be index as old one. Does that mean that it could be a good choice to place the tsvector in another table? thanks -- Ivan Sergio Borgonovo http://www.webthatworks.it -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription: http

Re: [GENERAL] very long update gin index troubles back?

2009-01-24 Thread Ivan Sergio Borgonovo
that update agg content and the fact that I'm just updating d, postgresql will update the index? Right? -- Ivan Sergio Borgonovo http://www.webthatworks.it -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref

[GENERAL] very long update gin index troubles back?

2009-01-22 Thread Ivan Sergio Borgonovo
. Is there anything wrong in the above to make this update so slow on a 2x Xeon 3.2GHz 4GbRAM and a RAID1 [sic] I know it is slow on write. -- Ivan Sergio Borgonovo http://www.webthatworks.it -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription: http

[GENERAL] too smart update (was: left join with smaller table or index on (XXX is not null) to avoid upsert)

2009-01-19 Thread Ivan Sergio Borgonovo
an update should fire triggers just if columns get updated... things will start to be a bit non-deterministic. You'll have to take into account rules etc... eg. FOUND is set true when conditions are met, not when columns are changed etc... -- Ivan Sergio Borgonovo http://www.webthatworks.it

Re: [GENERAL] left join with smaller table or index on (XXX is not null) to avoid upsert

2009-01-19 Thread Ivan Sergio Borgonovo
is feasible in a decent time. -- Ivan Sergio Borgonovo http://www.webthatworks.it -- 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] How can I look at a recursive table dependency tree?

2009-01-19 Thread Ivan Sergio Borgonovo
without doing a drop? BEGIN; DROP CASCADE... -- check things ROLLBACK; Isn't it going to be a pretty expensive way to see? Is the default log level enough to take note of the things that will be touched? (including eg. sequences, indexes etc...)? -- Ivan Sergio Borgonovo http

Re: [GENERAL] How can I look at a recursive table dependency tree?

2009-01-19 Thread Ivan Sergio Borgonovo
On Mon, 19 Jan 2009 14:41:12 + Richard Huxton d...@archonet.com wrote: Ivan Sergio Borgonovo wrote: On Mon, 19 Jan 2009 14:19:51 + Richard Huxton d...@archonet.com wrote: Igor Katson wrote: Is there a way to watch all dependencies recursively without doing a drop? BEGIN

Re: [GENERAL] left join with smaller table or index on (XXX is not null) to avoid upsert

2009-01-19 Thread Ivan Sergio Borgonovo
On Sun, 18 Jan 2009 22:12:07 +0100 Ivan Sergio Borgonovo m...@webthatworks.it wrote: I've to apply a discounts to products. For each promotion I've a query that select a list of products and should apply a discount. Queries may have intersections, in these intersections the highest

[GENERAL] left join with smaller table or index on (XXX is not null) to avoid upsert

2009-01-18 Thread Ivan Sergio Borgonovo
was wondering if it makes retrieval of Products and Prices slower. Having a larger table that is being updated at a rate of 5% to 10% a day may make it a bit fragmented. Advices on the overall problem of discount overlap management will be appreciated too. -- Ivan Sergio Borgonovo http

HTML email (was: Re: [GENERAL] Vacuum and Reindex hangs)

2009-01-15 Thread Ivan Sergio Borgonovo
/node/page/are_geeks_rich_media_impaired_or_why_html_emails_are_evil -- Ivan Sergio Borgonovo http://www.webthatworks.it -- 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] Polymorphic setof record function?

2009-01-14 Thread Ivan Sergio Borgonovo
use around. -- Ivan Sergio Borgonovo http://www.webthatworks.it -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-general

[GENERAL] limit and other joined tables

2009-01-13 Thread Ivan Sergio Borgonovo
on s.Aid=C.Cid; Can postgresql take advantage of the LIMIT even if it is in the outer select? -- Ivan Sergio Borgonovo http://www.webthatworks.it -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql

[GENERAL] refactoring: changing tables names

2009-01-09 Thread Ivan Sergio Borgonovo
in any significant slowdown accessing the table indirectly? Later I'll have to rename tables that have associated sequences, pk/fk and are referenced in functions etc... etc... Any good list of advices? Is there any tools that works with postgresql that can help me? thanks -- Ivan Sergio

[GENERAL] subselect and count (DISTINCT expression [ , ... ] ) performances

2008-12-27 Thread Ivan Sergio Borgonovo
be spent on distinct where postgresql shouldn't suffer from its count implementation. But well still 300K rows to count on 1M aren't few. -- Ivan Sergio Borgonovo http://www.webthatworks.it -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription

[GENERAL] count (DISTINCT expression [ , ... ] ) and documentation

2008-12-26 Thread Ivan Sergio Borgonovo
expression) Still I'm using 8.3 and select count(distinct c1, c2) from table1; report: No function matches the given name and argument types. You might need to add explicit type casts. What should I write in spite of? select count(distinct c1, c2) from table1; -- Ivan Sergio Borgonovo http

Re: [GENERAL] count (DISTINCT expression [ , ... ] ) and documentation

2008-12-26 Thread Ivan Sergio Borgonovo
into test.dist values(1,0); insert into test.dist values(1,0); insert into test.dist values(1,1); insert into test.dist values(0,0); select count(*) from (select distinct a,b from test.dist ) a; but still I can't think of anything that would work with aggregate(distinct a,b) not just count. -- Ivan Sergio

Re: [GENERAL] count (DISTINCT expression [ , ... ] ) and documentation

2008-12-26 Thread Ivan Sergio Borgonovo
On Fri, 26 Dec 2008 16:23:52 +0100 Pavel Stehule pavel.steh...@gmail.com wrote: 2008/12/26 Ivan Sergio Borgonovo m...@webthatworks.it: On Fri, 26 Dec 2008 15:46:48 +0100 Pavel Stehule pavel.steh...@gmail.com wrote: count has only one argument, then what was changed between 8.1

Re: [GENERAL] count (DISTINCT expression [ , ... ] ) and documentation

2008-12-26 Thread Ivan Sergio Borgonovo
On Fri, 26 Dec 2008 10:43:25 -0800 David Fetter da...@fetter.org wrote: On Fri, Dec 26, 2008 at 03:34:33PM +0100, Ivan Sergio Borgonovo wrote: I noticed that starting from 8.2 the documentation at http://www.postgresql.org/docs/8.2/interactive/sql-expressions.html say that multiple

[GENERAL] WITH AS vs subselect was: count (DISTINCT expression [ , ... ] ) and documentation

2008-12-26 Thread Ivan Sergio Borgonovo
On Fri, 26 Dec 2008 12:04:48 -0800 David Fetter da...@fetter.org wrote: On Fri, Dec 26, 2008 at 08:03:30PM +0100, Ivan Sergio Borgonovo wrote: aggregate_name (DISTINCT expression [, expression] ) In 8.4, you'll be able to do: WITH d AS ( SELECT DISTINCT c1, c2 FROM table1

Re: [GENERAL] How to Import Excel Into PostgreSQL database

2008-12-24 Thread Ivan Sergio Borgonovo
MS SQL 2000 to 2005 -- Ivan Sergio Borgonovo http://www.webthatworks.it -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-general

[GENERAL] return query and function result type must be real because of OUT parameters

2008-12-24 Thread Ivan Sergio Borgonovo
get ERROR: function result type must be real because of OUT parameters ** Error ** ERROR: function result type must be real because of OUT parameters SQL state: 42P13 same with text etc... -- Ivan Sergio Borgonovo http://www.webthatworks.it -- Sent via pgsql-general mailing

[GENERAL] design available tricks: traversing heterogeneous tree (table-level + linked list)

2008-12-22 Thread Ivan Sergio Borgonovo
) to represent the hierarchy may not be optimal and wring a safe and *fast* import function may not be trivial. I was wondering if there is some cool feature or cool contrib (8.3) that could make the choice much easier to take or just some suggestion. thanks -- Ivan Sergio Borgonovo http

[SOLVED] Re: [GENERAL] from 2 keys to serial

2008-12-15 Thread Ivan Sergio Borgonovo
On Sun, 14 Dec 2008 20:16:35 +0100 Ivan Sergio Borgonovo m...@webthatworks.it wrote: The cleanest solution I was able to find was to redefine the addresses_temp table so that it uses the same sequence as the _dest table. Some general design advices would be still welcome. I've to import

[GENERAL] from 2 keys to serial

2008-12-14 Thread Ivan Sergio Borgonovo
2 keys into a serial is pretty common and I'm asking for any alternative more elegant way than the above. thanks -- Ivan Sergio Borgonovo http://www.webthatworks.it -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription: http

[GENERAL] create table as vs. create table like

2008-12-12 Thread Ivan Sergio Borgonovo
I just noticed something I found unexpected. CREATE TABLE LIKE let you specify DEFAULT and Co. CREATE TABLE AS doesn't. Is there a one step way to clone a table? -- Ivan Sergio Borgonovo http://www.webthatworks.it -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make

Re: [GENERAL] create table as vs. create table like

2008-12-12 Thread Ivan Sergio Borgonovo
On Fri, 12 Dec 2008 13:25:07 +0100 A. Kretschmer andreas.kretsch...@schollglas.com wrote: In response to Ivan Sergio Borgonovo : I just noticed something I found unexpected. CREATE TABLE LIKE let you specify DEFAULT and Co. CREATE TABLE AS doesn't. Is there a one step way to clone

[GENERAL] case when evaluating else condition anyway?

2008-11-26 Thread Ivan Sergio Borgonovo
to a timestamp. Is there any cleaner functional way that doesn't involve prepared statement etc... since the whole exercise is caused by an null-impaired DB API (aka MySQLish). -- Ivan Sergio Borgonovo http://www.webthatworks.it -- Sent via pgsql-general mailing list (pgsql-general

Re: [GENERAL] case when evaluating else condition anyway?

2008-11-26 Thread Ivan Sergio Borgonovo
On Wed, 26 Nov 2008 14:18:44 + Sam Mason [EMAIL PROTECTED] wrote: On Wed, Nov 26, 2008 at 02:53:07PM +0100, Ivan Sergio Borgonovo wrote: case when ''=extinput then null else extinput::timestamp end I'd tend to use nullif(extinput,'')::timestamp for this sort of Thanks

[GENERAL] long vacuum full, gin index and unusually long delete

2008-11-21 Thread Ivan Sergio Borgonovo
activities the box seems to behave happily... including some other heavy weight activities where postgresql is involved. -- Ivan Sergio Borgonovo http://www.webthatworks.it -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription: http

Re: [GENERAL] transaction_read_only effects on performance, actual meaning (was: How to reduce impact of a query)

2008-11-20 Thread Ivan Sergio Borgonovo
. Thank you for pointing it out. -- Ivan Sergio Borgonovo http://www.webthatworks.it -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-general

[GENERAL] tracking down a warning

2008-11-19 Thread Ivan Sergio Borgonovo
the statement? Which is the right log config to tweak to get enough info to be able to use grep on my code base without producing 2Gb logs in 5min? BTW can this log config be tweaked dynamically? by connection etc... or just in postgres.conf? thanks -- Ivan Sergio Borgonovo http

Re: [GENERAL] still gin index creation takes forever

2008-11-18 Thread Ivan Sergio Borgonovo
to collect more data and see if it didn't happen by chance. -- Ivan Sergio Borgonovo http://www.webthatworks.it -- 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] still gin index creation takes forever

2008-11-13 Thread Ivan Sergio Borgonovo
90K records took a bit more than 6min. I'll try to move everything on another box and see what happens. -- Ivan Sergio Borgonovo http://www.webthatworks.it -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription: http://www.postgresql.org

Re: [GENERAL] still gin index creation takes forever

2008-11-13 Thread Ivan Sergio Borgonovo
an exact measure since it does look to last more than the box itself. Anyway... I'll try Teodor's trick to see if somehow it can circumvent the real cause and I'll try everything on another box ASAP. thanks to all -- Ivan Sergio Borgonovo http://www.webthatworks.it -- Sent via pgsql-general mailing

Re: [GENERAL] still gin index creation takes forever

2008-11-12 Thread Ivan Sergio Borgonovo
On Tue, 11 Nov 2008 22:02:17 -0500 Tom Lane [EMAIL PROTECTED] wrote: Ivan Sergio Borgonovo [EMAIL PROTECTED] writes: Any suggestion about how to track down the problem? What you are describing sounds rather like a use-of-uninitialized-memory problem, wherein the behavior depends on what

[GENERAL] sequence not restarting in a for loop (actually semi-random numbers)

2008-11-12 Thread Ivan Sergio Borgonovo
Sergio Borgonovo http://www.webthatworks.it -- 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] sequence not restarting in a for loop (actually semi-random numbers)

2008-11-12 Thread Ivan Sergio Borgonovo
On Wed, 12 Nov 2008 11:17:03 -0500 Tom Lane [EMAIL PROTECTED] wrote: Ivan Sergio Borgonovo [EMAIL PROTECTED] writes: insert into mytop (id,n) select id, nextval('tmp_seq') from biglist join mylist on biglist.id=mylist order by biglist.something limit 3; I suspect you

[GENERAL] still gin index creation takes forever

2008-11-11 Thread Ivan Sergio Borgonovo
even when there is no process stealing CPU cycles. Anyway when I'm creating a gin index CPU use is very high staying constantly near 100%. Any suggestion about how to track down the problem? thanks [1] temporary but not strictly temp tables -- Ivan Sergio Borgonovo http://www.webthatworks.it

[GENERAL] psql exit code

2008-11-10 Thread Ivan Sergio Borgonovo
(PostgreSQL) 8.3.4 How can I know if something went wrong other than parsing the output? Thanks -- Ivan Sergio Borgonovo http://www.webthatworks.it -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref

Re: [GENERAL] psql exit code

2008-11-10 Thread Ivan Sergio Borgonovo
On Mon, 10 Nov 2008 10:56:57 + Richard Huxton [EMAIL PROTECTED] wrote: Ivan Sergio Borgonovo wrote: I'm running: ON_ERROR_STOP=on PGPASSFILE=/somewhere psql dbname username -f script.sql (or alternatively script.sql) echo $? always returns 0 even when sql is clearly wrong

Re: [GENERAL] options for launching sql script asynchronously from web app

2008-11-08 Thread Ivan Sergio Borgonovo
it before and I'm still alive. I just have to trigger an event that run asynchronously, avoid other events of the same kind are triggered while one is running and report back event status. thanks -- Ivan Sergio Borgonovo http://www.webthatworks.it -- Sent via pgsql-general mailing list (pgsql-general

Re: [GENERAL] Fulltext index

2008-11-08 Thread Ivan Sergio Borgonovo
the correct language when you generate the tsquery in your search. http://www.sigaev.ru/gin/fastinsert_and_multicolumn_GIN.pdf -- Ivan Sergio Borgonovo http://www.webthatworks.it -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription: http

Re: [GENERAL] Specifying text to substitute for NULLs in selects

2008-11-07 Thread Ivan Sergio Borgonovo
in the COPY manual: http://www.postgresql.org/docs/8.1/static/sql-copy.html -- Ivan Sergio Borgonovo http://www.webthatworks.it -- 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] Specifying text to substitute for NULLs in selects

2008-11-07 Thread Ivan Sergio Borgonovo
if c1 was text you may end up in output like: 'NA' that will be hard to be discerned from a normal string. BTW I just discovered that COPY doesn't work on view. -- Ivan Sergio Borgonovo http://www.webthatworks.it -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make

Re: [GENERAL] Specifying text to substitute for NULLs in selects

2008-11-07 Thread Ivan Sergio Borgonovo
option is closest to a generic setting, but doesn't work with a select query, just a table dump. \copy (select ) to ... works. As written in my 2nd post. -- Ivan Sergio Borgonovo http://www.webthatworks.it -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make

[GENERAL] options for launching sql script asynchronously from web app

2008-11-07 Thread Ivan Sergio Borgonovo
I'd like to launch some sql script asynchronously from a web app and have some kind of feedback later. Some form of authentication would be a plus. Is there anything ready? -- Ivan Sergio Borgonovo http://www.webthatworks.it -- Sent via pgsql-general mailing list (pgsql-general

Re: [GENERAL] COPY TO duplicates \ signs

2008-11-05 Thread Ivan Sergio Borgonovo
== ==== == try to play with the ESCAPE AS and set it as '' if you really want to skip \. http://www.postgresql.org/docs/8.1/static/sql-copy.html -- Ivan Sergio Borgonovo http://www.webthatworks.it -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org

Re: [GENERAL] gin creation and previous history of server

2008-11-05 Thread Ivan Sergio Borgonovo
On Tue, 04 Nov 2008 10:33:26 -0500 Tom Lane [EMAIL PROTECTED] wrote: Ivan Sergio Borgonovo [EMAIL PROTECTED] writes: It seems that gin creation is triggering something nasty in the server that depends on previous history of the server. Can you put together a self-contained test case

Re: [GENERAL] gin creation and previous history of server

2008-11-05 Thread Ivan Sergio Borgonovo
On Wed, 05 Nov 2008 10:53:38 -0500 Tom Lane [EMAIL PROTECTED] wrote: Ivan Sergio Borgonovo [EMAIL PROTECTED] writes: Tom Lane [EMAIL PROTECTED] wrote: Can you put together a self-contained test case that illustrates this? I'm trying... Tonight I just let my long transaction run all

[GENERAL] gin creation and previous history of server

2008-11-04 Thread Ivan Sergio Borgonovo
it is definitively slower than 3x gist/gin index creation looks more cpu bounded than memory bounded. I'm checking if I made some mistake in other cfg parameters that may have some impact on index creation... Any further clue? -- Ivan Sergio Borgonovo http://www.webthatworks.it -- Sent via

[GENERAL] raise notice, psql and having some feedback from scripts

2008-11-03 Thread Ivan Sergio Borgonovo
I just have some batch work in scripts that I pass through: psql script.sql script.log or may be run by cron. In sql raise notice is not available. Is there any other way to send messages to the logs without polluting them too much with -a? -- Ivan Sergio Borgonovo http

[GENERAL] gin index creation performance problems

2008-11-03 Thread Ivan Sergio Borgonovo
. maintenance_work_mem is still untouched. What would be a good value to start from? Anything else to do to improve performances? -- Ivan Sergio Borgonovo http://www.webthatworks.it -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription: http

Re: [GENERAL] gin index creation performance problems

2008-11-03 Thread Ivan Sergio Borgonovo
On Mon, 3 Nov 2008 16:45:35 +0100 Ivan Sergio Borgonovo [EMAIL PROTECTED] wrote: Forgot to add that top say postgresql is using 100% CPU and 15% memory. I'm looking for a bit more guidance on gin index creation. The process: - vaccum analyze. - start a transaction that: - drop

Re: [GENERAL] gin index creation performance problems

2008-11-03 Thread Ivan Sergio Borgonovo
On Mon, 03 Nov 2008 11:04:45 -0500 Tom Lane [EMAIL PROTECTED] wrote: Ivan Sergio Borgonovo [EMAIL PROTECTED] writes: maintenance_work_mem is still untouched. What would be a good value to start from? GIN index build time is *very* sensitive to maintenance_work_mem. Try cranking it up

Re: [GENERAL] tsearch2 problem

2008-10-31 Thread Ivan Sergio Borgonovo
I find the resources to actually do what should be done (fully support the 2 languages). -- Ivan Sergio Borgonovo http://www.webthatworks.it -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql

Re: [GENERAL] Are there plans to add data compression feature to postgresql?

2008-10-31 Thread Ivan Sergio Borgonovo
and it seems that compression algorithms are strongly read-only search optimised. -- Ivan Sergio Borgonovo http://www.webthatworks.it -- 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] Are there plans to add data compression feature to postgresql?

2008-10-31 Thread Ivan Sergio Borgonovo
? -- Ivan Sergio Borgonovo http://www.webthatworks.it -- 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] overhead of plpgsql functions over simple select

2008-10-24 Thread Ivan Sergio Borgonovo
in sql... anything else to avoid? What are the factors that play a role in execution times? -- Ivan Sergio Borgonovo http://www.webthatworks.it -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql

Re: [GENERAL] Database design for separate tsearch table

2008-10-23 Thread Ivan Sergio Borgonovo
with the latter you've to use @@@ Um, could you clarify that? I know the general differences between gist and gin, but not how it affects weighted searches... http://www.postgresql.org/docs/8.3/static/textsearch-indexes.html search for @@@ -- Ivan Sergio Borgonovo http://www.webthatworks.it

[GENERAL] overhead of plpgsql functions over simple select

2008-10-23 Thread Ivan Sergio Borgonovo
to a simple select? I'm not that worried of old query plans. thx -- Ivan Sergio Borgonovo http://www.webthatworks.it -- 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] Shopping cart

2008-10-22 Thread Ivan Sergio Borgonovo
, Ubercart and Ecommerce (last 2 for drupal). I think they *may* work with postgresql as well. I think that anyway most of the popular prepackaged solutions don't support transactions in the DB. -- Ivan Sergio Borgonovo http://www.webthatworks.it -- Sent via pgsql-general mailing list (pgsql-general

[GENERAL] where column in ARRAY

2008-10-22 Thread Ivan Sergio Borgonovo
Without building up a dynamic query is it possible to: create or replace function t1(a int[]) as $$ ... select * from t1 where c in a; // eg in spite of in (1,2,3); or just obtain a similar effect? -- Ivan Sergio Borgonovo http://www.webthatworks.it -- Sent via pgsql-general mailing list

Re: [GENERAL] where column in ARRAY

2008-10-22 Thread Ivan Sergio Borgonovo
On Wed, 22 Oct 2008 14:46:35 +0200 Ivan Sergio Borgonovo [EMAIL PROTECTED] wrote: Without building up a dynamic query is it possible to: create or replace function t1(a int[]) as $$ ... select * from t1 where c in a; // eg in spite of in (1,2,3); or just obtain a similar effect? tired

Re: [GENERAL] Shopping cart

2008-10-22 Thread Ivan Sergio Borgonovo
friendly than most modules so you may have some surprises. Still no popular Free cart I know rely on DB coherency features especially the ones written in PHP. -- Ivan Sergio Borgonovo http://www.webthatworks.it -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes

[GENERAL] gin index and same query misteriously slowing down on a nearly-readonly DB

2008-10-22 Thread Ivan Sergio Borgonovo
no further. I've been able to vacuum full dropping the gin index and then vacuum and vacuum full... but it is still very very slow. -- Ivan Sergio Borgonovo http://www.webthatworks.it -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription

Re: [GENERAL] Database design for separate tsearch table

2008-10-22 Thread Ivan Sergio Borgonovo
don't tsearch won't work. eg. cane with Italian tsearch becomes {can}, but when you search it with English tsearch it remains {cane} so you won't find it. -- Ivan Sergio Borgonovo http://www.webthatworks.it -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes

[GENERAL] tsearch2: setting weights on tsquery

2008-10-21 Thread Ivan Sergio Borgonovo
be able rank on all fields at a time. -- Ivan Sergio Borgonovo http://www.webthatworks.it -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-general

exposing more parse was: Re: [GENERAL] tsearch2: setting weights on tsquery

2008-10-21 Thread Ivan Sergio Borgonovo
On Tue, 21 Oct 2008 10:29:52 +0200 Ivan Sergio Borgonovo [EMAIL PROTECTED] wrote: I came across this: http://grokbase.com/topic/2007/08/07/general-tsearch2-plainto-tsquery-with-or/r92nI5l_k9S4iKcWdCxKs05yFQk And I find it is strictly related to my needs. Working around ts_parse I could get

Re: exposing more parse was: Re: [GENERAL] tsearch2: setting weights on tsquery

2008-10-21 Thread Ivan Sergio Borgonovo
On Tue, 21 Oct 2008 13:20:12 +0200 Ivan Sergio Borgonovo [EMAIL PROTECTED] wrote: On Tue, 21 Oct 2008 10:29:52 +0200 Ivan Sergio Borgonovo [EMAIL PROTECTED] wrote: I came across this: http://grokbase.com/topic/2007/08/07/general-tsearch2-plainto-tsquery-with-or/r92nI5l_k9S4iKcWdCxKs05yFQk

Re: exposing more parse was: Re: [GENERAL] tsearch2: setting weights on tsquery

2008-10-21 Thread Ivan Sergio Borgonovo
On Tue, 21 Oct 2008 10:36:20 -0400 Tom Lane [EMAIL PROTECTED] wrote: Ivan Sergio Borgonovo [EMAIL PROTECTED] writes: It would still be nice to be able to directly work with tsvector and tsquery so people could exploit the parser, lexer etc... and recycle the config. I'd thinking

[GENERAL] tsearch2: setting weights on tsquery plainto_tsquery with | or and weight

2008-10-21 Thread Ivan Sergio Borgonovo
On Tue, 21 Oct 2008 13:40:33 -0400 Tom Lane [EMAIL PROTECTED] wrote: Ivan Sergio Borgonovo [EMAIL PROTECTED] writes: I missed it. Thanks. Nearly perfect. Now I've to understand what a {} is. An array with a null element? an empty array? an array containing ''? Hmm ... it appears

[GENERAL] parser: tokens in tsearch2

2008-10-18 Thread Ivan Sergio Borgonovo
Sergio Borgonovo http://www.webthatworks.it -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-general

[GENERAL] searching through a catalogue with tsearch2 (examples, references, HOWTO)

2008-10-17 Thread Ivan Sergio Borgonovo
... Other than the author's website and postgresql manual could someone point me to some good documentation, howto, examples? I'd appreciate even some general introduction to SE for catalogues that could be applied to tsearch2. thanks -- Ivan Sergio Borgonovo http://www.webthatworks.it -- Sent via

Re: [GENERAL] Annoying Reply-To

2008-10-17 Thread Ivan Sergio Borgonovo
it sound familiar? I beg everyone pardon, especially to Tom Lane whose replies always shine here, but I couldn't resist to reply to people thinking I'm not sensible, I took it personally ;) Evidently I'm old enough to know the existence of RFCs but not mature enough ;) -- Ivan Sergio Borgonovo

<    1   2   3   4   5   6   >