On Sat, Feb 28, 2015 at 2:39 PM, inspector morse
wrote:
>
> Is it a good idea to write a simple application (consisting of just data
> entry interfaces) in pure pgsql?
>
> Basically, we would have each page has a stored function in postgresql that
> is called by php+apache (the http get/post value
On Thu, Mar 5, 2015 at 8:58 AM, Igor Neyman wrote:
> From: pgsql-general-ow...@postgresql.org
> [mailto:pgsql-general-ow...@postgresql.org] On Behalf Of inspector morse
> Sent: Thursday, March 05, 2015 9:21 AM
> To: pgsql-general@postgresql.org
> Subject: [GENERAL] Sharing data between stored func
On Sat, Mar 14, 2015 at 7:21 PM, Denver Timothy wrote:
> In 9.4.1, I do this:
>
> CREATE TYPE my_test_type as (part1 text, part2 text);
>
> \pset null NULL
>
> WITH test_table(test_col) AS (
> VALUES (NULL::my_test_type), (ROW(NULL, NULL)::my_test_type)
> )
> SELECT *, (test_col).part1, (test_
On Fri, Mar 27, 2015 at 1:36 PM, Arthur Silva wrote:
> On Fri, Mar 27, 2015 at 1:56 PM, Deven Phillips
> wrote:
>>
>> Are there any plans or ideas about implement JSON Patch
>> (http://jsonpatch.com/) support for PostgreSQL? We deal with some relatively
>> large JSON documents for our in-house ap
On Mon, Mar 30, 2015 at 6:27 AM, Deven Phillips
wrote:
> I have a multi-table join which will return 1 row per "interface" and I
> would like to aggregate the interfaces as a nested section on the resulting
> JSON output. Could someone help me to figure out how to accomplish that?
>
> Example:
>
>
On Mon, Mar 30, 2015 at 12:54 PM, Deven Phillips
wrote:
> Hi all,
>
> I have a query which selects several rows of data, and contained in one
> of those rows is some aggregated JSON data. I am using row_to_json() to make
> the whole output JSON and I am providing "true" for pretty formatting o
On Mon, Mar 30, 2015 at 4:22 PM, Deven Phillips
wrote:
> I'm using PostgreSQL 9.4.1 on Ubuntu 14.10.
>
> The function does the following:
>
> DROP FUNCTION get_vm_with_interfaces(vm_id BIGINT);
>
> CREATE OR REPLACE FUNCTION get_virtual_interfaces(vm_id BIGINT) RETURNS
> jsonb AS $$
> DECLARE
>
On Mon, Mar 30, 2015 at 3:30 PM, Adrian Klaver
wrote:
> On 03/30/2015 10:54 AM, Deven Phillips wrote:
>>
>> Hi all,
>>
>> I have a query which selects several rows of data, and contained in
>> one of those rows is some aggregated JSON data. I am using row_to_json()
>> to make the whole output
On Sat, Apr 18, 2015 at 5:37 PM, Jim Nasby wrote:
> On 4/18/15 12:47 AM, David G. Johnston wrote:
>>
>> If you could find a way to pass a value of type some_table into the
>> function - instead of the name/text 'some_table‘ - you could possibly
>> use polymorphic pseudotypes...just imagining here
On Mon, Apr 20, 2015 at 11:40 AM, David G. Johnston
wrote:
> On Mon, Apr 20, 2015 at 7:57 AM, Merlin Moncure wrote:
>>
>> On Sat, Apr 18, 2015 at 5:37 PM, Jim Nasby
>> wrote:
>> > On 4/18/15 12:47 AM, David G. Johnston wrote:
>> >>
>> &g
On Wed, May 6, 2015 at 1:56 AM, Mitu Verma wrote:
> Thank you so much all of you.
>
> Table audittraillogentry have PRIMARY KEY and FOREIGN KEY defined, below is
> the detail of existing table audittraillogentry.
>
> As you can see ., it is referenced by 2 tables , "cdrdetails" and
> "cdrlogentr
have a read:
http://www.techrepublic.com/article/postgres-pushes-past-mysql-in-developer-hearts/
merlin
--
Sent via pgsql-general mailing list (pgsql-general@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general
On Thu, Jun 18, 2015 at 7:50 AM, Chris Travers wrote:
>
> On Thu, Jun 18, 2015, 14:38 Sven Geggus wrote:
>
> Hello,
>
> I supose this is simple, but I did not find a solution in the documentation.
>
> Because you already are returning 2 columns.
>
> I would like to be able to do something like th
On Tue, Jun 23, 2015 at 5:56 PM, Ted Toth wrote:
> What are peoples experiences with either/both, pluses/minuses?
If you're coding at the C level, I would definitely choose libpq
unless you were worried about cross database portability. libpq is a
bit clunky but easy to code against. libpq is
On Thu, Jun 25, 2015 at 1:59 PM, Алексей Бережняк wrote:
> I think that PostgreSQL is great RDBMS, but one important (for me)
> feature that it missing is case-insensitive identifier quotes
> ([table].[column]) like in Microsoft SQL Server.
>
> I know that there are double quotes, but they are cas
On Tue, Jul 28, 2015 at 8:34 AM, Christian Ramseyer wrote:
> On 22/06/15 13:51, Christian Ramseyer wrote:
>> Hi
>>
>> I have a pretty large table with syslog messages.
>>
>> It is already partitioned by month, and for a single month I have e.g.
>>
>>
>> DM=# \d+ logs_01
>>
>> Column|
On Thu, Jul 30, 2015 at 9:19 AM, John Scalia wrote:
> Seconding Peter on this one; it's a lot more important should one of those
> locks be hanging around, say for hours or days, not how many have come and
> gone.
Also, it's good to focus on *ungranted* locks. Typically the only
time I care abo
http://www.spinics.net/lists/raid/msg49452.html (via slashdot)
merlin
--
Sent via pgsql-general mailing list (pgsql-general@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general
On Wed, Aug 19, 2015 at 5:55 AM, tonymark09 wrote:
> Hello,
>
> Is preparing a statement using PQexec and executing it is much slower that
> using other API such as PQprepare and PQexecPrepared?
PQexec can be faster than a combination of PQprepare and
PQexecPrepared particularly if you only need
On Tue, Aug 25, 2015 at 8:33 AM, Johann Spies wrote:
> I have a long-running query (running now for more than 6 days already
> (process 17434). It involves three tables of which one contains XML-data.
>
> On another, unrelated table with 30718567 records, I ran a query to create
> an index on a
On Tue, Aug 25, 2015 at 7:04 PM, Edson Richter wrote:
> Any chance to get those amazing wonderful features backported to 9.4?
you might have some luck merging in the feature yourself if you're so inclined.
merlin
--
Sent via pgsql-general mailing list (pgsql-general@postgresql.org)
To make ch
On Mon, Sep 7, 2015 at 12:07 AM, Tom Smith wrote:
> Hi:
>
> I am using the wonderful lateral query feature like the following
>
> select * from generate_series (1,10,5) T(t),
>lateral (select * from P where t between t and t + 3)
>
> P is a parent table of a hundred partitions
> the id
On Tue, Sep 8, 2015 at 3:24 PM, Tom Smith wrote:
> On Tue, Sep 8, 2015 at 3:51 PM, Merlin Moncure wrote:
>> On Mon, Sep 7, 2015 at 12:07 AM, Tom Smith
>> > How to force query planner "dynamically" generate plan to
>> > for each lateral select query as "
On Sat, Sep 5, 2015 at 3:28 PM, Albe Laurenz wrote:
> Pavel Suderevsky wrote:
>> When I have been passing through "Understanding explain" manual
>> (http://www.dalibo.org/_media/understanding_explain.pdf)
>> I've faced some strange situation when table with size of 65MB completely
>> placed in c
On Wed, Sep 23, 2015 at 8:38 AM, Etienne Champetier
wrote:
> Two questions:
> 1) Is it normal to have such a big difference between OR and UNION and
> should i always prefer UNION when possible?
yes, it's unfortunate but true. I consider automatic transformation
of these expressions to possible
On Monday, October 12, 2015, Lele Gaifax wrote:
> Adrian Klaver > writes:
>
> > Off hand I would say it is because of this --> count(m.num). Try
> count(l.num) instead and see
> > what happens. As your queries above show they are the same number.
>
> No, that's another thing I already tried tweak
On Tue, Oct 13, 2015 at 11:54 AM, Alvaro Herrera
wrote:
> Lele Gaifax wrote:
>> Alvaro Herrera writes:
>>
>> > So 10% of your rows in the master_l10n table start with "quattro"?
>> > That's pretty odd, isn't it? How did you manufacture these data?
>>
>> Well, not a real scenario for sure, but de
On Tue, Oct 20, 2015 at 3:14 AM, Birta Levente wrote:
> Hi
>
> I have a supermicro SYS-1028R-MCTR, LSI3108 integrated with SuperCap module
> (BTR-TFM8G-LSICVM02)
> - 2x300GB 10k spin drive, as raid 1 (OS)
> - 2x300GB 15k spin drive, as raid 1 (for xlog)
> - 2x200GB Intel DC S3710 SSD (for DB), as
On Tue, Oct 20, 2015 at 10:14 AM, Tomas Vondra
wrote:
> Hi,
>
> On 10/20/2015 03:30 PM, Merlin Moncure wrote:
>>
>> On Tue, Oct 20, 2015 at 3:14 AM, Birta Levente
>> wrote:
>>>
>>> Hi
>>>
>>> I have a supermicro SYS-1028R-MCTR, LSI3
On Tue, Oct 20, 2015 at 9:45 AM, Dane Foster wrote:
> Hello,
>
> I'm in the very very very very early stages of migrating a MySQL/PHP app to
> PostgreSQL/PHP/Lua. Because we are moving to PostgreSQL one of the [many]
> things I intend to change is to move ALL the SQL code/logic out of the
> applic
On Tue, Oct 20, 2015 at 12:28 PM, Scott Marlowe wrote:
>> On Tue, Oct 20, 2015 at 9:33 AM, Scott Marlowe
>> wrote:
>>> We're running LSI MegaRAIDs at work with 10 SSD RAID-5 arrays, and we
>>> can get ~5k to 7k tps on a -s 1 pgbench with the write cache on.
>>>
>>> When we turn the write cac
On Wed, Oct 21, 2015 at 10:24 AM, Dane Foster wrote:
> For posterity here is the final version. I ran it through PostgreSQL
> 9.5beta1 this morning so it's at least syntactically valid. Additionally I
> went w/ a list of INTO targets instead of a RECORD because it's a more
> elegant solution in th
On Tue, Oct 27, 2015 at 12:14 PM, Bill Moran wrote:
> On Tue, 27 Oct 2015 11:30:45 +0800
> "657985...@qq.com" <657985...@qq.com> wrote:
>
>> Dear sir:
>> Recently a wired question about postgresql database really bothered
>> me a lot, so i really need your help. Here is the problem, in t
On Tue, Oct 27, 2015 at 2:33 PM, Jeff Janes wrote:
> On Mon, Oct 26, 2015 at 8:30 PM, 657985...@qq.com <657985...@qq.com> wrote:
>>
>> Dear sir:
>> Recently a wired question about postgresql database really
>> bothered me a lot, so i really need your help. Here is the problem, in the
>> m
On Tue, Oct 27, 2015 at 4:04 PM, Merlin Moncure wrote:
> On Tue, Oct 27, 2015 at 2:33 PM, Jeff Janes wrote:
>> On Mon, Oct 26, 2015 at 8:30 PM, 657985...@qq.com <657985...@qq.com> wrote:
>>>
>>> Dear sir:
>>> Recently a wired question about po
On Mon, Nov 2, 2015 at 4:14 PM, droberts wrote:
> Hi, I have a table that contains call records. I'm looking to get only
> records for users who made the most calls over a particular time duration in
> an efficient way.
>
> calls()
>
> time, duration, caller_number, dialed_number
>
>
>
> -- qu
On Tue, Nov 3, 2015 at 9:57 AM, Vick Khera wrote:
>
> On Tue, Nov 3, 2015 at 10:07 AM, Sami Pietilä
> wrote:
>>
>> Unfortunately I could not figure out how to select rows which, for
>> example, contain following json: '{"a":"world","c":{"b":"helloworld"}}' by
>> search with "hello" string.
>
> ca
On Sun, Nov 8, 2015 at 7:22 AM, 莎士比亚说: <657985...@qq.com> wrote:
> Hi moran and others;
>
> yesterday i get the pg problem again, and i use perf top Observation
> follows:
> PerfTop: 11574 irqs/sec kernel: 2.2% exact: 0.0% [4000Hz cycles],
> (all, 32 CPUs)
> 81.39% postgres [.
On Tue, Nov 10, 2015 at 8:26 AM, Merlin Moncure wrote:
> On Sun, Nov 8, 2015 at 7:22 AM, 莎士比亚说: <657985...@qq.com> wrote:
>> Hi moran and others;
>>
>> yesterday i get the pg problem again, and i use perf top Observation
>> follows:
>> PerfTop: 11
On Wed, Nov 11, 2015 at 3:44 AM, Dusan wrote:
> Hi,
> I'm using table with parent_id to themselve and WITH RECURSIVE in SELECT on
> about 3thousands records.
> The "tree" of data is wide (each node has more children) but not deep
> (maximal depth of branch is 10 nodes).
>
> I'm planning to use sam
On Tue, Nov 10, 2015 at 12:26 PM, Adrian Klaver
wrote:
> On 11/10/2015 10:21 AM, Mammarelli, Joanne T wrote:
>>
>> Hi .. we’re on a hunt to locate either pgloader or the tds_fdw extension
>> to assist us with pulling data FROM a Microsoft sql server (we’re a
>> windows-based postgres installation)
On Fri, Nov 13, 2015 at 7:20 AM, Leonardo M. Ramé wrote:
> Hi, is there a way to get an array converted to json without brackets?.
>
> I'm getting, for example [{"field": "value"}, {"field": "value"}] and I want
> to get this: {"field": "value"}, {"field": "value"}.
please supply an example. Als
On Thu, Jun 2, 2016 at 1:14 AM, Dmitry Igrishin wrote:
> Hi,
>
> It's possible to query pg_prepared_statements view to obtain the
> information about
> parameters used in the statement that was prepared. But I don't found
> how to get the
> information about the rows that will be returned when the
On Thu, Jun 2, 2016 at 6:54 PM, Michael Paquier
wrote:
> On Fri, Jun 3, 2016 at 8:48 AM, David G. Johnston
> wrote:
>> On Thu, Jun 2, 2016 at 7:39 PM, Michael Paquier
>> wrote:
>> I was focused on admin task due to the pg_ctl (not sure you'd want to run
>> that via psql...) but if you have shell
On Tue, Jun 14, 2016 at 4:59 PM, Catalin Maftei wrote:
> when I recreate a VIEW or FUNCTION with a small change I get:
>
> Query returned successfully with no result in 03:58 minutes.
This is almost certainly due to locks. Next time this happens, query
pg_stat_activity and pg_locks -- the inform
On Thu, Jun 16, 2016 at 6:55 PM, Melvin Davidson wrote:
You have not provided information as to the O/S of the PostgreSQL
server or your PgAdmin remote system (I suspect Windows), but
regardless, you
> are just asking for trouble by doing development over a remote connection.
> You should verify
On Wed, Jun 29, 2016 at 1:46 PM, Neil Anderson wrote:
> On 2016-06-29 12:37 PM, Mark Morgan Lloyd wrote:
>>
>> Elsewhere, somebody was asking how people implemented version control
>> for stored procedures on (MS) SQL Server.
>>
>> The consensus was that this is probably best managed by using scri
On Fri, Jul 1, 2016 at 12:17 PM, Sfiligoi, Igor wrote:
> Hello.
>
> We have a view that is very generic, and we noticed that PostgreSQL is not
> very good at removing useless joins, which makes our queries very slow.
>
> We could change our code to avoid the view and write ad-hoc queries to the
>
On Thu, Jul 7, 2016 at 6:12 AM, FarjadFarid(ChkNet)
wrote:
>
>
> Hi Álvaro,
>
> Based on the article. This research has been tested with various hardware.
> The code automatically detects the hardware and based on the size of memory
> to be copied it will choose one of 3 routines.
>
> Regarding li
On Thu, Jul 7, 2016 at 1:18 PM, Alvaro Herrera wrote:
> Tom Lane wrote:
>
>> You might have better luck with "psql -n", or maybe not.
>
> I've wished sometimes for a "\set READLINE off" psql metacommand for
> this kind of thing. It's pretty annoying when the text being pasted
> contains tabs and
On Thu, Jul 7, 2016 at 2:48 PM, Alvaro Herrera wrote:
> Merlin Moncure wrote:
>> On Thu, Jul 7, 2016 at 1:18 PM, Alvaro Herrera
>> wrote:
>> > Tom Lane wrote:
>> >
>> >> You might have better luck with "psql -n", or maybe not.
>>
On Mon, Aug 8, 2016 at 7:25 PM, Xtra Coder wrote:
> Hi,
>
> I'm just curious about the reasons of the design of 'DO' statement so that
> it is not able to return result of the SELECT in its body.
>
> References:
> https://www.postgresql.org/docs/current/static/sql-do.html
>
> http://stackoverf
pe variables, 'DO' is just
>> not needed after that
>> - SELECTs not targeted into a variable - are written to client output
>> - (C) Merlin Moncure - "Ability to embed collection of statements in the
>> database under a name and invoke those statements via CAL
On Thu, Aug 11, 2016 at 8:45 AM, Tom Lane wrote:
> Jim Nasby writes:
>> I never dug into why. As Tom posited, decompression might explain the
>> time to get a single key out. Getting 10 keys instead of just 1 wasn't
>> 10x more expensive, but it was significantly more expensive than just
>> getti
On Fri, Aug 19, 2016 at 2:32 AM, Thomas Güttler
wrote:
> I want to store logs in a simple table.
>
> Here my columns:
>
> Primary-key (auto generated)
> timestamp
> host
> service-on-host
> loglevel
> msg
> json (optional)
>
> I am unsure which DB to choose: Postgres, ElasticSearch o
On Fri, Aug 26, 2016 at 10:50 AM, Cachique wrote:
> Hi
> From the documentation... (
> https://www.postgresql.org/docs/current/static/sql-select.html )
>
> 'Function calls can appear in the FROM clause. (This is especially useful
> for functions that return result sets, but any function can be use
On Mon, Aug 29, 2016 at 6:28 AM, Tom Lane wrote:
> Pavel Stehule writes:
>> 2016-08-29 1:59 GMT+02:00 Jim Nasby :
>>> It would be nice if there was a way to pass dynamically formed records
>>> around, similar to how you can pass the results of row() around. Someone
>>> else has actually be asking
On Sat, Aug 27, 2016 at 5:39 AM, Alexander Farber
wrote:
> Hello,
>
> what do you use to retrieve a jsonb column using JDBC?
>
> I have tried
>
> Object last_tiles = rs.getObject("last_tiles");
>
> and the resulting Object seems to be a String.
>
> Then I have called (using Jetty JSON clas
Fri, Sep 2, 2016 at 6:55 PM, Jim Nasby wrote:
> On 8/29/16 6:28 AM, Tom Lane wrote:
>>
>> Pavel Stehule writes:
>>>
>>> > 2016-08-29 1:59 GMT+02:00 Jim Nasby :
>> It would be nice if there was a way to pass dynamically formed
>> records
>> around, similar to how you can pass
On Tue, Sep 6, 2016 at 11:12 PM, Pradeep wrote:
> Dear Naveed,
>
> I am using PostgreSQL 9.3 version on Windows .After changing these
> parameters, I have not seen any resource management utilization.
>
> I have observed before and after changing the parameter values ,it is not
> reflecting the m
On Fri, Sep 9, 2016 at 8:30 AM, Tim Uckun wrote:
> I am trying to get the child elements of a one to many table to be rolled up
> into a json field in the parent table. The query I am running is
>
> select
> ob.id
> ,case when array_position(array_agg(im.image_type), null) = 1 then
> '[]
On Mon, Sep 12, 2016 at 9:03 AM, Vinicius Segalin wrote:
> Hi everyone,
>
> I'm trying to find a way to predict query runtime (I don't need to be
> extremely precise). I've been reading some papers about it, and people are
> using machine learning to do so. For the feature vector, they use what th
On Wed, Oct 5, 2016 at 3:27 PM, Stephen Frost wrote:
> Darren,
>
> * Darren Lafreniere (dlafreni...@onezero.com) wrote:
>> Tom Lane wrote:
>> > > Gavin Wahl wrote:
>> > >> It seems trivial to accelerate a MAX or MIN query with a BRIN index. You
>> > >> just find the page range with the largest/sm
On Wed, Oct 5, 2016 at 5:38 AM, Tomáš Uko wrote:
> Hi Jeff,
>
>
>
> We have encountered same problem as you (in 9.5.4), it seems that so far it
> hasn’t been ported back from 9.6, but if you take this commit and apply it
> to 9.5 source codes, it seems to be working
>
> But anyway, does anybody kn
On Thu, Oct 6, 2016 at 4:21 AM, Geoff Winkless wrote:
> Hi
>
> I have code that does (inside a single transaction)
>
> DROP TABLE IF EXISTS mytable; CREATE TABLE mytable
>
> Occasionally this produces
>
> ERROR: duplicate key value violates unique constraint
> "pg_type_typname_nsp_index" DETA
On Sun, Oct 9, 2016 at 10:10 PM, Sebastian P. Luque wrote:
> On Sun, 09 Oct 2016 16:00:21 -0400,
> Tom Lane wrote:
>
>> "Sebastian P. Luque" writes:
>>> Tom Lane wrote:
On closer inspection, the error is only in the
aggregate-used-as-window-function case, not plain aggregation.
>
>>>
On Tue, Oct 18, 2016 at 12:00 PM, Nicolas Paris wrote:
> Hello,
>
> I want to minimize postgresql json size when I fetch them.
> I translate columnar table to json thought json_build_object/array or even
> row_to_jeon.
>
> While row_to_json do have a "pretty_bool" option, the latter do not. Each
>
On Thu, Oct 27, 2016 at 10:01 AM, Francisco Olarte
wrote:
> And I'd like to point libpq sessions does not sound to be the best
> kind of traffic across a firewall, not a good service / protocol to
> expose.
meh -- it's perfectly fine to expose postgres to the internet as long
as you've handled th
On Thu, Oct 27, 2016 at 11:18 AM, Francisco Olarte
wrote:
> Merlin:
>
> On Thu, Oct 27, 2016 at 6:10 PM, Merlin Moncure wrote:
>> On Thu, Oct 27, 2016 at 10:01 AM, Francisco Olarte
>> wrote:
>>> And I'd like to point libpq sessions does not sound to be th
On Thu, Oct 27, 2016 at 12:45 PM, Francisco Olarte
wrote:
> Merlin:
>
> On Thu, Oct 27, 2016 at 7:29 PM, Merlin Moncure wrote:
>> On Thu, Oct 27, 2016 at 11:18 AM, Francisco Olarte
>> wrote:
>>> It is, but handling them is not easy, and you have to deal with thi
On Fri, Oct 28, 2016 at 1:17 PM, Tom Lane wrote:
> Scott Marlowe writes:
>> On Fri, Oct 28, 2016 at 10:29 AM, Kim Rose Carlsen wrote:
>>> I was wondering if there is a way to hint that two columns in two different
>>> tables IS NOT DISTINCT FROM each other. So that the optimizer may assume if
>>
On Fri, Oct 28, 2016 at 1:20 PM, Merlin Moncure wrote:
> On Fri, Oct 28, 2016 at 1:17 PM, Tom Lane wrote:
>> Scott Marlowe writes:
>>> On Fri, Oct 28, 2016 at 10:29 AM, Kim Rose Carlsen wrote:
>>>> I was wondering if there is a way to hint that two columns in tw
On Fri, Oct 28, 2016 at 2:54 PM, Kim Rose Carlsen wrote:
>> > On Fri, Oct 28, 2016 at 10:29 AM, Kim Rose Carlsen wrote:
>
>> > Hi
>> >
>> > I was wondering if there is a way to hint that two columns in two
>> > different
>> > tables IS NOT DISTINCT FROM each other. So that the optimizer may assum
On Sat, Oct 29, 2016 at 8:27 AM, Kim Rose Carlsen wrote:
>>> This doesn't do much good. This doesn't tell the planner that the 3
>
>>> customer_ids are actually of same value, and it therefore can't filter
>>> them
>>> as it sees fit.
>
>> You do know you can index on a function, and the planner t
On Mon, Oct 31, 2016 at 9:28 AM, Kim Rose Carlsen wrote:
> On Sat, Oct 29, 2016 at 8:27 AM, Kim Rose Carlsen wrote:
>
>> > I have tried creating a function called
>> > zero_if_null(int) : int that just select COALESCE($1, 0)
>> > and adding a index on (zero_if_null(customer_id)) on table that con
On Fri, Nov 4, 2016 at 8:08 AM, Kim Rose Carlsen wrote:
>>> It might raise another problem, that the nulls are generated through LEFT
>
>>> JOINS where no rows are defined. Then the 0 or -1 value need to be
>>> a computed value. Won't this throw off index lookups? (I might be
>>> more confused in
On Fri, Nov 4, 2016 at 9:38 AM, Alban Hertroys wrote:
> On 4 November 2016 at 14:41, Merlin Moncure wrote:
>> On Fri, Nov 4, 2016 at 8:08 AM, Kim Rose Carlsen wrote:
>>> The nulls are generated by something like this
>>> SELECT c.circuit_id,
>>&g
On Friday, November 11, 2016, Andreas Brandl wrote:
> Hi,
>
> we have a pretty big table with an integer-type primary key. I'm looking
> for the quickest way to change the column type to bigint to avoid hitting
> the integer limit. We're trying to avoid prolonged lock situations and full
> table
On Fri, Nov 11, 2016 at 9:30 AM, Andreas Brandl wrote:
> Hi,
>
> we have a pretty big table with an integer-type primary key. I'm looking for
> the quickest way to change the column type to bigint to avoid hitting the
> integer limit. We're trying to avoid prolonged lock situations and full tabl
On Tue, Nov 29, 2016 at 6:56 PM, rob stone wrote:
> Hello Michael,
> On Tue, 2016-11-29 at 19:10 -0500, Michael Sheaver wrote:
>> Greetings,
>>
>> I have two tables that are populated using large datasets from
>> disparate external systems, and I am trying to match records by
>> customer name betw
On Wed, Nov 30, 2016 at 7:43 AM, Raymond O'Donnell wrote:
> On 30/11/16 12:05, Thomas Kellerer wrote:
>>
>> Tobia Conforto schrieb am 30.11.2016 um 12:15:
>>>
>>> I think MONEY is a great datatype, at least in theory.
>>
>>
>> I personally find it pretty useless to be honest - especially because
>
On Wed, Nov 30, 2016 at 10:42 AM, Tom Lane wrote:
> George writes:
>> explain select * from wg3ppbm_transaction where partner_uuid in (
>> select p.uuid
>> from wg3ppbm_userpartner up
>> join wg3ppbm_partner p on p.id = up.partner_id
>> );
>
>> "Hash Semi Join
On Wed, Nov 30, 2016 at 11:05 AM, George wrote:
> On Wed, Nov 30, 2016 at 6:45 PM, Merlin Moncure wrote:
>> On Wed, Nov 30, 2016 at 10:42 AM, Tom Lane wrote:
>>> George writes:
>>>> explain select * from wg3ppbm_transaction where partner_uuid in (
On Wed, Nov 30, 2016 at 12:15 PM, David G. Johnston
wrote:
> On Wed, Nov 30, 2016 at 8:15 AM, bto...@computer.org
> wrote:
>>
>> 5. Use a CTE:
>>
>> with shortnames as (
>> select to_char(impressions_create_date,'-mm-dd') as ymd from
>> impressionsdb
>> ) select ymd from shortname
On Wed, Nov 30, 2016 at 2:16 PM, John McKown
wrote:
> On Wed, Nov 30, 2016 at 1:23 PM, bto...@computer.org
> wrote:
> Speaking generically, I guess maybe MONEY needs to be somewhat like a
> TIMESTAMP. At least in PostgreSQL, a TIMESTAMP can contain a TIMEZONE. I
> guess a MONEY type should contai
On Wed, Dec 7, 2016 at 9:57 AM, Rich Shepard wrote:
> I have used '-- ' to enter comments about tables or columns and am curious
> about the value of storing comments in tables using the COMMENT key word.
> When is the latter more appropriate than the former?
Main advantage of COMMENT is that t
On Wed, Dec 7, 2016 at 4:10 AM, Tom DalPozzo wrote:
> Hi,
> I tried both ways: they're ok.
> Also, multiple VALUES in one INSERT is actually better as performance.
If you are chasing performance with the binary protocol you might want
to take a look at libpqtypes: http://libpqtypes.esilo.com/
It
On Wed, Dec 28, 2016 at 3:15 AM, Tim Uckun wrote:
> I have seen various links on the internet which indicate that PLV8 is
> significantly faster than PL-PGSQL sometimes an order of magnitude faster.
>
> Is this uniformly true or is it just in certain circumstances?
>
> Is there any benefit to choo
On Wed, Jan 4, 2017 at 8:49 AM, Kevin Grittner wrote:
> On Wed, Dec 28, 2016 at 10:58 AM, Steven Grimm wrote:
>
>> WHERE ((e.timeStamp > '2016-12-19T20:34:22.315Z')
>> OR (e.timeStamp = '2016-12-19T20:34:22.315Z'
>> AND e.sequenceNumber > 0)
>> OR (e.timeStamp = '2016-
On Fri, Jan 6, 2017 at 4:09 AM, Pierre Ducroquet
wrote:
> Hi
>
> Running PostgreSQL 9.4, I am running in the following issue.
> On a huge table, I have to remove the content (set to '') of a column that
> makes for 99% of the weight of the table. Since the production can not be
> stopped, I will n
On Thu, Dec 29, 2016 at 4:03 PM, selforganized wrote:
> Hi,
>
> Does Postgresql have any write-optimized data structure like LSM-tree? if
> not is there any plan to implement that?
>
> I'm building a write-heavy OLTP application. I'm looking at write-optimized
> databases like MyRocks, TokuDB, and
On Mon, Jan 2, 2017 at 5:23 AM, Job wrote:
> Hello guys and very good new year to everybody!
>
> We are now approaching some queries and statistics on very big table (about
> 180 millions of record).
> The table is partitioned by day (about ~3 Gb of data for every partition/day).
> We use Postgre
On Thu, Jan 12, 2017 at 2:19 PM, bto...@computer.org
wrote:
>
>
> - Original Message -
>> From: "Jonathan Vanasco"
>> To: "pgsql-general general"
>> Sent: Thursday, January 12, 2017 3:06:14 PM
>> Subject: [GENERAL] efficiently migrating 'old' data from one table to another
>>
>> I'm just
On Fri, Jan 13, 2017 at 12:03 PM, wrote:
> On Jan 12, 2017, Jonathan Vanasco wrote:
>>On Jan 12, 2017, at 5:52 PM, Merlin Moncure wrote:
>>
>>> On Thu, Jan 12, 2017 at 2:19 PM, bto...@computer.org
>>> wrote:
>>>>
>>>> Revie
On Wed, Jan 18, 2017 at 1:04 PM, Ravi Tammineni
wrote:
> Hi Chris,
>
> Here is the query and execution plan in 9.5 and 9.6.
Can you verify tblpuorderstatus and tblpuorderstatushistory have all
indexes accounted for on both servers? It seems incredible server
would prefer wading through 11M recor
On Wed, Jan 18, 2017 at 2:12 PM, Melvin Davidson
wrote:
>
>
> On Wed, Jan 18, 2017 at 3:06 PM, Merlin Moncure
> wrote:
>
>> On Wed, Jan 18, 2017 at 1:04 PM, Ravi Tammineni
>> wrote:
>> > Hi Chris,
>> >
>> > Here is the query a
On Wed, Jan 18, 2017 at 11:10 PM, Adrian Klaver
wrote:
> On 01/18/2017 08:58 PM, Merlin Moncure wrote:
>>
>> On Wed, Jan 18, 2017 at 2:12 PM, Melvin Davidson > <mailto:melvin6...@gmail.com>> wrote:
>>
>>
>>
>> On Wed, Jan 18, 2017 at 3:06
On Thu, Jan 19, 2017 at 1:28 AM, Tomas Vondra
wrote:
> On 01/19/2017 06:21 AM, Merlin Moncure wrote:
>>
> ...
>>
>>
>> yes. Either way, I would like to very much understand how server is
>> preferring 3m cost plan to 2.6k cost plan or is otherwis
On Mon, Jan 23, 2017 at 11:08 AM, Kased, Razy (Chemistry and
Geosciences) wrote:
> I recently came across this question: "What is the purpose of PostGIS on
> PostgreSQL?" and wanted to know what this mailing list had to respond with.
PostGIS is a SQL wrapper to the GEOS library which lets you do
On Thu, Jan 19, 2017 at 5:23 PM, Julian Paul wrote:
> I hope that particular stereotypes aren't proven here, but it appears
> #postgresql encourages a particular tier and makes aware of it's rigid
> hierarchy. I owe alot to #postgresql but not to these particular users, I've
> perhaps been idle fo
1 - 100 of 2111 matches
Mail list logo