Database lease backend statistics contain statistics for non-existent subnets
It appears that when configured subnets are deleted entries in the corresponding leaseX-stat table entries are not being removed. There are likely a number of ways that lease statistics for a subnet get orphaned when subnets cease to exist. Certainly, cascade deletes help but only for CB subnets. The code that processes the result set needs to be altered so that rows for non-existent subnets are not issue.