afanasy: Old SQL classes removed. Now SQL for statistices only.