<html><head><meta name="color-scheme" content="light dark"></head><body><pre style="word-wrap: break-word; white-space: pre-wrap;">#!/usr/bin/perl

use strict;
use warnings;
use Data::Dumper;

use DBI;

my $dsn = "DBI:Pg:database=postgres;host=localhost";
my $dbh = DBI-&gt;connect( $dsn, 'postgres', '', { RaiseError =&gt; 1 } )
or die $DBI::errstr;

$dbh-&gt;do('CREATE TABLE buggy ( id INT )');
$dbh-&gt;do('INSERT INTO buggy (id) VALUES (1)');
my $ref= $dbh-&gt;selectrow_arrayref(&lt;&lt;END, {}, 1);
SELECT id
FROM buggy
-- it's a bug!
WHERE id = ?
END
print Dumper $ref;
$dbh-&gt;do('DROP TABLE buggy');
</pre></body></html>