convert db name to id for templates call