PostgreSQL查询缓存-意外关闭连接

PostgreSQL查询缓存-意外关闭连接,postgresql,caching,postgresql-9.0,Postgresql,Caching,Postgresql 9.0,但这是第二次: <?php $c = pg_connect( $connectionString, PGSQL_CONNECT_FORCE_NEW ); $queries = array ( "SELECT COUNT(*) AS data FROM articles", "SELECT * FROM posts WHERE visible = TRUE", "SELECT * FROM countries WHERE visible =

但这是第二次:

<?php
$c = pg_connect( $connectionString, PGSQL_CONNECT_FORCE_NEW );

$queries = array (
        "SELECT COUNT(*) AS data FROM articles",
        "SELECT * FROM posts WHERE visible = TRUE",
        "SELECT * FROM countries WHERE visible = FALSE",
        "SELECT * FROM types WHERE visible = TRUE"
);

foreach ( $queries as $query ) {
        $res = @pg_query( $c, $query );
        if ( empty( $res ) ) {
                echo "[ERR] " . pg_last_error( $c ) . "\n";
        } else {
                echo "[OK]\n";
        }
}
[OK]
[OK]
[OK]
[OK]
这意味着一些缓存查询会导致问题。我们试图改变怪癖的顺序,但没用。只有像
select1+8
这样的简单查询才能正常运行,它们可能不会被缓存

类似的问题可以使用psql和任何其他语言驱动程序(不仅仅是PHP)来模拟

当我们安装时,所有的麻烦都出现了

查询缓存是否应该以某种方式配置而不是以这种方式运行

我们的配置文件如下: –pcqd_hba.conf
–pcqd.conf

您可能在PostgreSQL查询缓存中有一个错误,导致后端出现SEGFULTS。您最好的解决方案是卸载此加载项。

您可能在PostgreSQL查询缓存中存在错误,导致后端出现故障。最好的解决方案是卸载此加载项。

PostgreSQL
或简称
Postgres
。没有“Postgre”。您是否尝试过使用PDO pgsql驱动程序?正如我所说的,即使使用原始的psql(PostgreSQL的shell工具),它的行为也是一样的。我使用哪个驱动程序并不重要。
PostgreSQL
或简称
Postgres
。没有“Postgre”。您是否尝试过使用PDO pgsql驱动程序?正如我所说的,即使使用原始的psql(PostgreSQL的shell工具),它的行为也是一样的。我使用哪种驱动程序并不重要。
[OK]
[OK]
[ERR] server closed the connection unexpectedly
    This probably means the server terminated abnormally
    before or while processing the request.
[ERR] server closed the connection unexpectedly
    This probably means the server terminated abnormally
        before or while processing the request.