Re: [GENERAL] Using relations in the SELECT part

2017-03-30 Thread Giuseppe Sacco
Hello Tom, Il giorno mer, 29/03/2017 alle 09.59 -0400, Tom Lane ha scritto: [...] > > Furthermore, let's assume postgres does a cartesian product, if I > > add a > > new relation as third element, does it create 4x3 product? > > You've hit on the reason why it's semantically ugly: it's not very

[GENERAL] Using relations in the SELECT part

2017-03-29 Thread Giuseppe Sacco
Hello, I am writing to this list since I wrote a query that I cannot really understand. So, thanks to anyone who will light my darkness :-) I have a table with two columns, the first one is a key, the second one is a list of car plates. What I need to extract is a result set that contains two

Re: [GENERAL] How to setup Active Directory users in Postgres 9.3.11

2016-03-10 Thread Giuseppe Sacco
Hello Wyatt, Il giorno mer, 09/03/2016 alle 14.35 +, Wyatt Sanford ha scritto: > I have recently been tasked with installing Postgres 9.3.11 on a > Windows 2012 R2 server on Active Directory and restoring backups from > a Linux server running Postgres 9.3.11.  I have all of the databases >

Re: [GENERAL]

2015-11-13 Thread Giuseppe Sacco
Hello, Il giorno ven, 13/11/2015 alle 13.38 +0800, Alex Luya ha scritto: > Hello, >        I created a new database by  >        create database icare; >        then quit off psql and  run: >         pg_restore --clean --create --exit-on-error --dbname=icare > icare-test.tar >          it

Re: [GENERAL] Postgres architecture for multiple instances

2015-02-23 Thread Giuseppe Sacco
Il giorno dom, 22/02/2015 alle 14.53 -0500, Tom Lane ha scritto: [...] That's because the above claim is nonsense. pg_largeobject is not shared across databases of a cluster. You could well have collisions against large objects in the same database, though, if you're adding more large

Re: [GENERAL] Postgres architecture for multiple instances

2015-02-22 Thread Giuseppe Sacco
Il giorno sab, 21/02/2015 alle 16.01 -0600, Samuel Smith ha scritto: Howdy, I am looking for advice on migrating to postgres from another database system. [...] People already wrote you some comments, here are two more. DB2 instances run as different OS users, so if you need the same

[GENERAL] Slow delete when many foreign tables are defined

2014-12-01 Thread Giuseppe Sacco
Hello, I have a main table and a lot of details tables that reference the main one. Every time I delete a record from the main table, a check is done on every details table that contain a foreign key toward main table. This is a simplified schema: create table main ( type varchar, serial

Re: [GENERAL] Slow delete when many foreign tables are defined

2014-12-01 Thread Giuseppe Sacco
Il giorno lun, 01/12/2014 alle 09.49 -0600, Andy Colson ha scritto: On 12/1/2014 9:23 AM, Giuseppe Sacco wrote: Hello, I have a main table and a lot of details tables that reference the main one. Every time I delete a record from the main table, a check is done on every details table

Re: [GENERAL] Large object rights management

2012-02-15 Thread Giuseppe Sacco
Is there anyone interested on this subject? Il giorno dom, 05/02/2012 alle 23.30 +0100, Giuseppe Sacco ha scritto: Hi all, I wrote an application that store a large quantity of files in the database as large binary objects. There are around 50 tables (all in one schema) and only one table

[GENERAL] Large object rights management

2012-02-05 Thread Giuseppe Sacco
Hi all, I wrote an application that store a large quantity of files in the database as large binary objects. There are around 50 tables (all in one schema) and only one table host all these large objects. Every user connect to database using his own user, so all users are parts of the same group

[GENERAL] error permission denied for relation on postgresql 9.0.6 during CREATE TABLE

2012-01-27 Thread Giuseppe Sacco
Hi, I get this error while executing a CREATE TABLE statement. This is my CREATE statement: CREATE TABLE agenzia.BarcodeByDocumentInfo ( docId VARCHAR(17) NOT NULL, defaultOp VARCHAR(10) NOT NULL DEFAULT 'Append', CONSTRAINT BcByDocInfo_pk PRIMARY KEY (docId),

Re: [GENERAL] error permission denied for relation on postgresql 9.0.6 during CREATE TABLE

2012-01-27 Thread Giuseppe Sacco
Il giorno ven, 27/01/2012 alle 08.54 -0800, Adrian Klaver ha scritto: On Friday, January 27, 2012 8:25:56 am Giuseppe Sacco wrote: [...] I am owner of table documents: neos= \dt agenzia.documents List of relations Schema | Name| Type | Owner

Re: [GENERAL] error permission denied for relation on postgresql 9.0.6 during CREATE TABLE

2012-01-27 Thread Giuseppe Sacco
Il giorno ven, 27/01/2012 alle 12.38 -0500, Tom Lane ha scritto: NOTICE: CREATE TABLE / PRIMARY KEY will create implicit index bcbydocinfo_pk for table barcodebydocumentinfo ERROR: permission denied for relation documents This example works for me. Are you sure you are executing the

Re: [GENERAL] SSL certificates issue

2011-08-23 Thread Giuseppe Sacco
Il giorno lun, 22/08/2011 alle 09.37 -0400, Tom Lane ha scritto: Asia asia123...@op.pl writes: Now the issue is then when using libpq it was enough to have only root certificate in server's root.crt and it worked fine. But when I tried using the same with JDBC it turned out that I need to

Re: [GENERAL] Executing more than one function.

2011-08-23 Thread Giuseppe Sacco
Il giorno mar, 23/08/2011 alle 16.30 +0100, f vf ha scritto: [...] it takes more time than if I execute one function at the time and sum the execution times of each one: BEGIN; SELECT functionX(); COMMIT; You should probably accout a time for the COMMIT operation. In one case you

Re: [GENERAL] About permissions on large objects

2011-07-15 Thread Giuseppe Sacco
Hi Howard, Il giorno mer, 13/07/2011 alle 23.30 +0100, Howard Cole ha scritto: Hi Guiseppe, Perhaps you can create a trigger that monitors for the insertion of an oid and then grant permissions. No idea if this can be done, but if it can it will save you lots of repeated grants. [...]

[GENERAL] About permissions on large objects

2011-07-13 Thread Giuseppe Sacco
Hi all, I moved a few clusters from 8.4 to 9.0 since I required the new way of authenticating against LDAP (or, in my case, AD). Now, I found the new database version introduced permissions on large object, so my application, in order to share large object across a group, require a bit of change.

Re: [GENERAL] About permissions on large objects

2011-07-13 Thread Giuseppe Sacco
Hi Howard, Il giorno mer, 13/07/2011 alle 13.18 +0100, Howard Cole ha scritto: [...] As an interim solution, you could set the large object compatibility: www.postgresql.org/docs/9.0/interactive/runtime-config-compatible.html#GUC-LO-COMPAT-PRIVILEGES thanks for pointing to this option. I