Add database analytic function.