adding more database functions