# HG changeset patch # User Alain Mazy # Date 1727440720 -7200 # Node ID 523241efee57d319992e14c4017c57d323938376 # Parent 6667bd31beaf1ecf329ed6d841ca77bb5c73ad00 fix diff -r 6667bd31beaf -r 523241efee57 PostgreSQL/Plugins/PostgreSQLIndex.cpp --- a/PostgreSQL/Plugins/PostgreSQLIndex.cpp Thu Sep 26 17:24:29 2024 +0200 +++ b/PostgreSQL/Plugins/PostgreSQLIndex.cpp Fri Sep 27 14:38:40 2024 +0200 @@ -257,7 +257,14 @@ statement.Execute(); - result = static_cast(statement.ReadInteger64(0)); + if (statement.IsNull(0)) + { + return 0; + } + else + { + result = static_cast(statement.ReadInteger64(0)); + } } // disabled because this is not alway true while transactions are being executed in READ COMITTED TRANSACTION. This is however true when no files are being delete/added