Added template to work with Eduard's SQL