<?xml version="1.0" encoding="utf-8" standalone="yes"?><rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>Sql on ads' corner</title><link>https://andreas.scherbaum.la/tags/sql/</link><description>Recent content in Sql on ads' corner</description><generator>Hugo</generator><language>en-us</language><lastBuildDate>Tue, 12 Dec 2023 23:56:03 +0100</lastBuildDate><atom:link href="https://andreas.scherbaum.la/tags/sql/index.xml" rel="self" type="application/rss+xml"/><item><title>PGConf.eu 2023 Speaker Dinner</title><link>https://andreas.scherbaum.la/post/2023-12-12_pgconf.eu-2023-speaker-dinner/</link><pubDate>Tue, 12 Dec 2023 23:56:03 +0100</pubDate><guid>https://andreas.scherbaum.la/post/2023-12-12_pgconf.eu-2023-speaker-dinner/</guid><description>&lt;p&gt;Traditionally, we (the conference organizers) invite the speakers and volunteers to a dinner the evening before the conference.&lt;/p&gt;&#10;&lt;p&gt;Without the speakers and all the helping hands the conference is certainly not possible.&lt;/p&gt;&#10;&lt;p&gt;Tomas found a nice place in &lt;em&gt;Prague&lt;/em&gt;, the &lt;a href="https://www.marina-garden.cz/"&gt;Restaurace Marina Garden&lt;/a&gt;. It&amp;rsquo;s about 30 minutes by public transport from the &lt;a href="https://2023.pgconf.eu/venue/"&gt;conference venue&lt;/a&gt;.&lt;/p&gt;&#10;&lt;p&gt;But this posting is not about the restaurant, but rather what&amp;rsquo;s happening when a large number of &lt;em&gt;PostgreSQL&lt;/em&gt; people come together and have an opportunity to chat about many different topics. The venue is downstairs, and the seating splits the larger group up into up to 6 people per table. Ideal conditions to walk around, chat with everyone, talk with old friends and meet new peoole.&lt;/p&gt;</description></item><item><title>My PostgreSQL database is empty!</title><link>https://andreas.scherbaum.la/post/2022-06-11_my-postgresql-database-is-empty/</link><pubDate>Sat, 11 Jun 2022 20:08:00 +0200</pubDate><guid>https://andreas.scherbaum.la/post/2022-06-11_my-postgresql-database-is-empty/</guid><description>&lt;p&gt;The one thing I like to do is challenge &lt;a href="https://www.postgresql.org/"&gt;PostgreSQL&lt;/a&gt; - and readers - to the extreme. A while ago I posted about the &lt;a href="https://andreas.scherbaum.la/post/2022-05-03_its-beer-oclock-for-postgresql/"&gt;Beer o&amp;rsquo;clock&lt;/a&gt;. Building &lt;a href="https://andreas.scherbaum.la/post/2022-01-27_not-so-equal-texts-in-postgresql-and-how-to-compare-texts-in-a-more-elaborate-way/"&gt;Zoé&lt;/a&gt; was another interesting example. And at some point I blog about Dancing with the Stars as well. Today it&amp;rsquo;s all about nothing. Empty. Where is all the data gone?&lt;/p&gt;&#10;&lt;p&gt;A while ago I posted &lt;a href="https://twitter.com/ascherbaum/status/1517832463829147648"&gt;this screenshot on Twitter&lt;/a&gt;, and as far as I can tell no one found the correct answer.&lt;/p&gt;</description></item><item><title>It's beer o'clock for PostgreSQL</title><link>https://andreas.scherbaum.la/post/2022-05-03_its-beer-oclock-for-postgresql/</link><pubDate>Tue, 03 May 2022 11:50:00 +0200</pubDate><guid>https://andreas.scherbaum.la/post/2022-05-03_its-beer-oclock-for-postgresql/</guid><description>&lt;p&gt;A couple days ago &lt;a href="https://twitter.com/DevrimGunduz/status/1519708131433066500"&gt;Devrim forked PostgreSQL to get a beer&lt;/a&gt;.&lt;/p&gt;&#10;&lt;p&gt;That effort is of course laudable, but a bit extreme.&lt;/p&gt;&#10;&lt;p&gt;&lt;em&gt;PostgreSQL&lt;/em&gt; is very extensible, and allows to implement a beer now clock with just a few easy steps.&lt;/p&gt;</description></item><item><title>GSoC 2021 completed</title><link>https://andreas.scherbaum.la/post/2021-09-02_gsoc-2021-completed/</link><pubDate>Thu, 02 Sep 2021 00:06:00 +0200</pubDate><guid>https://andreas.scherbaum.la/post/2021-09-02_gsoc-2021-completed/</guid><description>&lt;p&gt;The &lt;a href="https://summerofcode.withgoogle.com/"&gt;Google Summer of Code 2021&lt;/a&gt; (&lt;em&gt;GSoC&lt;/em&gt;) for the &lt;a href="https://www.postgresql.org/"&gt;PostgreSQL Project&lt;/a&gt; is wrapped up. The timeline this year was shortened to half, compared to previous years. That’s good, because smaller projects can be worked on, and students have a chance to cope with a changing environment at home and university. On the other hand, the shorter time doesn’t allow diving into more complex projects. Nevertheless, with the help of all mentors, six students successfully concluded their projects.&lt;/p&gt;</description></item><item><title>PostgreSQL Project @ GSoC 2021</title><link>https://andreas.scherbaum.la/post/2021-05-20_postgresql-project-gsoc-2021/</link><pubDate>Thu, 20 May 2021 15:25:00 +0200</pubDate><guid>https://andreas.scherbaum.la/post/2021-05-20_postgresql-project-gsoc-2021/</guid><description>&lt;p&gt;Wow! The &lt;a href="https://www.postgresql.org/"&gt;PostgreSQL Project&lt;/a&gt; got all 7 proposals accepted into &lt;a href="https://summerofcode.withgoogle.com/"&gt;Google Summer of Code 2021&lt;/a&gt; (&lt;em&gt;GSoC&lt;/em&gt;)!&lt;/p&gt;&#10;&lt;p&gt;This year &lt;em&gt;Google&lt;/em&gt; changed the &lt;a href="https://summerofcode.withgoogle.com/how-it-works/"&gt;participation terms&lt;/a&gt; a bit, and cut the time for the students in half. This is supposed to help students who can’t work full-time from home, especially in light of the global pandemic situation. It also means smaller projects, which are easier to handle even for students new to the project.&lt;/p&gt;</description></item><item><title>Advent of Code 2020: "Seating System" - Day 11</title><link>https://andreas.scherbaum.la/post/2020-12-12_advent-of-code-2020-seating-system-day-11/</link><pubDate>Sat, 12 Dec 2020 22:42:00 +0100</pubDate><guid>https://andreas.scherbaum.la/post/2020-12-12_advent-of-code-2020-seating-system-day-11/</guid><description>&lt;p&gt;Your career as a hacker brings you &lt;a href="https://adventofcode.com/2020/day/11"&gt;more and more unreasonable tasks&lt;/a&gt;. Today you arrive at the ferry station, head to your next gate (no one mentioned if you &lt;a href="https://andreas.scherbaum.la/post/2020-12-10_advent-of-code-2020-adapter-array-day-10/"&gt;even got an ice cream&lt;/a&gt;), and figure out where to seat. Even though you are the first person in the waiting area that does not stop you from knowing the seating habits for all other passengers, and calculate their seating patterns.&lt;/p&gt;</description></item><item><title>Advent of Code 2020: "Adapter Array" - Day 10</title><link>https://andreas.scherbaum.la/post/2020-12-10_advent-of-code-2020-adapter-array-day-10/</link><pubDate>Thu, 10 Dec 2020 22:21:00 +0100</pubDate><guid>https://andreas.scherbaum.la/post/2020-12-10_advent-of-code-2020-adapter-array-day-10/</guid><description>&lt;p&gt;After you finished &lt;a href="https://andreas.scherbaum.la/post/2020-12-09_advent-of-code-2020-encoding-error-day-9/"&gt;hacking the plane&lt;/a&gt;, your laptop dies: you forgot to charge it! Rookie mistake, or the calculations do consume a lot of power. The plane has a power outlet, but somehow it&amp;rsquo;s a non-standard one, you need an adapter. But first a cocktail! Then you empty your backback on the seat next to you and &lt;a href="https://adventofcode.com/2020/day/10"&gt;find out that you have dozens of different adapters&lt;/a&gt;, which you can &lt;a href="https://superuser.com/questions/1122204/how-many-port-adapters-and-which-ones-can-be-stacked-up-and-actually-work"&gt;stack together&lt;/a&gt;. None of them really work, and hopefully you don&amp;rsquo;t blow another fuse, or set the &lt;a href="https://www.youtube.com/watch?v=uiqvXKyhkiw"&gt;plane on fire&lt;/a&gt;!&lt;/p&gt;</description></item><item><title>Advent of Code 2020: "Encoding Error" - Day 9</title><link>https://andreas.scherbaum.la/post/2020-12-09_advent-of-code-2020-encoding-error-day-9/</link><pubDate>Wed, 09 Dec 2020 21:43:00 +0100</pubDate><guid>https://andreas.scherbaum.la/post/2020-12-09_advent-of-code-2020-encoding-error-day-9/</guid><description>&lt;p&gt;Uh oh, either the ice cream at the airport was bad, or the &lt;a href="https://andreas.scherbaum.la/post/2020-12-08_advent-of-code-2020-handheld-halting-day-8/"&gt;cocktails&lt;/a&gt; are not good for you! How else can you explain that you hack the airplane systems with some &lt;a href="https://en.wikipedia.org/wiki/Clippy"&gt;paperclips&lt;/a&gt; and break the &lt;a href="https://en.wikipedia.org/wiki/Xmas"&gt;XMAS&lt;/a&gt; &lt;a href="https://en.wikipedia.org/wiki/Encryption"&gt;encryption&lt;/a&gt;, while the plane is &lt;a href="https://en.wikipedia.org/wiki/Takeoff"&gt;airborne&lt;/a&gt;? The plane&amp;rsquo;s on-board systems emits some cryptic numbers and &lt;a href="https://adventofcode.com/2020/day/9"&gt;your task&lt;/a&gt; is it to decrypt this. Wait, did I say task? &lt;a href="https://en.wikipedia.org/wiki/Mission:_Impossible"&gt;Who gave this task to you&lt;/a&gt;? Oh well, please be careful, if you shorten a circuit you might as well crash your own plane.&lt;/p&gt;</description></item><item><title>Advent of Code 2020: "Handheld Halting" - Day 8</title><link>https://andreas.scherbaum.la/post/2020-12-08_advent-of-code-2020-handheld-halting-day-8/</link><pubDate>Tue, 08 Dec 2020 23:56:00 +0100</pubDate><guid>https://andreas.scherbaum.la/post/2020-12-08_advent-of-code-2020-handheld-halting-day-8/</guid><description>&lt;p&gt;You fixed the &lt;a href="https://andreas.scherbaum.la/post/2020-12-07_advent-of-code-2020-handy-haversacks-day-7/"&gt;colours of the bags yesterday&lt;/a&gt; and security allowed you to leave the baggage section and go get your ice cream before you board your next flight. On the flight the kid next to you recognizes you as the great hacker you are, and &lt;a href="https://adventofcode.com/2020/day/8"&gt;asks you to fix a problem&lt;/a&gt; with the handheld game console. Go and hack the bootloader while no documentation is available because the mobile internet is off. Turns out someone coded an infinite loop into the bootloader, and missed that fact during testing. What testing, do you ask? Well, let&amp;rsquo;s not jump too deep into details, you have to hack a bootloader and make a kid happy. It&amp;rsquo;s Christmas soon, after all! And your cocktail is waiting!&lt;/p&gt;</description></item><item><title>Advent of Code 2020: "Handy Haversacks" - Day 7</title><link>https://andreas.scherbaum.la/post/2020-12-07_advent-of-code-2020-handy-haversacks-day-7/</link><pubDate>Mon, 07 Dec 2020 21:08:00 +0100</pubDate><guid>https://andreas.scherbaum.la/post/2020-12-07_advent-of-code-2020-handy-haversacks-day-7/</guid><description>&lt;p&gt;They really trust you a lot &amp;hellip; Now all flights are delayed, that&amp;rsquo;s quite usual in advent times. Except it&amp;rsquo;s &lt;code&gt;2020&lt;/code&gt; and no one is traveling anyway. But they also impose more regulations, and now bags need to have colours, and bags need to go into other bags. And &lt;a href="https://adventofcode.com/2020/day/7"&gt;someone has to figure it out&lt;/a&gt;. That&amp;rsquo;s right, it&amp;rsquo;s you! I hope the stopover is long enough to at least grab some ice cream!&lt;/p&gt;</description></item><item><title>Advent of Code 2020: "Custom Customs" - Day 6</title><link>https://andreas.scherbaum.la/post/2020-12-06_advent-of-code-2020-custom-customs-day-6/</link><pubDate>Sun, 06 Dec 2020 22:35:00 +0100</pubDate><guid>https://andreas.scherbaum.la/post/2020-12-06_advent-of-code-2020-custom-customs-day-6/</guid><description>&lt;p&gt;The flight is approaching a regional airport, but you still have to fill out a &lt;a href="https://adventofcode.com/2020/day/6"&gt;customs form&lt;/a&gt;. Since you are good with hacking things together, you walk around the plane and gather all the answers from all groups on the plane. There are &lt;code&gt;26&lt;/code&gt; yes-or-no questions, marked from &lt;code&gt;a&lt;/code&gt; to &lt;code&gt;z&lt;/code&gt;.&lt;/p&gt;</description></item><item><title>Advent of Code 2020: "Binary Boarding" - Day 5</title><link>https://andreas.scherbaum.la/post/2020-12-05_advent-of-code-2020-binary-boarding-day-5/</link><pubDate>Sat, 05 Dec 2020 18:24:00 +0100</pubDate><guid>https://andreas.scherbaum.la/post/2020-12-05_advent-of-code-2020-binary-boarding-day-5/</guid><description>&lt;p&gt;Pretty amazing the tasks they ask you to do &amp;ldquo;on the fly&amp;rdquo;: &lt;a href="https://andreas.scherbaum.la/post/2020-12-05_advent-of-code-2020-passport-processing-day-4/"&gt;Yesterday&lt;/a&gt; we fixed the passport scanner, &lt;a href="https://adventofcode.com/2020/day/5"&gt;today&lt;/a&gt; you have to write a piece of code which scans all the boarding passes in your environment (no one said they all carry them in the hand, and show it to you), and while waiting in the gangway you also have to identify your designated seat. Because, you know, you are such a good hacker you lost your &lt;a href="https://en.wikipedia.org/wiki/Boarding_pass"&gt;boarding pass&lt;/a&gt; on the &lt;a href="https://en.wikipedia.org/wiki/Jet_bridge"&gt;way&lt;/a&gt; from the gate to the plane ;-)&lt;/p&gt;</description></item><item><title>Advent of Code 2020: "Passport Processing" - Day 4</title><link>https://andreas.scherbaum.la/post/2020-12-05_advent-of-code-2020-passport-processing-day-4/</link><pubDate>Sat, 05 Dec 2020 16:50:00 +0100</pubDate><guid>https://andreas.scherbaum.la/post/2020-12-05_advent-of-code-2020-passport-processing-day-4/</guid><description>&lt;p&gt;The challenge for day 4 is more suited for databases. The input is fuzzy, but with a &lt;a href="https://www.postgresql.org/docs/current/queries-with.html"&gt;CTE&lt;/a&gt; or two I should be able to clean it up. Solved the first part already with the &lt;a href="https://twitter.com/pscherbaum/status/1335238751363194880"&gt;kid&lt;/a&gt; earlier, but we decided to skip part two: mainly because it involved more complex string operations (best suited for regex operations), which is something the kid hasn&amp;rsquo;t learned yet.&lt;/p&gt;</description></item><item><title>Advent of Code 2020: "Toboggan Trajectory" - Day 3</title><link>https://andreas.scherbaum.la/post/2020-12-03_advent-of-code-2020-toboggan-trajectory-day-3/</link><pubDate>Thu, 03 Dec 2020 22:52:00 +0100</pubDate><guid>https://andreas.scherbaum.la/post/2020-12-03_advent-of-code-2020-toboggan-trajectory-day-3/</guid><description>&lt;p&gt;Have to admit, on first glance &lt;a href="https://adventofcode.com/2020/day/3"&gt;this challenge&lt;/a&gt; looks a bit complicated. It&amp;rsquo;s well suited for languages which can do string manipulations, but it&amp;rsquo;s not well suited for &lt;a href="https://www.postgresql.org/"&gt;PostgreSQL&lt;/a&gt;. Earlier today I already looked at this problem together with &lt;a href="https://twitter.com/pscherbaum/status/1334550125797105664"&gt;the kid&lt;/a&gt;, in &lt;em&gt;Python&lt;/em&gt;. Therefore I already knew that I have to jump multiple rows as well. To sum it up: &lt;em&gt;adjust x, including overruns, jump multiple rows in y direction, count trees along the way&lt;/em&gt;. All in a single SQL query.&lt;/p&gt;&#10;&lt;p&gt;Decided to do the map search in a &lt;a href="https://www.postgresql.org/docs/current/plpgsql.html"&gt;pl/pgSQL&lt;/a&gt; instead, and write a function for it.&lt;/p&gt;</description></item><item><title>Advent of Code 2020: "Password Philosophy" - Day 2</title><link>https://andreas.scherbaum.la/post/2020-12-02_advent-of-code-2020-password-philosophy-day-2/</link><pubDate>Wed, 02 Dec 2020 22:57:00 +0100</pubDate><guid>https://andreas.scherbaum.la/post/2020-12-02_advent-of-code-2020-password-philosophy-day-2/</guid><description>&lt;p&gt;&lt;a href="https://adventofcode.com/2020/day/2"&gt;Day 2&lt;/a&gt;, another challenge: fix a broken password database. In order to do that, the passwords which violate the policy must be identified.&lt;/p&gt;</description></item><item><title>Advent of Code 2020: "Report Repair" - Day 1</title><link>https://andreas.scherbaum.la/post/2020-12-01_advent-of-code-2020-report-repair-day-1/</link><pubDate>Tue, 01 Dec 2020 18:51:00 +0100</pubDate><guid>https://andreas.scherbaum.la/post/2020-12-01_advent-of-code-2020-report-repair-day-1/</guid><description>&lt;p&gt;Started &amp;ldquo;&lt;a href="https://adventofcode.com/2020/"&gt;Advent of Code&lt;/a&gt;&amp;rdquo; with the &lt;a href="https://pascal.scherbaum.la/blog/"&gt;kid&lt;/a&gt;, the kid is polishing the &lt;em&gt;Python&lt;/em&gt; (and &lt;em&gt;English&lt;/em&gt;) skills. I thought I better do this in &lt;a href="https://www.postgresql.org/"&gt;SQL&lt;/a&gt;.&lt;/p&gt;</description></item><item><title>Grafana: select host for a dashboard</title><link>https://andreas.scherbaum.la/post/2020-06-30_grafana-select-host-for-a-dashboard/</link><pubDate>Tue, 30 Jun 2020 00:49:00 +0200</pubDate><guid>https://andreas.scherbaum.la/post/2020-06-30_grafana-select-host-for-a-dashboard/</guid><description>&lt;p&gt;&lt;em&gt;InfluxDB&lt;/em&gt; is running on a &lt;em&gt;Raspberry Pi&lt;/em&gt; in my home network (&lt;a href="https://andreas.scherbaum.la/post/2020-06-21_move-influxdb-data-directory-to-a-sdcard/"&gt;with separate attached disk&lt;/a&gt;), and I installed a &lt;em&gt;Grafana&lt;/em&gt; on top of it, to visualize crucial data.&lt;/p&gt;</description></item><item><title>SELECT pg_sleep_until('#800Monies');</title><link>https://andreas.scherbaum.la/post/2020-01-17_select-pg_sleep_until800monies/</link><pubDate>Fri, 17 Jan 2020 00:34:00 +0100</pubDate><guid>https://andreas.scherbaum.la/post/2020-01-17_select-pg_sleep_until800monies/</guid><description>&lt;p&gt;Pavlo recently &lt;a href="https://twitter.com/PavloGolub/status/1217391570267377664"&gt;pointed out&lt;/a&gt; that the &lt;a href="https://www.postgresql.org/docs/current/functions-datetime.html#FUNCTIONS-DATETIME-DELAY"&gt;pg_sleep() function&lt;/a&gt; in &lt;a href="https://www.postgresql.org/"&gt;PostgreSQL&lt;/a&gt; has two alternatives: &lt;code&gt;pg_sleep_for()&lt;/code&gt; and &lt;code&gt;pg_sleep_until()&lt;/code&gt;.&lt;/p&gt;&#10;&lt;p&gt;What do they do?&lt;/p&gt;</description></item><item><title>How to not export data in Ispirer SQLWays</title><link>https://andreas.scherbaum.la/post/2012-09-26_how-to-not-export-data-in-ispirer-sqlways/</link><pubDate>Wed, 26 Sep 2012 21:14:00 +0200</pubDate><guid>https://andreas.scherbaum.la/post/2012-09-26_how-to-not-export-data-in-ispirer-sqlways/</guid><description>&lt;p&gt;&lt;a href="https://www.ispirer.com/"&gt;Ispirer&lt;/a&gt; &lt;a href="https://www.ispirer.com/products/sqlways-database-migration"&gt;SQLWays&lt;/a&gt; is a nice (although commercial) tool to convert DDL and data from one supported database to another. We are using it regularly, the list of supported databases is impressive: &lt;em&gt;PostgreSQL&lt;/em&gt;, &lt;em&gt;Greenplum&lt;/em&gt;, &lt;em&gt;Oracle&lt;/em&gt;, &lt;em&gt;SQL Server&lt;/em&gt;, &lt;em&gt;IBM DB2&lt;/em&gt;, &lt;em&gt;MySQL&lt;/em&gt;, &lt;em&gt;Sybase&lt;/em&gt;, &lt;em&gt;Informix&lt;/em&gt;, &lt;em&gt;Teradata&lt;/em&gt;, *Netezza *and some more.&lt;/p&gt;&#10;&lt;p&gt;There&amp;rsquo;s just one thing which I always forget: &lt;em&gt;SQLways&lt;/em&gt; exports all data by default, which makes the export unnecessary big and slow.&lt;/p&gt;</description></item><item><title>Single line input for psql copy command</title><link>https://andreas.scherbaum.la/post/2008-10-08_single-line-input-for-psql-copy-command/</link><pubDate>Wed, 08 Oct 2008 22:26:05 +0200</pubDate><guid>https://andreas.scherbaum.la/post/2008-10-08_single-line-input-for-psql-copy-command/</guid><description>&lt;p&gt;I have the following problem:&lt;/p&gt;&#10;&lt;p&gt;A database server and another client machine. I have to execute several &lt;code&gt;\copy&lt;/code&gt; commands in &lt;code&gt;psql&lt;/code&gt; on the client machine to retrieve data and store the output in CSV files. The &lt;em&gt;PostgreSQL&lt;/em&gt; &lt;code&gt;COPY&lt;/code&gt; command is not an option because it stores the results on the database server, not the client machine. All &lt;code&gt;\copy&lt;/code&gt; commands are executed from several files containing &lt;em&gt;SQL&lt;/em&gt; commands, which are concated together by a &lt;code&gt;Makefile&lt;/code&gt; and feeded into &lt;code&gt;psql&lt;/code&gt;. So far so good.&lt;/p&gt;</description></item><item><title>role ... cannot be dropped because some objects depend on it</title><link>https://andreas.scherbaum.la/post/2008-09-10_role-...-cannot-be-dropped-because-some-objects-depend-on-it/</link><pubDate>Wed, 10 Sep 2008 20:11:07 +0200</pubDate><guid>https://andreas.scherbaum.la/post/2008-09-10_role-...-cannot-be-dropped-because-some-objects-depend-on-it/</guid><description>&lt;p&gt;I want to &lt;a href="https://www.postgresql.org/docs/8.3/interactive/sql-droprole.html"&gt;drop a ROLE&lt;/a&gt; (previously &lt;code&gt;USER&lt;/code&gt;/&lt;code&gt;GROUP&lt;/code&gt;s) which is still referenced by object(s) in my database. But &lt;a href="https://www.postgresql.org/"&gt;PostgreSQL&lt;/a&gt; has objections:&lt;/p&gt;</description></item><item><title>create language if not exist</title><link>https://andreas.scherbaum.la/post/2008-03-27_create-language-if-not-exist/</link><pubDate>Thu, 27 Mar 2008 08:33:14 +0100</pubDate><guid>https://andreas.scherbaum.la/post/2008-03-27_create-language-if-not-exist/</guid><description>&lt;p&gt;In a customer project I have to setup a database from a &lt;code&gt;Makefile&lt;/code&gt;. Part of my problem: on &lt;em&gt;Windows&lt;/em&gt; the installer may or may not install &lt;code&gt;plpgsql&lt;/code&gt; into &lt;code&gt;template1&lt;/code&gt;, therefore in consequence this language may or may not be activated in every new database. But that&amp;rsquo;s not predictable. This problem can appear on different &lt;em&gt;Linux&lt;/em&gt;/Unix distributions too.&lt;/p&gt;</description></item><item><title>Understanding SQL</title><link>https://andreas.scherbaum.la/post/2008-01-13_understanding-sql/</link><pubDate>Sun, 13 Jan 2008 15:29:56 +0100</pubDate><guid>https://andreas.scherbaum.la/post/2008-01-13_understanding-sql/</guid><description>&lt;p&gt;Have to port a &lt;a href="https://web.archive.org/web/20080101020141/https://www.phpkit.de/"&gt;phpkit&lt;/a&gt; database to something else. It seems, the &lt;code&gt;phpkit&lt;/code&gt; ppl did not really understand what &lt;em&gt;SQL&lt;/em&gt; is for.&lt;/p&gt;</description></item><item><title>table size, database size</title><link>https://andreas.scherbaum.la/post/2007-12-04_table-size-database-size/</link><pubDate>Tue, 04 Dec 2007 11:07:00 +0100</pubDate><guid>https://andreas.scherbaum.la/post/2007-12-04_table-size-database-size/</guid><description>&lt;p&gt;I have seen this question &lt;a href="https://web.archive.org/web/20101210103329/https://www.postgresqlforums.com/forums/viewtopic.php?f=42&amp;amp;t=417"&gt;more than once&lt;/a&gt; in the past: &amp;ldquo;How much storage space do I need for my table?&amp;rdquo;&lt;/p&gt;&#10;&lt;p&gt;&lt;em&gt;PostgreSQL&lt;/em&gt; can give you &lt;a href="https://www.postgresql.org/docs/current/static/functions-admin.html#FUNCTIONS-ADMIN-DBSIZE"&gt;this information&lt;/a&gt;.&lt;/p&gt;</description></item><item><title>Avoid autovacuum for entire databases</title><link>https://andreas.scherbaum.la/post/2007-07-02_avoid-autovacuum-for-entire-databases/</link><pubDate>Mon, 02 Jul 2007 00:58:25 +0200</pubDate><guid>https://andreas.scherbaum.la/post/2007-07-02_avoid-autovacuum-for-entire-databases/</guid><description>&lt;p&gt;We have a database with production data for a platform and another database with a production database dump for testing queries. We also have a test database but this one has slightly different DDL, because it&amp;rsquo;s for developing new features. Now &lt;em&gt;Autovacuum&lt;/em&gt; is running on this server and keeps vacuuming this test database.&lt;/p&gt;</description></item><item><title>Avoid Unique Key violation</title><link>https://andreas.scherbaum.la/post/2006-07-28_avoid-unique-key-violation/</link><pubDate>Fri, 28 Jul 2006 11:18:51 +0200</pubDate><guid>https://andreas.scherbaum.la/post/2006-07-28_avoid-unique-key-violation/</guid><description>&lt;p&gt;If you have a table with an unique key field, want to insert new values but you don&amp;rsquo;t know if the value may already be in the table, you can use the following query:&lt;/p&gt;</description></item><item><title>Reverse a text in PostgreSQL</title><link>https://andreas.scherbaum.la/post/2006-07-24_reverse-a-text-in-postgresql/</link><pubDate>Mon, 24 Jul 2006 23:36:40 +0200</pubDate><guid>https://andreas.scherbaum.la/post/2006-07-24_reverse-a-text-in-postgresql/</guid><description>&lt;p&gt;I&amp;rsquo;m always searching for a reverse function in &lt;em&gt;PostgreSQL&lt;/em&gt;, so here is the link:&lt;/p&gt;</description></item><item><title>find the sequence name</title><link>https://andreas.scherbaum.la/post/2006-07-05_find-the-sequence-name/</link><pubDate>Wed, 05 Jul 2006 12:20:57 +0200</pubDate><guid>https://andreas.scherbaum.la/post/2006-07-05_find-the-sequence-name/</guid><description>&lt;p&gt;Because I always forget this function name:&lt;/p&gt;</description></item></channel></rss>