Re: [GENERAL] pg_dump not dropping event trigger

2017-07-22 Thread Tom Lane
Greg Atkins writes: > I have a DB with an event trigger, which I am dumping with > pg_dump -Fc --no-acl --no-owner [db_name] > [dump_file] > In my dump file, I can't find any DROP EVENT TRIGGER statement. Well, you wouldn't, for lack of -c ... but yes, it seems you

[GENERAL] pg_dump not dropping event trigger

2017-07-22 Thread Greg Atkins
I have a DB with an event trigger, which I am dumping with pg_dump -Fc --no-acl --no-owner [db_name] > [dump_file] In my dump file, I can't find any DROP EVENT TRIGGER statement. In src/bin/pg_dump/pg_dump.c, dumpEventTrigger() calls ArchiveEntry() with a "" argument for the dropStmt

[GENERAL] Exclude posts which was from blacklisted users Sql help

2017-07-22 Thread Arup Rakshit
Hello, Below is my table structure: musedb_dev=# \d kudosposts Table "public.kudosposts" Column|Type |Modifiers

Re: [GENERAL] Backward compatibility

2017-07-22 Thread Igor Korot
Thx. The split_part() works perfectly. On Sat, Jul 22, 2017 at 10:49 AM, Tom Lane wrote: > Igor Korot writes: >> But it works incorrectly - it should return: >> 9.5.7 on x86_64-redhat-linux-gnu, compiled by gcc (GCC) 6.3.1 20161221 >> (Red Hat 6.3.1-1),

Re: [GENERAL] Backward compatibility

2017-07-22 Thread rob stone
On Sat, 2017-07-22 at 10:49 -0400, Tom Lane wrote: > Igor Korot writes: > > But it works incorrectly - it should return: > > 9.5.7 on x86_64-redhat-linux-gnu, compiled by gcc (GCC) 6.3.1 > > 20161221 > > (Red Hat 6.3.1-1), 64-bit > > i.e. without the word "PosgreSQL", since

Re: [GENERAL] Backward compatibility

2017-07-22 Thread Tom Lane
Igor Korot writes: > But it works incorrectly - it should return: > 9.5.7 on x86_64-redhat-linux-gnu, compiled by gcc (GCC) 6.3.1 20161221 > (Red Hat 6.3.1-1), 64-bit > i.e. without the word "PosgreSQL", since '\s' should match the (first) > space in the version(). position()

Re: [GENERAL] Backward compatibility

2017-07-22 Thread Igor Korot
Hi, John, On Sat, Jul 22, 2017 at 8:44 AM, John McKown wrote: > On Fri, Jul 21, 2017 at 10:21 PM, Igor Korot wrote: >> >> Hi, guys, >> Below query does not even run: >> >> SELECT version(), substring( version() from position( '\s' in version() )

Re: [GENERAL] Backward compatibility

2017-07-22 Thread John McKown
On Fri, Jul 21, 2017 at 10:21 PM, Igor Korot wrote: > Hi, guys, > Below query does not even run: > > SELECT version(), substring( version() from position( '\s' in version() ) > ); > > Could you spot the error? > > ​works for me. psql psql (9.5.7) Type "help" for help.

Re: [GENERAL] Postgres csv logging

2017-07-22 Thread Alessandro_feliz
Hi David, thank you for your reply. David G Johnston wrote > As the comment there says your config and your output seem at odds. What I showed was the output present in the csv log, the output in the text file log has the prefix that I indicated in the configration file. Either way, I managed