[GENERAL] Prevent roles not having admin option from granting themselves to other roles

2015-06-11 Thread Charles Clavadetscher
ves to others. In my searches so far, I could not find any information on that and I was not able to find a strategy myself. Thank you and have a good day. Charles Clavadetscher -- 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] Prevent roles not having admin option from granting themselves to other roles

2015-06-11 Thread Charles Clavadetscher
Hello Adrian Thank you very much for your response. As a matter of fact I already had a look into the NOINHERIT attribute and its consequences. This partially solves the problem but makes the usage of user accounts in applications more complex. If I wanted to create a group for accessing the data

Re: [GENERAL] Prevent roles not having admin option from granting themselves to other roles

2015-06-11 Thread Charles Clavadetscher
.@postgresql.org] On Behalf Of Charles Clavadetscher Sent: Donnerstag, 11. Juni 2015 16:28 To: pgsql-general@postgresql.org Subject: Re: [GENERAL] Prevent roles not having admin option from granting themselves to other roles Hello Adrian Thank you very much for your response. As a matter of fact I alr

Re: [GENERAL] Trying to avoid a simple temporary variable declaration in a pl/pgsql function

2015-06-20 Thread Charles Clavadetscher
Hello The solution proposed by Tom works as long as you can make sure that your SELECT statement in the function will return a single row with a single column of type TEXT: CREATE TABLE test (id INTEGER, what_goes_here TEXT); INSERT INTO test values (1,'Text 1'); INSERT INTO test values (2,'T

Re: [GENERAL] INSERT a number in a column based on other columns OLD INSERTs

2015-06-20 Thread Charles Clavadetscher
Hello I just made a short test with the code provided. As Bill mentioned the moment when the trigger is fired is essential. I made a test with both before (worked) and after (did not work because the row was already inserted and the returned new row is ignored). The assignment (= or :=) does

Re: [GENERAL] INSERT a number in a column based on other columns OLD INSERTs

2015-06-21 Thread Charles Clavadetscher
Hi The two things have nothing in common. With NEW.time_index = t_ix you set the field with a value and with return you return the record (with the modified field) to make the insert. You have to return NEW, because you have a trigger function. The function must return a record of the same typ

Re: [GENERAL] INSERT a number in a column based on other columns OLD INSERTs

2015-06-21 Thread Charles Clavadetscher
efore" triggers. I would recommend you to read the documentation on trigger functions. It is excellent and clarifies quite a lot how things work. Bye Charles On 6/21/2015 16:49, Charles Clavadetscher wrote: Hi The two things have nothing in common. With NEW.time_index = t_ix you set the fi

Re: [GENERAL] create index on a field of udt

2015-06-28 Thread Charles Clavadetscher
Hello I am not sure it is that simple. Probably you need to create operator classes to be used for indexing. http://www.postgresql.org/docs/9.4/static/xtypes.html You are probably better off using the basic data type in your table and using a composite index. Bye Charles F

Re: [GENERAL] create index on a field of udt

2015-06-29 Thread Charles Clavadetscher
+1 create index on test (((i).id)); ANALYZE explain select * from test where (i).id = 8909; QUERY PLAN - Index Scan using test_id_idx on test (cost=0.43..8.45 rows=1 width=34) Index

Re: [GENERAL] Ubuntu 14.04 LTS install problem

2015-07-01 Thread Charles Clavadetscher
Hello Urs I could install PostgreSQL 9.4 on Ubuntu 14.04 without adding repositories (actually it was an upgrade and I had to move the data manually from 9.3 to 9.4). You may want to try it that way? Bye Charles > -Original Message- > From: pgsql-general-ow...@postgresql.org [mailto:pg

Re: [GENERAL] Ubuntu 14.04 LTS install problem

2015-07-01 Thread Charles Clavadetscher
eneral-ow...@postgresql.org [mailto:pgsql-general- > ow...@postgresql.org] On Behalf Of Urs Berner > Sent: Mittwoch, 1. Juli 2015 11:06 > To: pgsql-general@postgresql.org > Subject: Re: [GENERAL] Ubuntu 14.04 LTS install problem > > Am 01.07.2015 um 09:08 schrieb Charles Clav

Re: [GENERAL] Download PostgreSQL 9.5 Alpha

2015-07-03 Thread Charles Clavadetscher
Hello I also could not find the download on EDB. For Ubuntu 9.5 alpha is available but I was not able to install it using apt-get because it cannot resolve some dependencies. Finally I downloaded and compiled the source code. This worked well, but I had to do some additional steps to get the c

Re: [GENERAL] String match function required like utl_match in oracle

2015-07-04 Thread Charles Clavadetscher
Or maybe even better: http://www.postgresql.org/docs/9.4/static/fuzzystrmatch.html Search for Levenshtein. Bye Charles On 7/4/2015 11:50, Jimit Amin wrote: Hello, I want to compare 2 string and want result like how much percentage or how much part string is compared. Can I know any option li

Re: [GENERAL] [pg_hba.conf] publish own Python application using PostgreSQL

2015-07-05 Thread Charles Clavadetscher
Hi I am not really an expert, but from your description I guess that you assume an existing PostgreSQL installation on your customers' server. If that is the case you probably won't get around giving instructions to your customer and let them do the change. I would not like to install applica

[GENERAL] Row level security - notes and questions

2015-07-10 Thread Charles Clavadetscher
Hello I have been testing the new row level security feature of 9.5 and I have some notes and questions on it. This is a simple table for the test, with 2 rows and a user named john, who is granted access to the table through a group named users. CREATE TABLE testrls.accounts ( id integer,

Re: [GENERAL] Row level security - notes and questions

2015-07-11 Thread Charles Clavadetscher
continue with some experiments and get back with new questions if any arise. PostgreSQL has really a great community ;-) Enjoy Charles > -Original Message- > From: Stephen Frost [mailto:sfr...@snowman.net] > Sent: Samstag, 11. Juli 2015 15:22 > To: Charles Clavadetscher > Cc

Re: [GENERAL] A table of magic constants

2015-07-11 Thread Charles Clavadetscher
Hi Dane There is a list of reserved keywords, including the ones that you mentioned. http://www.postgresql.org/docs/9.5/static/sql-keywords-appendix.html However you still need to search for their meaning. Mayb

[GENERAL] Where to place suggestions for documentation improvements

2015-07-14 Thread Charles Clavadetscher
Hello I have a generic question. Where should I/we place suggestions on possible improvements of the documentation? Is it here or better on pgsql-docs? Thanks Charles -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription: http://www.postgr

Re: [GENERAL] Where to place suggestions for documentation improvements

2015-07-14 Thread Charles Clavadetscher
gt; To: Charles Clavadetscher > Cc: PostgreSQL mailing lists > Subject: Re: [GENERAL] Where to place suggestions for documentation > improvements > > On Tue, Jul 14, 2015 at 8:17 PM, Charles Clavadetscher > wrote: > > I have a generic question. Where should I/we place suggesti

Re: [GENERAL] [9.5] question about row level security

2015-07-15 Thread Charles Clavadetscher
Hello I am not so sure if this is feasible with policies only. Personally I would separate private data from the rest assuming that that part is anyway information that also the boss is not supposed to look at. A separation would make the setup of policies easy. Using the structure that you

Re: [GENERAL] INSERT ... ON CONFLICT DO UPDATE

2015-07-19 Thread Charles Clavadetscher
Hello > I've just started to read through postgres-9.5 "what's new" ... before giving > it > a try. The "insert ... on conflict do update" is particularly atractive to > me; but I > was wondering why it does not cover the third usage scenario of action that a > programmer may need for a PK confl

Re: [GENERAL] Problem with pl/python procedure connecting to the internet

2015-08-22 Thread Charles Clavadetscher
> -Original Message- > From: pgsql-general-ow...@postgresql.org [mailto:pgsql-general- > ow...@postgresql.org] On Behalf Of Igor Sosa Mayor > Sent: Sonntag, 23. August 2015 07:22 > To: pgsql-general@postgresql.org > Subject: Re: [GENERAL] Problem with pl/python procedure connecting to the >

Re: [GENERAL] Problem with pl/python procedure connecting to the internet

2015-08-23 Thread Charles Clavadetscher
Hi Weird. According to http://geopy.readthedocs.org/en/latest/#geopy.exc.GeocoderServiceError this is the most generic exception, only used when there is not a more specific one (which include by the way problems caused by connectivity and authorization). The message of the exception is supposed t

Re: [GENERAL] Strange TRIGGER failure with FOR ... IN ... LOOP ... INSERT

2015-08-27 Thread Charles Clavadetscher
Hello You declare your variable r as of type application.store_ldap_profile_defaults%rowtype, but then select only 4 of the 5 fields of the table to put in there. The last one (happens to be access_mode is then null). The structures don’t match. That may explain this behaviour. This wor

Re: [GENERAL] Strange TRIGGER failure with FOR ... IN ... LOOP ... INSERT

2015-08-27 Thread Charles Clavadetscher
: pgsql-general-ow...@postgresql.org [mailto:pgsql-general-ow...@postgresql.org] On Behalf Of Charles Clavadetscher Sent: Donnerstag, 27. August 2015 14:57 To: pgsql-general@postgresql.org Subject: Re: [GENERAL] Strange TRIGGER failure with FOR ... IN ... LOOP ... INSERT Hello You declare your

Re: [GENERAL] Strange TRIGGER failure with FOR ... IN ... LOOP ... INSERT

2015-08-27 Thread Charles Clavadetscher
Hi > -Original Message- > From: pgsql-general-ow...@postgresql.org [mailto:pgsql-general- > ow...@postgresql.org] On Behalf Of Adrian Klaver > Sent: Donnerstag, 27. August 2015 15:41 > To: Christopher BROWN > Cc: pgsql-general@postgresql.org > Subject: Re: [GENERAL] Strange TRIGGER failur

Re: [GENERAL] Need Database Backup

2015-08-30 Thread Charles Clavadetscher
Hi I agree with all upthreads mentioning that the amount of information you (Murali) deliver is much too little to help. Nevertheless my thoughts. - NTLDR Missing is obviously a Windows problem and I don't think that it has to do with PostgreSQL. You may find better help on a Windows forum or m

Re: [GENERAL] Need Database Backup

2015-08-30 Thread Charles Clavadetscher
Well the rest should be easy. psql -U ... -h ... -p ... -d ... -f sql_file.sql http://www.postgresql.org/docs/9.4/static/app-psql.html option "f" From: pgsql-general-ow...@postgresql.org [mailto:pgsql-general-ow...@postgresql.org] On Behalf Of Melvin Davidson Sent: Sonntag, 30. August 2015 16:2

Re: [GENERAL] Public facing PostgreSQL hosting ?

2015-08-31 Thread Charles Clavadetscher
Hello You can use pgAdmin (or psql for that matter) to connect to a database over the network, provided PostgreSQL is configured to accept this kind of connections and all the firewalls to it allow the traffic. http://www.postgresql.org/docs/9.4/interactive/runtime-config-connection.html http:/

Re: [GENERAL] Delete trigger

2015-09-18 Thread Charles Clavadetscher
Hello Not sure I get it right, but all three fields are not nullable. So they will always have a value, which is what I understand of "are specified". What do you need the trigger for in that case? Bye Charles > -Original Message- > From: pgsql-general-ow...@postgresql.org > [mailto:pg

Re: [GENERAL] how to show time zone with numerical offset in CSV log?

2015-09-22 Thread Charles Clavadetscher
Hi > -Original Message- > From: pgsql-general-ow...@postgresql.org > [mailto:pgsql-general-ow...@postgresql.org] On Behalf Of Michael Zoet > Sent: Dienstag, 22. September 2015 12:07 > To: pgsql-general@postgresql.org > Subject: [GENERAL] how to show time zone with numerical offset in CSV

Re: [GENERAL] how to show time zone with numerical offset in CSV log?

2015-09-22 Thread Charles Clavadetscher
Hi > thanks for the quick response and it looked promising but did not work > as expected. > > I can set the datestyle to ISO on database level but this does not > seem to effect the way the CSV logs are written. I still get > 2015-09-22 13:06:01.658 UTC (or CEST and so on) in the log files. And

Re: [GENERAL] Selecting pairs of numbers

2015-10-05 Thread Charles Clavadetscher
> aklaver@test=> create table pr_test(x int, y int); > > aklaver@test=> select * from pr_test where (x, y) between (1, 3) and > (3,2) order by x,y; > x | y > ---+--- > 1 | 3 > 1 | 4 > 2 | 1 > 2 | 2 > 2 | 3 > 2 | 4 > 3 | 1 > 3 | 2 +1, nice. -- Sent via pgsql-general mailing

Re: [GENERAL] Unable to select a table as postgres user

2015-10-30 Thread Charles Clavadetscher
Hi What error do you get? - Permission denied or table does not exist? Latter would indicate a problem with the search_path and you should fully qualify the table name in the function body. - Did you create the function as postgres user? Bye Charles On 30/10/2015 07:56, rajan wrote: Yes.

Re: [GENERAL] Selectively Importing Data

2015-10-31 Thread Charles Clavadetscher
Hello This should work: \copy taxon (descr) from ; This is true if your sheet has only one column, so you should delete that column. However if you happen to have another table with a foreign key on taxonid you will probably screw up the references. But from your description I take it, that

Re: [GENERAL] How SQL SELECT * statement works in Postgres?

2016-06-05 Thread Charles Clavadetscher
a good start: https://www.postgresql.org/docs/9.5/static/overview.html Regards, Charles Regards, SSR -- Charles Clavadetscher Swiss PostgreSQL Users Group http://www.swisspug.org http://www.pg

Re: [GENERAL] Running query without trigger?

2016-07-08 Thread Charles Clavadetscher
Good morning > -Original Message- > From: pgsql-general-ow...@postgresql.org > [mailto:pgsql-general-ow...@postgresql.org] On Behalf Of hamann.w@t- > online.de > Sent: Samstag, 9. Juli 2016 08:20 > To: pgsql-general@postgresql.org > Subject: [GENERAL] Running query without trigger? > >

Re: [GENERAL] For storing XML version in our table.

2016-07-22 Thread Charles Clavadetscher
> From: pgsql-general-ow...@postgresql.org > [mailto:pgsql-general-ow...@postgresql.org] On Behalf Of zubair alam > Sent: Mittwoch, 20. Juli 2016 09:09 > To: pgsql-general@postgresql.org > Subject: [GENERAL] For storing XML version in our table. Hi How i can store my xml data with their ver

Re: [GENERAL] Array value from table as parameter

2016-07-22 Thread Charles Clavadetscher
Hello > From: pgsql-general-ow...@postgresql.org > [mailto:pgsql-general-ow...@postgresql.org] On Behalf Of Aislan Luiz Wendling > Sent: Mittwoch, 20. Juli 2016 19:17 > To: pgsql-general@postgresql.org > Subject: [GENERAL] Array value from table as parameter > > Hi, > > I need to pass an array as

Re: [GENERAL] Proposal "stack trace" like debugging option in PostgreSQL

2016-08-01 Thread Charles Clavadetscher
ll Stack --- PL/pgSQL function inner_func() line 5 at GET DIAGNOSTICS PL/pgSQL function outer_func() line 3 at RETURN CONTEXT: PL/pgSQL function outer_func() line 3 at RETURN outer_func 1 (1 row) Regards Charles -- Swiss PostgreS

Re: [GENERAL] Log all queries before migration ?

2016-08-03 Thread Charles Clavadetscher
Hello > -Original Message- > From: pgsql-general-ow...@postgresql.org > [mailto:pgsql-general-ow...@postgresql.org] On Behalf Of ben.play > Sent: Mittwoch, 3. August 2016 15:29 > To: pgsql-general@postgresql.org > Subject: Re: [GENERAL] Log all queries before migration ? > > Hi guys, >

Re: [GENERAL] Extract data from JSONB

2016-08-07 Thread Charles Clavadetscher
Hello > -Original Message- > From: pgsql-general-ow...@postgresql.org > [mailto:pgsql-general-ow...@postgresql.org] On Behalf Of Michael Paquier > Sent: Montag, 8. August 2016 05:24 > To: Alex Magnum > Cc: Postgres General > Subject: Re: [GENERAL] Extract data from JSONB > > On Mon, Au

Re: [GENERAL] lower() silently fails for 9.5.3 on Windows, but works on Mac, Linux

2016-08-08 Thread Charles Clavadetscher
Hello > From: pgsql-general-ow...@postgresql.org > [mailto:pgsql-general-ow...@postgresql.org] On Behalf Of Alexander Farber > Sent: Montag, 8. August 2016 09:10 > To: pgsql-general > Subject: Re: [GENERAL] lower() silently fails for 9.5.3 on Windows, but works > on Mac, Linux > > More info: >

Re: [GENERAL] lower() silently fails for 9.5.3 on Windows, but works on Mac, Linux

2016-08-08 Thread Charles Clavadetscher
Hello > -Original Message- > From: pgsql-general-ow...@postgresql.org > [mailto:pgsql-general-ow...@postgresql.org] On Behalf Of Charles > Clavadetscher > Sent: Montag, 8. August 2016 09:30 > To: 'Alexander Farber' ; 'pgsql-general' > > Subje

Re: [GENERAL] lower() silently fails for 9.5.3 on Windows, but works on Mac, Linux

2016-08-08 Thread Charles Clavadetscher
Hello > From: pgsql-general-ow...@postgresql.org > [mailto:pgsql-general-ow...@postgresql.org] On Behalf Of Alexander Farber > Sent: Montag, 8. August 2016 10:12 > Cc: pgsql-general > Subject: Re: [GENERAL] lower() silently fails for 9.5.3 on Windows, but works > on Mac, Linux > > Thank you for

Re: [GENERAL] lower() silently fails for 9.5.3 on Windows, but works on Mac, Linux

2016-08-08 Thread Charles Clavadetscher
Hello Alexander > -Original Message- > From: pgsql-general-ow...@postgresql.org > [mailto:pgsql-general-ow...@postgresql.org] On Behalf Of Alexander Farber > Sent: Montag, 8. August 2016 10:21 > Cc: pgsql-general > Subject: Re: [GENERAL] lower() silently fails for 9.5.3 on Windows, but w

Re: [GENERAL] RETURNS TABLE function: ERROR: column reference "word" is ambiguous

2016-08-10 Thread Charles Clavadetscher
Hello > -Original Message- > From: pgsql-general-ow...@postgresql.org > [mailto:pgsql-general-ow...@postgresql.org] On Behalf Of Alexander Farber > Sent: Mittwoch, 10. August 2016 14:54 > To: pgsql-general > Subject: [GENERAL] RETURNS TABLE function: ERROR: column reference "word" is >

Re: [GENERAL] Upgrading using pg_dumpall

2016-09-03 Thread Charles Clavadetscher
: password authentication failed for user "rshepard" Does the user rshepard exist in the new 9.5 instance? What was the error message? As above. Thanks, Rich -- Swiss PostgreSQL Users Group c/o Charles Clavadetscher Treasurer Motorenstrasse 18 CH – 8005 Zü

Re: [GENERAL] Upgrading using pg_dumpall

2016-09-04 Thread Charles Clavadetscher
6 fi Note the '-W' at the end. But, I ran initdb from the command line as user postgres. Rich -- Swiss PostgreSQL Users Group c/o Charles Clavadetscher Treasurer Motorenstrasse 18 CH – 8005 Zürich http://www.swisspug.org

Re: [GENERAL] Upgrading using pg_dumpall

2016-09-04 Thread Charles Clavadetscher
already answered that. You can set the connection authentication method to trust. This can have some risks, however. Bye Charles Thanks again, Rich -- Swiss PostgreSQL Users Group c/o Charles Clavadetscher Treasurer Motorenst

Re: [GENERAL] Upgrading using pg_dumpall

2016-09-04 Thread Charles Clavadetscher
Hi On 09/04/2016 05:16 PM, Charles Clavadetscher wrote: Hi On 09/04/2016 05:14 PM, Rich Shepard wrote: On Sat, 3 Sep 2016, Adrian Klaver wrote: Or if you are fine running the 9.5 instance at port 5432, what happens if you do?: psql -d postgres -U some_user -p 5432 $ psql -d postgres -U

Re: [GENERAL] Restricted access on DataBases

2016-09-05 Thread Charles Clavadetscher
reSQL. This will strongly help you understanding what you are doing. Charles Thank you for the help. information, or an example! DD -- Swiss PostgreSQL Users Group c/o Charles Clavadetscher Treasurer Motorenstrasse 18 CH – 8005 Zürich http://www.swisspug.org +

Re: [GENERAL] Restricted access on DataBases

2016-09-05 Thread Charles Clavadetscher
Hello On 09/05/2016 05:56 PM, Charles Clavadetscher wrote: Hello On 09/05/2016 04:19 PM, Adrian Klaver wrote: On 09/05/2016 05:45 AM, Durumdara wrote: Dear PG-masters! We want to put more databases to one server, to "public" schema: DB_A, DB_B, DB_C. The PUBLIC schema is contai

Re: [GENERAL] Check if there 6 last records of same type without gaps

2016-09-06 Thread Charles Clavadetscher
Hello > On 06.09.2016, at 14:35, Alexander Farber wrote: > > No, I am sorry - for struggling with probably basic questions, but without > GROUP BY I get another error: > > org.postgresql.util.PSQLException: ERROR: column "words_moves.played" must > appear in the GROUP BY clause or be used in

Re: [GENERAL] Restricted access on DataBases

2016-09-07 Thread Charles Clavadetscher
Hello On 09/07/2016 03:24 PM, Durumdara wrote: Dear Everybody! I read the documentation based on your example. First reactions. 2016-09-05 18:25 GMT+02:00 Charles Clavadetscher mailto:clavadetsc...@swisspug.org>>: GRANT us_a, us_b, us_c TO main_admin; Ah, it's good.

Re: [GENERAL] Restricted access on DataBases

2016-09-07 Thread Charles Clavadetscher
Hello I did oversee the additional questions... On 09/07/2016 06:45 PM, Charles Clavadetscher wrote: Hello On 09/07/2016 03:24 PM, Durumdara wrote: Dear Everybody! I read the documentation based on your example. First reactions. 2016-09-05 18:25 GMT+02:00 Charles Clavadetscher

Re: [GENERAL] Restricted access on DataBases

2016-09-14 Thread Charles Clavadetscher
Hello From: pgsql-general-ow...@postgresql.org [mailto:pgsql-general-ow...@postgresql.org] On Behalf Of Durumdara Sent: Mittwoch, 14. September 2016 17:13 Cc: pgsql-general@postgresql.org Subject: Re: [GENERAL] Restricted access on DataBases Dear Adrian and Charles! I tried to create a

[GENERAL] Question on replace function

2016-09-25 Thread Charles Clavadetscher
Firstname Lastname\r\\rEMAIL;TYPE=INTERNET;TYPE=OTHER:email\r\\rEND:VCARD (1 row) Does anybody have an idea what I am doing wrong? Thank you for your help. Charles -- Swiss PostgreSQL Users Group c/o Charles Clavadetscher Treasurer Motorenstrasse 18 CH – 8005 Zürich http://www.swisspug.org +-

Re: [GENERAL] Question on replace function [solved]

2016-09-25 Thread Charles Clavadetscher
Hi Rob On 09/25/2016 01:39 PM, rob stone wrote: > > On Sun, 2016-09-25 at 10:29 +0200, Charles Clavadetscher wrote: >> Hello >> >> I am using PostgreSQL 9.4.7 on x86_64-unknown-linux-gnu, compiled by >> gcc >> (Debian 4.7.2-5) 4.7.2, 64-bit >> &g

Re: [GENERAL] Question on replace function [solved]

2016-09-25 Thread Charles Clavadetscher
Hello Tom and Adrian > -Original Message- > From: pgsql-general-ow...@postgresql.org > [mailto:pgsql-general-ow...@postgresql.org] On Behalf Of Adrian Klaver > Sent: Sonntag, 25. September 2016 18:38 > To: Tom Lane ; Charles Clavadetscher > > Cc: pgsql-general@pos

Re: [GENERAL] Restricted access on DataBases

2016-10-04 Thread Charles Clavadetscher
Hello > > Also try this: > > ALTER DEFAULT PRIVILEGES FOR ex_mainuser GRANT INSERT, SELECT, UPDATE, > > DELETE, TRUNCATE, REFERENCES, TRIGGER > >ON TABLES TO ex_dbuser; > > > > You execute the ALTER DEFAULT PRIVILEGES as su, so the grant applies to > > objects created by su and n

Re: [GENERAL] pg_sample

2016-10-18 Thread Charles Clavadetscher
YFAlgG4NkACgkQvJuQZxSWSsge4ACePhBOBtBFnGNxXt5qpY7X+w3o d04AoKTzAgxcaqy8qfIE0LPuzG9x0KIU =sS+m -END PGP SIGNATURE----- -- Swiss PostgreSQL Users Group c/o Charles Clavadetscher Treasurer Motor

Re: [GENERAL] Request to share information regarding errors

2016-11-15 Thread Charles Clavadetscher
Good morning > -Original Message- > From: pgsql-general-ow...@postgresql.org > [mailto:pgsql-general-ow...@postgresql.org] On Behalf Of Yogesh Sharma > Sent: Mittwoch, 16. November 2016 07:09 > To: pgsql-general@postgresql.org > Subject: Re: [GENERAL] Request to share information regardin

Re: [GENERAL] Request to share information regarding errors

2016-11-15 Thread Charles Clavadetscher
Hello Yogesh > -Original Message- > From: pgsql-general-ow...@postgresql.org > [mailto:pgsql-general-ow...@postgresql.org] On Behalf Of Yogesh Sharma > Sent: Mittwoch, 16. November 2016 07:59 > To: Charles Clavadetscher ; > pgsql-general@postgresql.org > Subject:

Re: [GENERAL] Request to share information regarding deadlock in postgresql-9.3.6

2016-11-17 Thread Charles Clavadetscher
Hello > -Original Message- > From: pgsql-general-ow...@postgresql.org > [mailto:pgsql-general-ow...@postgresql.org] On Behalf Of Yogesh Sharma > Sent: Donnerstag, 17. November 2016 08:31 > To: John R Pierce ; pgsql-general@postgresql.org > Subject: Re: [GENERAL] Request to share informati

Re: [GENERAL] Request to share information regarding deadlock in postgresql-9.3.6

2016-11-17 Thread Charles Clavadetscher
Rethinking that > -Original Message- > From: pgsql-general-ow...@postgresql.org > [mailto:pgsql-general-ow...@postgresql.org] On Behalf Of Charles > Clavadetscher > Sent: Donnerstag, 17. November 2016 09:12 > To: 'Yogesh Sharma' ; 'John R Pierce'

[GENERAL] max_connections limit violation not showing in pg_stat_activity

2016-11-22 Thread Charles Clavadetscher
using the database, but is the only one where we expect such peaks). So I'd be very grateful for advice on this subject. Thank you. Regards Charles -- Swiss PostgreSQL Users Group c/o Charles Clavadetscher Treasurer Motorenstrasse 18 CH – 8005 Zürich http://w

Re: [GENERAL] max_connections limit violation not showing in pg_stat_activity

2016-11-23 Thread Charles Clavadetscher
Hello Kevin Thank you very much for your input. I appreciate it very much. > -Original Message- > From: Kevin Grittner [mailto:kgri...@gmail.com] > Sent: Dienstag, 22. November 2016 22:37 > To: Charles Clavadetscher > Cc: pgsql-general@postgresql.org > Sub

Re: [GENERAL] Extensions and privileges in public schema

2016-12-05 Thread Charles Clavadetscher
Hello > -Original Message- > From: pgsql-general-ow...@postgresql.org > [mailto:pgsql-general-ow...@postgresql.org] On Behalf Of Paul Ramsey > Sent: Sonntag, 4. Dezember 2016 22:24 > To: Lee Hachadoorian > Cc: pgsql-general > Subject: Re: [GENERAL] Extensions and privileges in public sc

Re: [GENERAL] When to use COMMENT vs --

2016-12-07 Thread Charles Clavadetscher
Hi Rich > -Original Message- > From: pgsql-general-ow...@postgresql.org > [mailto:pgsql-general-ow...@postgresql.org] On Behalf Of Chris Travers > Sent: Mittwoch, 7. Dezember 2016 17:12 > To: Postgres General > Subject: Re: [GENERAL] When to use COMMENT vs -- > > On Dec 7, 2016 5:07 PM,

Re: [GENERAL] Who dropped a role?

2016-12-08 Thread Charles Clavadetscher
Hello From: pgsql-general-ow...@postgresql.org [mailto:pgsql-general-ow...@postgresql.org] On Behalf Of Durumdara Sent: Donnerstag, 8. Dezember 2016 10:13 To: pgsql-general@postgresql.org Subject: Re: [GENERAL] Who dropped a role? Hello! Sorry, meanwhile I found it as Group Role. I ne

Re: [GENERAL] max_connections limit violation not showing in pg_stat_activity

2016-12-08 Thread Charles Clavadetscher
Hello Kevin Getting back at this. > -Original Message- > From: Kevin Grittner [mailto:kgri...@gmail.com] > Sent: Mittwoch, 23. November 2016 17:04 > To: Charles Clavadetscher > Cc: pgsql-general@postgresql.org > Subject: Re: [GENERAL] max_connections limit violat

Re: [GENERAL] Importing SQLite database

2016-12-08 Thread Charles Clavadetscher
Hello > -Original Message- > From: pgsql-general-ow...@postgresql.org > [mailto:pgsql-general-ow...@postgresql.org] On Behalf Of Adrian Klaver > Sent: Donnerstag, 8. Dezember 2016 16:09 > To: Igor Korot > Cc: pgsql-general@postgresql.org > Subject: Re: [GENERAL] Importing SQLite database

Re: [GENERAL] Recursive row level security policy

2016-12-15 Thread Charles Clavadetscher
Hello > -Original Message- > From: pgsql-general-ow...@postgresql.org > [mailto:pgsql-general-ow...@postgresql.org] On Behalf Of Simon Charette > Sent: Freitag, 16. Dezember 2016 06:15 > To: pgsql-general@postgresql.org > Subject: [GENERAL] Recursive row level security policy > > Hello t

Re: [GENERAL] Recursive row level security policy

2016-12-15 Thread Charles Clavadetscher
Hello Simon > -Original Message- > From: pgsql-general-ow...@postgresql.org > [mailto:pgsql-general-ow...@postgresql.org] On Behalf Of Simon Charette > Sent: Freitag, 16. Dezember 2016 07:02 > To: Charles Clavadetscher > Cc: pgsql-general@postgresql.org >

Re: [GENERAL] Recursive row level security policy

2016-12-15 Thread Charles Clavadetscher
Hello again > -Original Message- > From: pgsql-general-ow...@postgresql.org > [mailto:pgsql-general-ow...@postgresql.org] On Behalf Of Charles > Clavadetscher > Sent: Freitag, 16. Dezember 2016 07:41 > To: 'Simon Charette' > Cc: pgsql-general@postgre

Re: [GENERAL] Delete from table conditionally

2016-12-16 Thread Charles Clavadetscher
Hello > -Original Message- > From: pgsql-general-ow...@postgresql.org > [mailto:pgsql-general-ow...@postgresql.org] On Behalf Of Arup Rakshit > Sent: Samstag, 17. Dezember 2016 08:39 > To: Pgsql-general > Subject: [GENERAL] Delete from table conditionally > > Hi, > > I am using Postgre

Re: [GENERAL] Book or other resource on Postgres-local code?

2016-12-29 Thread Charles Clavadetscher
Hi From: pgsql-general-ow...@postgresql.org [mailto:pgsql-general-ow...@postgresql.org] On Behalf Of Guyren Howe Sent: Donnerstag, 29. Dezember 2016 23:32 To: pgsql-general Subject: [GENERAL] Book or other resource on Postgres-local code? As an aside from my last question about my LYDB ef

Re: [GENERAL] performance tuning postgresql 9.5.5.10 [enterprisedb]

2016-12-29 Thread Charles Clavadetscher
Hello > -Original Message- > From: pgsql-general-ow...@postgresql.org > [mailto:pgsql-general-ow...@postgresql.org] On Behalf Of ajmcello > Sent: Freitag, 30. Dezember 2016 05:54 > To: POSTGRES > Subject: [GENERAL] performance tuning postgresql 9.5.5.10 [enterprisedb] > > > I am trying

FW: [GENERAL] performance tuning postgresql 9.5.5.10 [enterprisedb]

2016-12-29 Thread Charles Clavadetscher
Forwarding to list. -Original Message- From: ajmcello [mailto:ajmcell...@gmail.com] Sent: Freitag, 30. Dezember 2016 07:05 To: Charles Clavadetscher Subject: Re: [GENERAL] performance tuning postgresql 9.5.5.10 [enterprisedb] There are no connections except one cli when running the

Re: [GENERAL] Special index for "like"-based query

2016-12-30 Thread Charles Clavadetscher
Hello > -Original Message- > From: pgsql-general-ow...@postgresql.org > [mailto:pgsql-general-ow...@postgresql.org] On Behalf Of Job > Sent: Freitag, 30. Dezember 2016 11:42 > To: Francisco Olarte > Cc: David G. Johnston ; > pgsql-general@postgresql.org > Subject: R: [GENERAL] Special i

Re: [GENERAL]

2015-11-15 Thread Charles Clavadetscher
Hello I never used pg_restore, but I assume that it works similarly to other PG tools, i.e. if you don’t specify a user to connect to the database it will take your unix user name. I assume that your step number 6 is the closing of the shell where you were as user postgres because after 5 yo

Re: [GENERAL]

2015-11-15 Thread Charles Clavadetscher
Instead of creating a superuser you may simply grant the privilege on the database: CREATE ROLE alex LOGIN PASSWORD '...'; GRANT CREATE ON DATABASE icare TO alex; Bye Charles From: pgsql-general-ow...@postgresql.org [mailto:pgsql-general-ow...@postgresql.org] On Behalf

Re: [GENERAL] Transfer db from one port to another

2015-12-23 Thread Charles Clavadetscher
Hello Why don’t you simply change the port in postgresql.conf and restart the server? Bye Charles From: pgsql-general-ow...@postgresql.org [mailto:pgsql-general-ow...@postgresql.org] On Behalf Of Killian Driscoll Sent: Mittwoch, 23. Dezember 2015 09:58 To: pgsql-general Subject: [GEN

Re: [GENERAL] Transfer db from one port to another

2015-12-23 Thread Charles Clavadetscher
Hello Killian >> I want to transfer my db with three schemas from port 5432 to port 5532 to >> use >> within the bitnami stack. I have used pgAdmin to create a backup.sql and when >> using pgAdmin to restore the .sql to port 5532 I get the following error > >Try it with plain pg_dump. > >pg_dump

Re: [GENERAL] Transfer db from one port to another

2015-12-23 Thread Charles Clavadetscher
From: Killian Driscoll [mailto:killiandrisc...@gmail.com] Sent: Mittwoch, 23. Dezember 2015 11:02 To: Charles Clavadetscher Cc: Andreas Kretschmer ; pgsql-general Subject: Re: [GENERAL] Transfer db from one port to another On 23 December 2015 at 10:58, Charles Clavadetscher

Re: [GENERAL] Transfer db from one port to another

2015-12-23 Thread Charles Clavadetscher
From: pgsql-general-ow...@postgresql.org [mailto:pgsql-general-ow...@postgresql.org] On Behalf Of Killian Driscoll Sent: Mittwoch, 23. Dezember 2015 11:19 To: John R Pierce Cc: pgsql-general Subject: Re: [GENERAL] Transfer db from one port to another On 23 December 2015 at 11:07, John R Pier

Re: [GENERAL] Transfer db from one port to another

2015-12-23 Thread Charles Clavadetscher
From: pgsql-general-ow...@postgresql.org [mailto:pgsql-general-ow...@postgresql.org] On Behalf Of Killian Driscoll Sent: Mittwoch, 23. Dezember 2015 11:26 To: John R Pierce Cc: pgsql-general Subject: Re: [GENERAL] Transfer db from one port to another On 23 December 2015 at 11:19, Killian

Re: [GENERAL] Transfer db from one port to another

2015-12-23 Thread Charles Clavadetscher
We had that already upthread. Did you set the path to the bin dir of PostgreSQL as of previous posts? Regards Charles From: pgsql-general-ow...@postgresql.org [mailto:pgsql-general-ow...@postgresql.org] On Behalf Of Killian Driscoll Sent: Mittwoch, 23. Dezember 2015 15:14 To: Adrian Klav

Re: [GENERAL] Strange syntax with select

2015-12-25 Thread Charles Clavadetscher
Hello I am not in clear what your use case is, but you may have a look at that: http://www.depesz.com/2013/02/25/variables-in-sql-what-how-when/ The bottom line is that in a psql interactive session you cannot really set a variable as the result of a select statement (or at least I did

Re: [GENERAL] How do I implement a .XSD in Postgres?

2016-01-01 Thread Charles Clavadetscher
Hello XML is an extensible object description language and XSD is not an XML derivative, but an implementation of the XML extensibility as a replacement for DTD. It is finally nothing else than an XML file following the validation schema of itself ( http:/

Re: [GENERAL] Function error

2016-01-07 Thread Charles Clavadetscher
Hello If I understand you correctly you have two functions create_catexp_ss_1 and create_catexp_ss_2 that you then call from create_catexp_master. If so then you probably need to change the call to them: > -- Exposure for single supplier without category filtering >

Re: [GENERAL] Slow Query - PostgreSQL 9.2

2016-01-10 Thread Charles Clavadetscher
Hello > -Original Message- > From: pgsql-general-ow...@postgresql.org > [mailto:pgsql-general-ow...@postgresql.org] On Behalf Of Saulo Merlo > Sent: Montag, 11. Januar 2016 08:12 > To: Vitaly Burovoy > Cc: pgsql-general@postgresql.org > Subject: Re: [GENERAL] Slow Query - PostgreSQL 9.2

Re: [GENERAL] Giving error for function

2016-01-12 Thread Charles Clavadetscher
Hello > -Original Message- > From: pgsql-general-ow...@postgresql.org > [mailto:pgsql-general-ow...@postgresql.org] On Behalf Of Sachin Srivastava > Sent: Dienstag, 12. Januar 2016 08:40 > To: pgsql-general@postgresql.org >> PG-General Mailing List > > Subject: [GENERAL] Giving error fo

Re: [GENERAL] ERROR: check constraint - PostgreSQL 9.2

2016-01-24 Thread Charles Clavadetscher
Hello Althought both options are technically correct, I guess that the first one is the only reasonable one. What is the point of having a check constraint that is not checked? If all fields in the check constraint must not be null there must be a reason for it. Possibly the "wrong" data is usel

Re: [GENERAL] ERROR: check constraint - PostgreSQL 9.2

2016-01-25 Thread Charles Clavadetscher
.2 > > On 1/24/16, Christophe Pettus wrote: > > > > On Jan 24, 2016, at 9:01 PM, Charles Clavadetscher > > wrote: > > > >> What is the point of having a check constraint that is not checked? > > > > Well, it *is* checked going into the

Re: [GENERAL] ERROR: missing FROM-clause entry for table

2016-02-09 Thread Charles Clavadetscher
Hello > -Original Message- > From: pgsql-general-ow...@postgresql.org > [mailto:pgsql-general-ow...@postgresql.org] On Behalf Of bigkev > Sent: Mittwoch, 10. Februar 2016 08:11 > To: pgsql-general@postgresql.org > Subject: [GENERAL] ERROR: missing FROM-clause entry for table > > I am rec

Re: [GENERAL] CONCAT returns null

2016-02-28 Thread Charles Clavadetscher
Hello Just a short question to that. > CONCAT(f.nrfo, '/', TO_CHAR(fd1.validfrom, '-MM-DD'), f2.nrfo, > TO_CHAR(fd7.validfrom, '-MM-DD'), > DATE(fd5.validto)-DATE(fd1.validfrom)) > that works fine but when I change to this(I added a ' with '): > ARRAY_AGG(CONCAT(f.nrfo, '/', TO_CHAR(fd1.

Re: [GENERAL] CONCAT returns null

2016-02-28 Thread Charles Clavadetscher
Hello again > -Original Message- > From: pgsql-general-ow...@postgresql.org > [mailto:pgsql-general-ow...@postgresql.org] On Behalf Of Charles > Clavadetscher > Sent: Sonntag, 28. Februar 2016 11:24 > To: 'Sterpu Victor' ; 'PostgreSQL General' >

Re: [GENERAL] CONCAT returns null

2016-02-28 Thread Charles Clavadetscher
Hello > -Original Message- > From: pgsql-general-ow...@postgresql.org > [mailto:pgsql-general-ow...@postgresql.org] On Behalf Of Andreas Kretschmer > Sent: Sonntag, 28. Februar 2016 11:30 > To: pgsql-general@postgresql.org > Subject: Re: [GENERAL] CONCAT returns null > > Sterpu Victor w

  1   2   >