Modify connect to db canexecute