added mkdir -p tables so that tables folder will be created in case it does not exit