Category “PostgreSQL” — 131 articles

The problem was raised this week on IRC and this time again I felt it would be a good occasion for a blog entry: how to load an XML file content into a single field? The usual tool used to import files is COPY, but it’ll want each line of the file to host a text representation of a database tuple, so it doesn’t apply to the case at hand. RhodiumToad was online and offered the following code to solve the problem:



One of the difficulties in getting to understand and configure londiste reside in the relation between the ticker and the replication. This question was raised once more on IRC yesterday, so I made a new FAQ entry about it: How do this ticker thing relates to londiste?


In the page about Skytools I’ve encouraged people to ask some more questions in order for me to be able to try and answer them. That just happened, as usual on the #postgresql IRC, and the question is What does londiste lack that slony has?


As it happens, I’ve got some environments where I want to make sure HOT ( aka Heap Only Tuples) is in use. Because we’re doing so much updates a second that I want to get sure it’s not killing my database server. I not only wrote some checking view to see about it, but also made a quick article about it in the French PostgreSQL website. Handling around in #postgresql means that I’m now bound to write about it in English too!


Londiste Trick

So, you’re using londiste and the ticker has not been running all night long, due to some restart glitch in your procedures, and the on call admin didn’t notice the restart failure. If you blindly restart the replication daemon, it will load in memory all those events produced during the night, at once, because you now have only one tick where to put them all. The following query allows you to count how many events that represents, with the magic tick numbers coming from pgq.

Dimitri Fontaine

PostgreSQL Major Contributor

Open Source Software Engineer

France