PostgreSQL Partition Check Script

New year is coming, if you want to check date based partitions in PostgreSQL , you may use the following query: