CREATE EXTENSION IF NOT EXISTS pg_stat_statements;
SELECT pg_stat_statements_reset();
CREATE TABLE Foo(id SERIAL PRIMARY KEY);
-- INSERT INTO Foo(id) VALUES(1);
PREPARE S1(INTEGER) AS SELECT * FROM Foo WHERE id=$1;
-- EXECUTE S1(1);
  DEALLOCATE	 S1;
PREPARE S2(INTEGER) AS SELECT * FROM Foo WHERE id=$1;
Deallocate S2;
PREPARE S3(INTEGER) AS SELECT * FROM Foo WHERE id=$1;
deallocate S3;
PREPARE S4(INTEGER) AS SELECT * FROM Foo WHERE id=$1;
DEALLOCATE S4;
SELECT COUNT(*) FROM pg_stat_statements WHERE query ILIKE 'DEALLOCATE%';
