put machine templates in relation table