updated create.sql to contain check constraints, small changes to php