     (mapping [:CreationTime] :CreationTime)
     (mapping [:Validity] :Validity)
     (mapping [:Scheme] :Scheme))
-  (add-relation :mappingPolicy_fk_ShareId))
+  (add-association :mappingPolicy_fk_ShareId))
 
 (foreach [:accesspolicy]
   (add-instance :AcessPolicy
     (mapping-pk [:Id] :Id))
-  (add-relation :accessPolicy_fk_EndpointId))
+  (add-association :accessPolicy_fk_EndpointId))

    (mapping [:Type] :Type)
    (mapping [:QualityLevel] :QualityLevel)
    (mapping [:Complexity] :Complexity))
  (add-relation :service_fk_LocationId)
  (add-relation :service_fk_AdminDomainId))
;TODO ASSOC SERVICE: CONTACT   (table "serviceservice" :serviceservice (column "serviceId2" :serviceId2 :pk :notnull) (column "contactId" :contactId :pk :notnull))
;TODO ASSOC SERVICE: SERVICE (table "serviceservice" :serviceservice (column "serviceId2" :serviceId2 :pk :notnull) (column "serviceId1" :serviceId1 :pk :notnull))


    (mapping [:Name] :Name)
    (mapping [:CreationTime] :CreationTime)
    (mapping [:Validity] :Validity))
  (add-association :activity_fk_EndpointId)
  (add-association :activity_fk_ResourceId)
  (add-association :activity_fk_ShareId)
  (add-association :activity_fk_UserDomainId))
;TODO ASSOC ACTIIVITY: ACTIVITY (table "activityactivity" :activityactivity  (column "activityId2" :activityId2 :pk :notnull)  (column "activityId1" :activityId1 :pk :notnull))

(foreach [:contact]
