Hi, would it be possible to implement a “remove” for a certain build?
Our database has a 17GB table of “builds_unittest”.
I’ve figured out (using pgAdmin) that around 30 builds have more than 500.000 unit tests registered which is wrong
Hi Christian, thank you for posting. We have discussed internally and agree that it would be good to offer the ability to cleanup a specific build, as well as giving more granular options related to metrics via the build cleanup options (I have added these ideas to the project backlog).
In terms of handling your specific scenario, we have developed a one off datafix that I will send to you direct.
Thanks again
yeah, sounds great.
hi, the scripts worked. i had to remove the build handlers table because its not existing in the production version, but that was no problem.
however that was not the trick at all thanks again for you help.
Hi Christian thanks for the update, happy to hear that you where able to cleanup, with the VACCUM / Reindex. We have a task on our product backlog to evaluate our index usage.
Thanks again for the heads up. If you could send us a ‘SELECT * FROM pg_stat_all_tables’ and the below query that would be greatly appreciated.
SELECT
t.tablename,
indexname,
c.reltuples AS num_rows,
pg_size_pretty(pg_relation_size(quote_ident(t.tablename)::text)) AS table_size,
pg_size_pretty(pg_relation_size(quote_ident(indexrelname)::text)) AS index_size,
CASE WHEN indisunique THEN ‘Y’
ELSE ‘N’
END AS UNIQUE,
idx_scan AS number_of_scans,
idx_tup_read AS tuples_read,
idx_tup_fetch AS tuples_fetched
FROM pg_tables t
LEFT OUTER JOIN pg_class c ON t.tablename=c.relname
LEFT OUTER JOIN
( SELECT c.relname AS ctablename, ipg.relname AS indexname, x.indnatts AS number_of_columns, idx_scan, idx_tup_read, idx_tup_fetch, indexrelname, indisunique FROM pg_index x
JOIN pg_class c ON c.oid = x.indrelid
JOIN pg_class ipg ON ipg.oid = x.indexrelid
JOIN pg_stat_all_indexes psai ON x.indexrelid = psai.indexrelid )
AS foo
ON t.tablename = foo.ctablename
WHERE t.schemaname='public’
ORDER BY 1,2;
Thanks again for your support
Sent to you via mail.
Hi Christian, many thanks for this information we really appreciate it