The following sample SQL repository definition file overrides the default SQL definition file. It removes several properties from the default configuration, and it adds an ldapUser property, as described in step 4 above. It also modifies the default login property definition as specified in step 5.

<gsa-template>
  <item-descriptor name="user">

    <table name="dps_user">

      <!-- Remove properties which are in LDAP -->
      <property name="password" xml-combine="remove"/>
      <property name="email" xml-combine="remove"/>
      <property name="firstName" xml-combine="remove"/>
      <property name="lastName" xml-combine="remove"/>

      <!-- Replicate unique id property into LDAP -->
      <property name="login"
          property-type="atg.adapter.gsa.ReplicatePropertyDescriptor">
        <attribute name="replicateProperty" value="ldapUser.login"/>
      </property>

    </table>

    <!-- Add property which points to the LDAP item -->
    <property name="ldapUser"
        property-type="atg.repository.linked.RepositoryLinkPropertyDescriptor"
        repository="/atg/adapter/ldap/LDAPRepository"
        item-type="user"
        category="Info"
        display-name="Linked LDAP User"
        cascade="insert,update,delete"
        queryable="false">
      <attribute name="uniqueIdPropertyLocal" value="login"/>
      <attribute name="uniqueIdPropertyRemote" value="login"/>
    </property>

  </item-descriptor>
</gsa-template>

See the Sample LDAP Profile Repository Definition File section of the Setting Up an LDAP Profile Repository chapter for a sample LDAP repository definition file. No changes are needed to the LDAP definition file to set up repository linking.