Applies Bas van Gompel's patch which allows the database to read from stdin.