Commit c23bbfc9 authored by Steven Murray's avatar Steven Murray
Browse files

[Catalogue] operations#179 Slow `cta-admin sq` even when there is very little activity

Fixing problem with comparing char with integer using the <>
operator.  This appears to be happening with some
version(s)/configurations of PostgreSQL but not all.
parent b32ccd33
......@@ -1992,9 +1992,9 @@ std::list<TapePool> RdbmsCatalogue::getTapePools() const {
"COALESCE(COUNT(TAPE.VID), 0) AS NB_TAPES,"
"COALESCE(SUM(CASE WHEN TAPE.DATA_IN_BYTES = 0 THEN 1 ELSE 0 END), 0) AS NB_EMPTY_TAPES,"
"COALESCE(SUM(CASE WHEN TAPE.IS_DISABLED <> 0 THEN 1 ELSE 0 END), 0) AS NB_DISABLED_TAPES,"
"COALESCE(SUM(CASE WHEN TAPE.IS_FULL <> 0 THEN 1 ELSE 0 END), 0) AS NB_FULL_TAPES,"
"COALESCE(SUM(CASE WHEN TAPE.IS_READ_ONLY <> 0 THEN 1 ELSE 0 END), 0) AS NB_READ_ONLY_TAPES,"
"COALESCE(SUM(CASE WHEN TAPE.IS_DISABLED <> '0' THEN 1 ELSE 0 END), 0) AS NB_DISABLED_TAPES,"
"COALESCE(SUM(CASE WHEN TAPE.IS_FULL <> '0' THEN 1 ELSE 0 END), 0) AS NB_FULL_TAPES,"
"COALESCE(SUM(CASE WHEN TAPE.IS_READ_ONLY <> '0' THEN 1 ELSE 0 END), 0) AS NB_READ_ONLY_TAPES,"
"COALESCE(SUM(MEDIA_TYPE.CAPACITY_IN_BYTES), 0) AS CAPACITY_IN_BYTES,"
"COALESCE(SUM(TAPE.DATA_IN_BYTES), 0) AS DATA_IN_BYTES,"
"COALESCE(SUM(TAPE.LAST_FSEQ), 0) AS NB_PHYSICAL_FILES,"
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment