diff --git a/xos/models/models.py b/xos/models/models.py
index 2e7df7b..594255a 100644
--- a/xos/models/models.py
+++ b/xos/models/models.py
@@ -15,6 +15,14 @@
 class ProgranService(ProgranService_decl):
     class Meta:
         proxy = True
+    def save(self, *args, **kwargs):
+
+        existing_services = ProgranService.objects.all()
+
+        if len(existing_services) > 0 and not self.delete:
+            raise XOSValidationError("A ProgranService already exists, you should not have more than one")
+
+        super(ProgranService, self).save(*args, **kwargs)
 
 
 class ENodeB(ENodeB_decl):
@@ -33,19 +41,18 @@
 
     def save(self, *args, **kwargs):
         # NOTE someone is setting owner_id, so just override it for now
-        # if not self.owner_id:
-        services = Service.objects.all()
-        services = [s for s in services if s.name.lower() == 'progran']
-
-        # NOTE select the correct owner
         try:
-            progran_service = services[0]
+            # NOTE we allow just one ProgranService
+            progran_service = ProgranService.objects.all()[0]
             self.owner_id = progran_service.id
         except IndexError:
             raise XOSValidationError("Service Progran cannot be found, please make sure that the model exists.")
 
         # NOTE if the instance is new, check that the name is not duplicated
         instances_with_same_name = None
+        # FIXME This may leave us vulnerable to someone changing the name at a later time and causing a conflict.
+        # If that's important to prevent, we could prevent that case when `self.pk!=None`,
+        # filter for ProgranServiceInstance with the same name but `pk!=self.pk`.
         if self.pk is None:
             try:
                 instances_with_same_name = ProgranServiceInstance.objects.get(name=self.name)
diff --git a/xos/models/progran.xproto b/xos/models/progran.xproto
index 14206ac..909f6e1 100644
--- a/xos/models/progran.xproto
+++ b/xos/models/progran.xproto
@@ -43,8 +43,8 @@
     required string end = 6 [content_type = "date", null = False, blank = True];
     required string AdmControl = 7 [default = "0", choices = "(('0', 'ALL'), ('1', 'Voice Only'), ('2', 'Data Only'))", max_length = 1, blank = False, null = False, db_index = False];
     required int32 CellIndividualOffset = 8 [db_index = False, null = False, blank = False];
-    required manytoone enodeb->ENodeB:profiles = 9 [db_index = True, null = False, blank = False];
-    required manytoone handover->Handover:profiles = 10 [db_index = True, null = True, blank = False];
+    required manytoone enodeb->ENodeB:profiles = 9 [null = True, blank = True];
+    required manytoone handover->Handover:profiles = 10 [null = False, blank = False];
 }
 
 
