fixes bug by splitting the create query