fixed database syntax