OK database syntax fixed in all cases