diff --git a/physical/postgresql/postgresql.go b/physical/postgresql/postgresql.go index 79d68d4c77bd..013eae624cef 100644 --- a/physical/postgresql/postgresql.go +++ b/physical/postgresql/postgresql.go @@ -157,7 +157,7 @@ func NewPostgreSQLBackend(conf map[string]string, logger log.Logger) (physical.B get_query: "SELECT value FROM " + quoted_table + " WHERE path = $1 AND key = $2", delete_query: "DELETE FROM " + quoted_table + " WHERE path = $1 AND key = $2", list_query: "SELECT key FROM " + quoted_table + " WHERE path = $1" + - " UNION SELECT DISTINCT substring(substr(path, length($1)+1) from '^.*?/') FROM " + quoted_table + + " UNION ALL SELECT DISTINCT substring(substr(path, length($1)+1) from '^.*?/') FROM " + quoted_table + " WHERE parent_path LIKE $1 || '%'", haGetLockValueQuery: // only read non expired data