sql file generation