database orm issue fixed