﻿<?xml version="1.0" encoding="utf-8"?>
<edmx:Edmx Version="3.0" xmlns:edmx="http://schemas.microsoft.com/ado/2009/11/edmx">
  <!-- EF Runtime content -->
  <edmx:Runtime>
    <!-- SSDL content -->
    <edmx:StorageModels>
    <Schema Namespace="BuddyFinance.Model.Store" Provider="System.Data.SqlClient" ProviderManifestToken="2012" Alias="Self" xmlns:store="http://schemas.microsoft.com/ado/2007/12/edm/EntityStoreSchemaGenerator" xmlns:customannotation="http://schemas.microsoft.com/ado/2013/11/edm/customannotation" xmlns="http://schemas.microsoft.com/ado/2009/11/edm/ssdl">
        <EntityType Name="ActivityLog">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="int" StoreGeneratedPattern="Identity" Nullable="false" />
          <Property Name="Type" Type="nvarchar" MaxLength="200" Nullable="false" />
          <Property Name="TimeStamp" Type="datetime" Nullable="false" />
          <Property Name="Description" Type="nvarchar(max)" Nullable="false" />
          <Property Name="UserId" Type="int" />
          <Property Name="IpAddress" Type="nvarchar" MaxLength="200" Nullable="false" />
          <Property Name="UserAgent" Type="nvarchar" MaxLength="200" Nullable="false" />
        </EntityType>
        <EntityType Name="AddressType">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="int" StoreGeneratedPattern="Identity" Nullable="false" />
          <Property Name="Description" Type="nvarchar" MaxLength="150" Nullable="false" />
        </EntityType>
        <EntityType Name="AuthenticationCode">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="int" StoreGeneratedPattern="Identity" Nullable="false" />
          <Property Name="Code" Type="nvarchar(max)" Nullable="false" />
          <Property Name="Number" Type="nvarchar" MaxLength="150" />
          <Property Name="Type" Type="varchar" MaxLength="50" />
          <Property Name="IsValid" Type="bit" Nullable="false" />
        </EntityType>
        <EntityType Name="BankingDetail">
          <Key>
            <PropertyRef Name="ProfileId" />
          </Key>
          <Property Name="ProfileId" Type="int" Nullable="false" />
          <Property Name="BankName" Type="nvarchar" MaxLength="50" />
          <Property Name="AccountType" Type="nvarchar" MaxLength="50" />
          <Property Name="BranchName" Type="nvarchar" MaxLength="50" />
          <Property Name="BranchCode" Type="nvarchar" MaxLength="50" />
          <Property Name="AccountName" Type="nvarchar" MaxLength="50" />
          <Property Name="AccountNumber" Type="nvarchar" MaxLength="50" />
        </EntityType>
        <EntityType Name="Borrower">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="int" Nullable="false" />
          <Property Name="BorrowerNumber" Type="nvarchar" MaxLength="50" Nullable="false" />
          <Property Name="ProfileTypeId" Type="int" Nullable="false" />
          <Property Name="StatusId" Type="int" Nullable="false" />
        </EntityType>
        <EntityType Name="CashDeposit">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="int" StoreGeneratedPattern="Identity" Nullable="false" />
          <Property Name="ProfileId" Type="int" Nullable="false" />
          <Property Name="Amount" Type="float" Nullable="false" />
          <Property Name="Date" Type="datetime" Nullable="false" />
          <Property Name="Comment" Type="nvarchar(max)" />
          <Property Name="UserId" Type="int" Nullable="false" />
        </EntityType>
        <EntityType Name="CashWithdrawal">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="int" StoreGeneratedPattern="Identity" Nullable="false" />
          <Property Name="ProfileId" Type="int" Nullable="false" />
          <Property Name="Amount" Type="float" Nullable="false" />
          <Property Name="Date" Type="datetime" Nullable="false" />
          <Property Name="Comment" Type="nvarchar(max)" />
          <Property Name="StatusId" Type="int" Nullable="false" />
          <Property Name="ReviewerId" Type="int" />
          <Property Name="ReviewDate" Type="datetime" />
        </EntityType>
        <EntityType Name="CashWithdrawalStatus">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="int" StoreGeneratedPattern="Identity" Nullable="false" />
          <Property Name="Description" Type="nvarchar" MaxLength="90" Nullable="false" />
        </EntityType>
        <EntityType Name="Country">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="int" StoreGeneratedPattern="Identity" Nullable="false" />
          <Property Name="CountryCode" Type="nvarchar" MaxLength="20" Nullable="false" />
          <Property Name="CountryName" Type="nvarchar" MaxLength="70" Nullable="false" />
        </EntityType>
        <EntityType Name="DocumentType">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="int" StoreGeneratedPattern="Identity" Nullable="false" />
          <Property Name="Description" Type="nvarchar" MaxLength="70" Nullable="false" />
        </EntityType>
        <EntityType Name="EmploymentDetail">
          <Key>
            <PropertyRef Name="ProfileId" />
          </Key>
          <Property Name="ProfileId" Type="int" Nullable="false" />
          <Property Name="EmploymentTypeId" Type="int" />
          <Property Name="EmployerName" Type="nvarchar" MaxLength="50" />
          <Property Name="EmployerContactNumber" Type="nvarchar" MaxLength="50" />
          <Property Name="EmploymentStartDate" Type="datetime" />
          <Property Name="EmploymentEndDate" Type="datetime" />
          <Property Name="GrossMonthlyIncome" Type="float" />
          <Property Name="NetMonthlyIncome" Type="float" />
          <Property Name="EmployerNumber" Type="nvarchar" MaxLength="50" />
          <Property Name="SalaryDay" Type="int" />
          <Property Name="BillingDay" Type="int" />
        </EntityType>
        <EntityType Name="EmploymentStatus">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="int" StoreGeneratedPattern="Identity" Nullable="false" />
          <Property Name="Description" Type="nvarchar" MaxLength="50" Nullable="false" />
        </EntityType>
        <EntityType Name="EmploymentType">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="int" StoreGeneratedPattern="Identity" Nullable="false" />
          <Property Name="Description" Type="nvarchar" MaxLength="70" Nullable="false" />
        </EntityType>
        <EntityType Name="Ethnicity">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="int" StoreGeneratedPattern="Identity" Nullable="false" />
          <Property Name="Description" Type="nvarchar" MaxLength="70" Nullable="false" />
        </EntityType>
        <EntityType Name="FeeType">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="int" StoreGeneratedPattern="Identity" Nullable="false" />
          <Property Name="Description" Type="nvarchar" MaxLength="50" Nullable="false" />
          <Property Name="Basis" Type="float" Nullable="false" />
          <Property Name="Amount" Type="float" Nullable="false" />
          <Property Name="Percentage" Type="float" Nullable="false" />
          <Property Name="VatPercentage" Type="float" Nullable="false" />
          <Property Name="AmountForPercentUse" Type="float" Nullable="false" />
        </EntityType>
        <EntityType Name="FicaCompliance">
          <Key>
            <PropertyRef Name="ProfileId" />
          </Key>
          <Property Name="ProfileId" Type="int" Nullable="false" />
          <Property Name="FicaStatusId" Type="int" Nullable="false" />
          <Property Name="VerificationDate" Type="datetime" />
        </EntityType>
        <EntityType Name="FicaComplianceDocuments">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="int" StoreGeneratedPattern="Identity" Nullable="false" />
          <Property Name="FicaComplianceId" Type="int" Nullable="false" />
          <Property Name="DocumentTypeId" Type="int" Nullable="false" />
          <Property Name="FileId" Type="int" Nullable="false" />
        </EntityType>
        <EntityType Name="FicaStatus">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="int" StoreGeneratedPattern="Identity" Nullable="false" />
          <Property Name="Description" Type="nvarchar" MaxLength="50" Nullable="false" />
        </EntityType>
        <EntityType Name="FileData">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="int" StoreGeneratedPattern="Identity" Nullable="false" />
          <Property Name="FileName" Type="nvarchar" MaxLength="150" Nullable="false" />
          <Property Name="Contents" Type="varbinary(max)" Nullable="false" />
          <Property Name="Size" Type="int" Nullable="false" />
          <Property Name="ContentType" Type="nvarchar(max)" Nullable="false" />
          <Property Name="FileUrl" Type="nvarchar(max)" />
        </EntityType>
        <EntityType Name="Gender">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="int" StoreGeneratedPattern="Identity" Nullable="false" />
          <Property Name="Description" Type="nvarchar" MaxLength="50" />
        </EntityType>
        <EntityType Name="GlobalSetup">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="uniqueidentifier" Nullable="false" />
          <Property Name="InterestType" Type="int" Nullable="false" />
          <Property Name="ExpenseFactor" Type="decimal" Precision="18" Scale="4" Nullable="false" />
          <Property Name="ServiceFee" Type="decimal" Precision="18" Scale="4" Nullable="false" />
          <Property Name="TransUnionSecurityCode" Type="nvarchar" MaxLength="50" Nullable="false" />
          <Property Name="TransUnionSubscriberCode" Type="nvarchar" MaxLength="50" Nullable="false" />
        </EntityType>
        <EntityType Name="IdentificationType">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="int" StoreGeneratedPattern="Identity" Nullable="false" />
          <Property Name="Description" Type="nvarchar" MaxLength="50" />
        </EntityType>
        <EntityType Name="Lender">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="int" Nullable="false" />
          <Property Name="LenderNumber" Type="nvarchar" MaxLength="50" Nullable="false" />
          <Property Name="ProfileTypeId" Type="int" Nullable="false" />
          <Property Name="StatusId" Type="int" Nullable="false" />
        </EntityType>
        <EntityType Name="Loan">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="int" StoreGeneratedPattern="Identity" Nullable="false" />
          <Property Name="LoanRequestId" Type="int" Nullable="false" />
          <Property Name="LoanOfferId" Type="int" Nullable="false" />
          <Property Name="BorrowerId" Type="int" />
          <Property Name="LenderId" Type="int" />
          <Property Name="LoanAmount" Type="float" Nullable="false" />
          <Property Name="FirstRepaymentDate" Type="datetime" Nullable="false" />
          <Property Name="LoanDuration" Type="int" Nullable="false" />
          <Property Name="TermTypeId" Type="int" Nullable="false" />
          <Property Name="LoanStatusId" Type="int" Nullable="false" />
          <Property Name="CreatedDate" Type="datetime" Nullable="false" />
          <Property Name="InitialPaymentAmount" Type="float" Nullable="false" />
          <Property Name="DateAccepted" Type="datetime" />
          <Property Name="MonthlyInstallmentAmount" Type="float" Nullable="false" />
          <Property Name="TotalPayment" Type="float" Nullable="false" />
          <Property Name="Comment" Type="nvarchar(max)" />
          <Property Name="RepayCompletedDate" Type="datetime" />
        </EntityType>
        <EntityType Name="LoanEarningBracket">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="int" StoreGeneratedPattern="Identity" Nullable="false" />
          <Property Name="MinAmount" Type="float" Nullable="false" />
          <Property Name="MaxAmount" Type="float" Nullable="false" />
          <Property Name="QualifyingAmount" Type="float" Nullable="false" />
        </EntityType>
        <EntityType Name="LoanOffer">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="int" StoreGeneratedPattern="Identity" Nullable="false" />
          <Property Name="LenderId" Type="int" Nullable="false" />
          <Property Name="Amount" Type="float" Nullable="false" />
          <Property Name="Balance" Type="float" Nullable="false" />
          <Property Name="InterestRate" Type="float" Nullable="false" />
          <Property Name="Term" Type="int" Nullable="false" />
          <Property Name="TermTypeId" Type="int" Nullable="false" />
          <Property Name="IsActive" Type="bit" Nullable="false" />
          <Property Name="DateCreated" Type="datetime" Nullable="false" />
          <Property Name="ExpiryDate" Type="datetime" />
          <Property Name="IsDeleted" Type="bit" Nullable="false" />
        </EntityType>
        <EntityType Name="LoanPayout">
          <Key>
            <PropertyRef Name="LoanId" />
          </Key>
          <Property Name="LoanId" Type="int" Nullable="false" />
          <Property Name="PayoutDate" Type="datetime" Nullable="false" />
          <Property Name="PayoutAmount" Type="float" Nullable="false" />
        </EntityType>
        <EntityType Name="LoanRepayment">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="int" StoreGeneratedPattern="Identity" Nullable="false" />
          <Property Name="LoanId" Type="int" Nullable="false" />
          <Property Name="PaymentAmount" Type="float" Nullable="false" />
          <Property Name="PaymentDate" Type="datetime" Nullable="false" />
          <Property Name="PaymentMethod" Type="nvarchar" MaxLength="50" Nullable="false" />
          <Property Name="LoanScheduleId" Type="int" />
          <Property Name="LoanRepaymentStatusId" Type="int" Nullable="false" />
        </EntityType>
        <EntityType Name="LoanRepaymentStatus">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="int" StoreGeneratedPattern="Identity" Nullable="false" />
          <Property Name="Description" Type="nvarchar" MaxLength="90" Nullable="false" />
        </EntityType>
        <EntityType Name="LoanRequest">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="int" StoreGeneratedPattern="Identity" Nullable="false" />
          <Property Name="RequestedDate" Type="datetime" Nullable="false" />
          <Property Name="BorrowerId" Type="int" Nullable="false" />
          <Property Name="Amount" Type="float" Nullable="false" />
          <Property Name="Term" Type="int" Nullable="false" />
          <Property Name="TermTypeId" Type="int" Nullable="false" />
          <Property Name="FirstPaymentDate" Type="datetime" Nullable="false" />
          <Property Name="ReferenceNumber" Type="nvarchar" MaxLength="50" />
          <Property Name="LoanRequestStatusId" Type="int" Nullable="false" />
        </EntityType>
        <EntityType Name="LoanRequestOffer">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="int" StoreGeneratedPattern="Identity" Nullable="false" />
          <Property Name="RequestDate" Type="datetime" Nullable="false" />
          <Property Name="Comments" Type="nvarchar" MaxLength="500" />
          <Property Name="OfferStausId" Type="int" Nullable="false" />
          <Property Name="LoanOfferId" Type="int" Nullable="false" />
          <Property Name="LoanRequestId" Type="int" Nullable="false" />
          <Property Name="IsActive" Type="bit" Nullable="false" />
          <Property Name="IOU_Accepted" Type="bit" Nullable="false" />
        </EntityType>
        <EntityType Name="LoanRequestScore">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="int" Nullable="false" />
        </EntityType>
        <EntityType Name="LoanRequestStatus">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="int" StoreGeneratedPattern="Identity" Nullable="false" />
          <Property Name="Description" Type="nvarchar" MaxLength="70" Nullable="false" />
        </EntityType>
        <EntityType Name="LoanSchedule">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="int" StoreGeneratedPattern="Identity" Nullable="false" />
          <Property Name="Description" Type="nvarchar" MaxLength="70" Nullable="false" />
          <Property Name="Amount" Type="float" Nullable="false" />
          <Property Name="ExpectedPayDate" Type="datetime" Nullable="false" />
          <Property Name="StatusId" Type="int" Nullable="false" />
          <Property Name="LoanId" Type="int" Nullable="false" />
        </EntityType>
        <EntityType Name="LoanScheduleFee">
          <Key>
            <PropertyRef Name="LoanScheduleId" />
          </Key>
          <Property Name="LoanScheduleId" Type="int" Nullable="false" />
          <Property Name="BillDate" Type="datetime" Nullable="false" />
          <Property Name="TransactionFeeId" Type="int" Nullable="false" />
        </EntityType>
        <EntityType Name="LoanScheduleStatus">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="int" StoreGeneratedPattern="Identity" Nullable="false" />
          <Property Name="Description" Type="nvarchar" MaxLength="70" Nullable="false" />
        </EntityType>
        <EntityType Name="LoanStatus">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="int" StoreGeneratedPattern="Identity" Nullable="false" />
          <Property Name="Description" Type="nvarchar" MaxLength="70" Nullable="false" />
        </EntityType>
        <EntityType Name="LoanTermBracket">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="int" StoreGeneratedPattern="Identity" Nullable="false" />
          <Property Name="MinAmount" Type="float" Nullable="false" />
          <Property Name="MaxAmount" Type="float" Nullable="false" />
          <Property Name="Duration" Type="int" Nullable="false" />
        </EntityType>
        <EntityType Name="ManualDeduction">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="int" StoreGeneratedPattern="Identity" Nullable="false" />
          <Property Name="Amount" Type="float" Nullable="false" />
          <Property Name="Description" Type="nvarchar(max)" />
          <Property Name="DeductionDate" Type="datetime" Nullable="false" />
          <Property Name="ProfileId" Type="int" Nullable="false" />
          <Property Name="UserId" Type="int" Nullable="false" />
        </EntityType>
        <EntityType Name="NextOfKin">
          <Key>
            <PropertyRef Name="ProfileId" />
          </Key>
          <Property Name="ProfileId" Type="int" Nullable="false" />
          <Property Name="Name" Type="nvarchar" MaxLength="100" />
          <Property Name="RelationshipType" Type="nvarchar" MaxLength="100" />
          <Property Name="ContactNumber" Type="nvarchar" MaxLength="20" />
          <Property Name="Income" Type="float" />
        </EntityType>
        <EntityType Name="Notification">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="int" StoreGeneratedPattern="Identity" Nullable="false" />
          <Property Name="Recipient" Type="nvarchar" MaxLength="100" Nullable="false" />
          <Property Name="Message" Type="nvarchar(max)" Nullable="false" />
          <Property Name="Status" Type="nvarchar" MaxLength="100" Nullable="false" />
          <Property Name="NotificationTypeId" Type="int" Nullable="false" />
          <Property Name="DateSent" Type="datetime" Nullable="false" />
        </EntityType>
        <EntityType Name="NotificationType">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="int" StoreGeneratedPattern="Identity" Nullable="false" />
          <Property Name="Description" Type="nvarchar" MaxLength="50" Nullable="false" />
        </EntityType>
        <EntityType Name="OfferStatus">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="int" StoreGeneratedPattern="Identity" Nullable="false" />
          <Property Name="Description" Type="nvarchar" MaxLength="50" Nullable="false" />
        </EntityType>
        <EntityType Name="PreLoanRequest">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="int" StoreGeneratedPattern="Identity" Nullable="false" />
          <Property Name="RequestedDate" Type="datetime" Nullable="false" />
          <Property Name="BorrowerId" Type="int" Nullable="false" />
          <Property Name="Amount" Type="float" Nullable="false" />
          <Property Name="Term" Type="int" Nullable="false" />
          <Property Name="TermTypeId" Type="int" Nullable="false" />
          <Property Name="FirstPaymentDate" Type="datetime" Nullable="false" />
          <Property Name="ReferenceNumber" Type="nvarchar" MaxLength="50" />
          <Property Name="LoanRequestStatusId" Type="int" Nullable="false" />
        </EntityType>
        <EntityType Name="Profile">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="int" StoreGeneratedPattern="Identity" Nullable="false" />
          <Property Name="ProfileNumber" Type="nvarchar" MaxLength="50" Nullable="false" />
          <Property Name="LendServiceAccount" Type="bit" />
          <Property Name="BorrowServiceAccount" Type="bit" />
          <Property Name="Title" Type="nvarchar" MaxLength="50" />
          <Property Name="Name" Type="nvarchar" MaxLength="50" Nullable="false" />
          <Property Name="Surname" Type="nvarchar" MaxLength="50" Nullable="false" />
          <Property Name="EmailAddress" Type="nvarchar" MaxLength="50" Nullable="false" />
          <Property Name="ContactNumber" Type="nvarchar" MaxLength="50" />
          <Property Name="DateOfBirth" Type="datetime" />
          <Property Name="GenderId" Type="int" />
          <Property Name="CountryOfBirthId" Type="int" />
          <Property Name="EthnicityId" Type="int" />
          <Property Name="IdentificationTypeId" Type="int" />
          <Property Name="IdentificationNumber" Type="nvarchar" MaxLength="50" Nullable="false" />
          <Property Name="AvailableFunds" Type="float" Nullable="false" />
          <Property Name="CashDeposit" Type="float" />
          <Property Name="CashWithdrawal" Type="float" />
          <Property Name="TaxRegistered" Type="bit" />
          <Property Name="SourceOfIncomeId" Type="int" />
          <Property Name="OtherSourceOfIncome" Type="nvarchar" MaxLength="50" />
          <Property Name="EmploymentStatusId" Type="int" />
          <Property Name="StatusId" Type="int" Nullable="false" />
          <Property Name="BillingDate" Type="datetime" />
          <Property Name="LastBillDate" Type="datetime" />
        </EntityType>
        <EntityType Name="ProfileAddress">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="int" StoreGeneratedPattern="Identity" Nullable="false" />
          <Property Name="ProfileId" Type="int" Nullable="false" />
          <Property Name="AddressTypeId" Type="int" Nullable="false" />
          <Property Name="Line1" Type="nvarchar" MaxLength="50" Nullable="false" />
          <Property Name="Line2" Type="nvarchar" MaxLength="50" />
          <Property Name="City" Type="nvarchar" MaxLength="50" />
          <Property Name="PostalCode" Type="nvarchar" MaxLength="50" />
          <Property Name="ProvinceId" Type="int" />
          <Property Name="CountryId" Type="int" />
          <Property Name="IsDeleted" Type="bit" Nullable="false" />
        </EntityType>
        <EntityType Name="ProfileApproval">
          <Key>
            <PropertyRef Name="ProfileId" />
          </Key>
          <Property Name="ProfileId" Type="int" Nullable="false" />
          <Property Name="ProfileStatusId" Type="int" Nullable="false" />
          <Property Name="RejectReason" Type="nvarchar" MaxLength="2000" />
          <Property Name="ReviewDate" Type="datetime" Nullable="false" />
          <Property Name="ReviewerId" Type="int" Nullable="false" />
        </EntityType>
        <EntityType Name="ProfileCreditRatingScore">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="int" StoreGeneratedPattern="Identity" Nullable="false" />
          <Property Name="ProfileId" Type="int" Nullable="false" />
          <Property Name="BorrowerId" Type="int" />
          <Property Name="LoanRequestOfferId" Type="int" />
          <Property Name="CreditBureauScore" Type="int" Nullable="false" />
          <Property Name="DerivedScore" Type="int" Nullable="false" />
          <Property Name="CreditBureauRobotScoreId" Type="int" Nullable="false" />
          <Property Name="DerivedRobotScoreId" Type="int" Nullable="false" />
          <Property Name="ScoreDate" Type="datetime" Nullable="false" />
          <Property Name="Firstname" Type="nvarchar" MaxLength="50" Nullable="false" />
          <Property Name="Lastname" Type="nvarchar" MaxLength="50" Nullable="false" />
        </EntityType>
        <EntityType Name="ProfileDocument">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="int" StoreGeneratedPattern="Identity" Nullable="false" />
          <Property Name="FileId" Type="int" Nullable="false" />
          <Property Name="UploadedDate" Type="datetime" Nullable="false" />
          <Property Name="DocumentTypeId" Type="int" Nullable="false" />
          <Property Name="ProfileId" Type="int" Nullable="false" />
          <Property Name="IsDeleted" Type="bit" Nullable="false" />
        </EntityType>
        <EntityType Name="ProfileStatus">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="int" StoreGeneratedPattern="Identity" Nullable="false" />
          <Property Name="Description" Type="nvarchar" MaxLength="50" />
        </EntityType>
        <EntityType Name="ProfileSuspension">
          <Key>
            <PropertyRef Name="ProfileId" />
          </Key>
          <Property Name="ProfileId" Type="int" Nullable="false" />
          <Property Name="StartDate" Type="datetime" Nullable="false" />
          <Property Name="EndDate" Type="datetime" />
          <Property Name="Reason" Type="nvarchar(max)" />
          <Property Name="ReviewerId" Type="int" Nullable="false" />
        </EntityType>
        <EntityType Name="ProfileType">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="int" StoreGeneratedPattern="Identity" Nullable="false" />
          <Property Name="Description" Type="nvarchar" MaxLength="50" Nullable="false" />
        </EntityType>
        <EntityType Name="Province">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="int" StoreGeneratedPattern="Identity" Nullable="false" />
          <Property Name="Description" Type="varchar" MaxLength="150" Nullable="false" />
        </EntityType>
        <EntityType Name="RequestLog">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="int" StoreGeneratedPattern="Identity" Nullable="false" />
          <Property Name="RequestType" Type="nvarchar" MaxLength="50" Nullable="false" />
          <Property Name="Timestamp" Type="datetime" Nullable="false" />
          <Property Name="RequestXML" Type="xml" Nullable="false" />
          <Property Name="ResponseCode" Type="nvarchar" MaxLength="50" />
          <Property Name="ResponseMessage" Type="nvarchar" MaxLength="500" />
          <Property Name="ResponseXML" Type="xml" />
        </EntityType>
        <EntityType Name="RobotScore">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="int" StoreGeneratedPattern="Identity" Nullable="false" />
          <Property Name="MinScore" Type="int" Nullable="false" />
          <Property Name="MaxScore" Type="int" Nullable="false" />
          <Property Name="RobotColor" Type="nvarchar" MaxLength="50" Nullable="false" />
          <Property Name="Description" Type="nvarchar" MaxLength="250" Nullable="false" />
        </EntityType>
        <EntityType Name="SourceOfFunds">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="int" StoreGeneratedPattern="Identity" Nullable="false" />
          <Property Name="Description" Type="nvarchar" MaxLength="50" Nullable="false" />
        </EntityType>
        <EntityType Name="SourceOfIncome">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="int" StoreGeneratedPattern="Identity" Nullable="false" />
          <Property Name="Description" Type="nvarchar" MaxLength="50" Nullable="false" />
        </EntityType>
        <EntityType Name="TaxIdentificationType">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="int" StoreGeneratedPattern="Identity" Nullable="false" />
          <Property Name="Description" Type="nvarchar" MaxLength="50" />
        </EntityType>
        <EntityType Name="TaxInformation">
          <Key>
            <PropertyRef Name="ProfileId" />
          </Key>
          <Property Name="ProfileId" Type="int" Nullable="false" />
          <Property Name="TaxIdentificationTypeId" Type="int" Nullable="false" />
          <Property Name="TaxNumber" Type="nvarchar" MaxLength="50" Nullable="false" />
          <Property Name="TaxCountryId" Type="int" Nullable="false" />
        </EntityType>
        <EntityType Name="TermType">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="int" StoreGeneratedPattern="Identity" Nullable="false" />
          <Property Name="Description" Type="nvarchar" MaxLength="70" Nullable="false" />
        </EntityType>
        <EntityType Name="Transaction">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="int" StoreGeneratedPattern="Identity" Nullable="false" />
          <Property Name="ProfileId" Type="int" Nullable="false" />
          <Property Name="ProfileTypeId" Type="int" Nullable="false" />
          <Property Name="TransactionDate" Type="datetime" Nullable="false" />
          <Property Name="Description" Type="nvarchar" MaxLength="250" Nullable="false" />
          <Property Name="Reference" Type="nvarchar" MaxLength="70" Nullable="false" />
          <Property Name="TransactionTypeId" Type="int" Nullable="false" />
          <Property Name="Amount" Type="float" Nullable="false" />
          <Property Name="TransactionStatusId" Type="int" Nullable="false" />
          <Property Name="LoanId" Type="int" />
          <Property Name="LoanRequestId" Type="int" />
          <Property Name="LoanRepaymentId" Type="int" />
        </EntityType>
        <EntityType Name="TransactionFee">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="int" StoreGeneratedPattern="Identity" Nullable="false" />
          <Property Name="TransactionId" Type="int" Nullable="false" />
          <Property Name="FeeTypeId" Type="int" Nullable="false" />
          <Property Name="FeeAmount" Type="float" Nullable="false" />
        </EntityType>
        <EntityType Name="TransactionStatus">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="int" StoreGeneratedPattern="Identity" Nullable="false" />
          <Property Name="Description" Type="nvarchar" MaxLength="90" Nullable="false" />
        </EntityType>
        <EntityType Name="TransactionType">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="int" StoreGeneratedPattern="Identity" Nullable="false" />
          <Property Name="Description" Type="nvarchar" MaxLength="70" Nullable="false" />
        </EntityType>
        <EntityType Name="User">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="int" StoreGeneratedPattern="Identity" Nullable="false" />
          <Property Name="UserName" Type="nvarchar" MaxLength="250" Nullable="false" />
          <Property Name="Name" Type="nvarchar" MaxLength="150" />
          <Property Name="Surname" Type="nvarchar" MaxLength="150" />
          <Property Name="MobileNumber" Type="nvarchar" MaxLength="150" />
          <Property Name="Password" Type="nvarchar(max)" Nullable="false" />
          <Property Name="PasswordHash" Type="nvarchar(max)" Nullable="false" />
          <Property Name="SignUpDate" Type="datetime" />
          <Property Name="LastLoginDate" Type="datetime" />
          <Property Name="MustChangePassword" Type="bit" Nullable="false" />
          <Property Name="ProfileId" Type="int" Nullable="false" />
          <Property Name="RoleId" Type="int" Nullable="false" />
          <Property Name="IsActive" Type="bit" Nullable="false" />
          <Property Name="AccountVerified" Type="bit" Nullable="false" />
        </EntityType>
        <EntityType Name="UserRole">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="int" StoreGeneratedPattern="Identity" Nullable="false" />
          <Property Name="Name" Type="nvarchar" MaxLength="90" Nullable="false" />
        </EntityType>
        <Association Name="FK_ActivityLog_User">
          <End Role="User" Type="Self.User" Multiplicity="0..1" />
          <End Role="ActivityLog" Type="Self.ActivityLog" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="User">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="ActivityLog">
              <PropertyRef Name="UserId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_BankingDetail_Profile">
          <End Role="Profile" Type="Self.Profile" Multiplicity="1" />
          <End Role="BankingDetail" Type="Self.BankingDetail" Multiplicity="0..1" />
          <ReferentialConstraint>
            <Principal Role="Profile">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="BankingDetail">
              <PropertyRef Name="ProfileId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_Borrower_Profile">
          <End Role="Profile" Type="Self.Profile" Multiplicity="1" />
          <End Role="Borrower" Type="Self.Borrower" Multiplicity="0..1" />
          <ReferentialConstraint>
            <Principal Role="Profile">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="Borrower">
              <PropertyRef Name="Id" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_Borrower_ProfileStatus">
          <End Role="ProfileStatus" Type="Self.ProfileStatus" Multiplicity="1" />
          <End Role="Borrower" Type="Self.Borrower" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="ProfileStatus">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="Borrower">
              <PropertyRef Name="StatusId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_Borrower_ProfileType">
          <End Role="ProfileType" Type="Self.ProfileType" Multiplicity="1" />
          <End Role="Borrower" Type="Self.Borrower" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="ProfileType">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="Borrower">
              <PropertyRef Name="ProfileTypeId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_CashDeposit_Profile">
          <End Role="Profile" Type="Self.Profile" Multiplicity="1" />
          <End Role="CashDeposit" Type="Self.CashDeposit" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="Profile">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="CashDeposit">
              <PropertyRef Name="ProfileId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_CashDeposit_User">
          <End Role="User" Type="Self.User" Multiplicity="1" />
          <End Role="CashDeposit" Type="Self.CashDeposit" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="User">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="CashDeposit">
              <PropertyRef Name="UserId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_CashWithdrawal_Profile">
          <End Role="Profile" Type="Self.Profile" Multiplicity="1" />
          <End Role="CashWithdrawal" Type="Self.CashWithdrawal" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="Profile">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="CashWithdrawal">
              <PropertyRef Name="ProfileId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_CashWithdrawal_Status">
          <End Role="CashWithdrawalStatus" Type="Self.CashWithdrawalStatus" Multiplicity="1" />
          <End Role="CashWithdrawal" Type="Self.CashWithdrawal" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="CashWithdrawalStatus">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="CashWithdrawal">
              <PropertyRef Name="StatusId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_CashWithdrawal_User">
          <End Role="User" Type="Self.User" Multiplicity="0..1" />
          <End Role="CashWithdrawal" Type="Self.CashWithdrawal" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="User">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="CashWithdrawal">
              <PropertyRef Name="ReviewerId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_EmploymentDetail_EmploymentType">
          <End Role="EmploymentType" Type="Self.EmploymentType" Multiplicity="0..1" />
          <End Role="EmploymentDetail" Type="Self.EmploymentDetail" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="EmploymentType">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="EmploymentDetail">
              <PropertyRef Name="EmploymentTypeId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_EmploymentDetail_ProfileId">
          <End Role="Profile" Type="Self.Profile" Multiplicity="1" />
          <End Role="EmploymentDetail" Type="Self.EmploymentDetail" Multiplicity="0..1" />
          <ReferentialConstraint>
            <Principal Role="Profile">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="EmploymentDetail">
              <PropertyRef Name="ProfileId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_FicaCompliance_FicaStatus">
          <End Role="FicaStatus" Type="Self.FicaStatus" Multiplicity="1" />
          <End Role="FicaCompliance" Type="Self.FicaCompliance" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="FicaStatus">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="FicaCompliance">
              <PropertyRef Name="FicaStatusId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_FicaCompliance_Profile">
          <End Role="Profile" Type="Self.Profile" Multiplicity="1" />
          <End Role="FicaCompliance" Type="Self.FicaCompliance" Multiplicity="0..1" />
          <ReferentialConstraint>
            <Principal Role="Profile">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="FicaCompliance">
              <PropertyRef Name="ProfileId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_FicaComplianceDocuments_DocumentType">
          <End Role="DocumentType" Type="Self.DocumentType" Multiplicity="1" />
          <End Role="FicaComplianceDocuments" Type="Self.FicaComplianceDocuments" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="DocumentType">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="FicaComplianceDocuments">
              <PropertyRef Name="DocumentTypeId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_FicaComplianceDocuments_FicaCompliance">
          <End Role="FicaCompliance" Type="Self.FicaCompliance" Multiplicity="1" />
          <End Role="FicaComplianceDocuments" Type="Self.FicaComplianceDocuments" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="FicaCompliance">
              <PropertyRef Name="ProfileId" />
            </Principal>
            <Dependent Role="FicaComplianceDocuments">
              <PropertyRef Name="FicaComplianceId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_FicaComplianceDocuments_FileData">
          <End Role="FileData" Type="Self.FileData" Multiplicity="1" />
          <End Role="FicaComplianceDocuments" Type="Self.FicaComplianceDocuments" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="FileData">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="FicaComplianceDocuments">
              <PropertyRef Name="FileId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_Lender_Profile">
          <End Role="Profile" Type="Self.Profile" Multiplicity="1" />
          <End Role="Lender" Type="Self.Lender" Multiplicity="0..1" />
          <ReferentialConstraint>
            <Principal Role="Profile">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="Lender">
              <PropertyRef Name="Id" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_Lender_ProfileStatus">
          <End Role="ProfileStatus" Type="Self.ProfileStatus" Multiplicity="1" />
          <End Role="Lender" Type="Self.Lender" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="ProfileStatus">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="Lender">
              <PropertyRef Name="StatusId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_Lender_ProfileType">
          <End Role="ProfileType" Type="Self.ProfileType" Multiplicity="1" />
          <End Role="Lender" Type="Self.Lender" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="ProfileType">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="Lender">
              <PropertyRef Name="ProfileTypeId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_Loan_Borrower">
          <End Role="Borrower" Type="Self.Borrower" Multiplicity="0..1" />
          <End Role="Loan" Type="Self.Loan" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="Borrower">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="Loan">
              <PropertyRef Name="BorrowerId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_Loan_Lender">
          <End Role="Lender" Type="Self.Lender" Multiplicity="0..1" />
          <End Role="Loan" Type="Self.Loan" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="Lender">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="Loan">
              <PropertyRef Name="LenderId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_Loan_LoanOffer">
          <End Role="LoanOffer" Type="Self.LoanOffer" Multiplicity="1" />
          <End Role="Loan" Type="Self.Loan" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="LoanOffer">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="Loan">
              <PropertyRef Name="LoanOfferId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_Loan_LoanRequest">
          <End Role="LoanRequest" Type="Self.LoanRequest" Multiplicity="1" />
          <End Role="Loan" Type="Self.Loan" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="LoanRequest">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="Loan">
              <PropertyRef Name="LoanRequestId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_Loan_LoanStatus">
          <End Role="LoanStatus" Type="Self.LoanStatus" Multiplicity="1" />
          <End Role="Loan" Type="Self.Loan" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="LoanStatus">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="Loan">
              <PropertyRef Name="LoanStatusId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_Loan_TermType">
          <End Role="TermType" Type="Self.TermType" Multiplicity="1" />
          <End Role="Loan" Type="Self.Loan" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="TermType">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="Loan">
              <PropertyRef Name="TermTypeId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_LoanOffer_Lender">
          <End Role="Lender" Type="Self.Lender" Multiplicity="1" />
          <End Role="LoanOffer" Type="Self.LoanOffer" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="Lender">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="LoanOffer">
              <PropertyRef Name="LenderId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_LoanOffer_TermType">
          <End Role="TermType" Type="Self.TermType" Multiplicity="1" />
          <End Role="LoanOffer" Type="Self.LoanOffer" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="TermType">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="LoanOffer">
              <PropertyRef Name="TermTypeId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_LoanPayout_Loan">
          <End Role="Loan" Type="Self.Loan" Multiplicity="1" />
          <End Role="LoanPayout" Type="Self.LoanPayout" Multiplicity="0..1" />
          <ReferentialConstraint>
            <Principal Role="Loan">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="LoanPayout">
              <PropertyRef Name="LoanId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_LoanRepayment_Loan">
          <End Role="Loan" Type="Self.Loan" Multiplicity="1" />
          <End Role="LoanRepayment" Type="Self.LoanRepayment" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="Loan">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="LoanRepayment">
              <PropertyRef Name="LoanId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_LoanRepayment_LoanRepaymentStatus">
          <End Role="LoanRepaymentStatus" Type="Self.LoanRepaymentStatus" Multiplicity="1" />
          <End Role="LoanRepayment" Type="Self.LoanRepayment" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="LoanRepaymentStatus">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="LoanRepayment">
              <PropertyRef Name="LoanRepaymentStatusId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_LoanRepayment_LoanSchedule">
          <End Role="LoanSchedule" Type="Self.LoanSchedule" Multiplicity="0..1" />
          <End Role="LoanRepayment" Type="Self.LoanRepayment" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="LoanSchedule">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="LoanRepayment">
              <PropertyRef Name="LoanScheduleId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_LoanRequest_Borrower">
          <End Role="Borrower" Type="Self.Borrower" Multiplicity="1" />
          <End Role="LoanRequest" Type="Self.LoanRequest" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="Borrower">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="LoanRequest">
              <PropertyRef Name="BorrowerId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_LoanRequest_LoanRequestStatus">
          <End Role="LoanRequestStatus" Type="Self.LoanRequestStatus" Multiplicity="1" />
          <End Role="LoanRequest" Type="Self.LoanRequest" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="LoanRequestStatus">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="LoanRequest">
              <PropertyRef Name="LoanRequestStatusId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_LoanRequest_TermType">
          <End Role="TermType" Type="Self.TermType" Multiplicity="1" />
          <End Role="LoanRequest" Type="Self.LoanRequest" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="TermType">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="LoanRequest">
              <PropertyRef Name="TermTypeId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_LoanRequestOffer_LoanOffer">
          <End Role="LoanOffer" Type="Self.LoanOffer" Multiplicity="1" />
          <End Role="LoanRequestOffer" Type="Self.LoanRequestOffer" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="LoanOffer">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="LoanRequestOffer">
              <PropertyRef Name="LoanOfferId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_LoanRequestOffer_LoanRequest">
          <End Role="LoanRequest" Type="Self.LoanRequest" Multiplicity="1" />
          <End Role="LoanRequestOffer" Type="Self.LoanRequestOffer" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="LoanRequest">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="LoanRequestOffer">
              <PropertyRef Name="LoanRequestId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_LoanRequestOffer_OfferStaus">
          <End Role="OfferStatus" Type="Self.OfferStatus" Multiplicity="1" />
          <End Role="LoanRequestOffer" Type="Self.LoanRequestOffer" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="OfferStatus">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="LoanRequestOffer">
              <PropertyRef Name="OfferStausId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_LoanSchedule_Loan">
          <End Role="Loan" Type="Self.Loan" Multiplicity="1" />
          <End Role="LoanSchedule" Type="Self.LoanSchedule" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="Loan">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="LoanSchedule">
              <PropertyRef Name="LoanId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_LoanSchedule_LoanScheduleStatus">
          <End Role="LoanScheduleStatus" Type="Self.LoanScheduleStatus" Multiplicity="1" />
          <End Role="LoanSchedule" Type="Self.LoanSchedule" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="LoanScheduleStatus">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="LoanSchedule">
              <PropertyRef Name="StatusId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_LoanScheduleFee_LoanSchedule">
          <End Role="LoanSchedule" Type="Self.LoanSchedule" Multiplicity="1" />
          <End Role="LoanScheduleFee" Type="Self.LoanScheduleFee" Multiplicity="0..1" />
          <ReferentialConstraint>
            <Principal Role="LoanSchedule">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="LoanScheduleFee">
              <PropertyRef Name="LoanScheduleId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_LoanScheduleFee_TransactionFee">
          <End Role="TransactionFee" Type="Self.TransactionFee" Multiplicity="1" />
          <End Role="LoanScheduleFee" Type="Self.LoanScheduleFee" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="TransactionFee">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="LoanScheduleFee">
              <PropertyRef Name="TransactionFeeId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_ManualDeduction_Profile">
          <End Role="Profile" Type="Self.Profile" Multiplicity="1" />
          <End Role="ManualDeduction" Type="Self.ManualDeduction" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="Profile">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="ManualDeduction">
              <PropertyRef Name="ProfileId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_ManualDeduction_User">
          <End Role="User" Type="Self.User" Multiplicity="1" />
          <End Role="ManualDeduction" Type="Self.ManualDeduction" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="User">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="ManualDeduction">
              <PropertyRef Name="UserId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_NextOfKin_Profile">
          <End Role="Profile" Type="Self.Profile" Multiplicity="1" />
          <End Role="NextOfKin" Type="Self.NextOfKin" Multiplicity="0..1" />
          <ReferentialConstraint>
            <Principal Role="Profile">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="NextOfKin">
              <PropertyRef Name="ProfileId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_Notification_NotificationType">
          <End Role="NotificationType" Type="Self.NotificationType" Multiplicity="1" />
          <End Role="Notification" Type="Self.Notification" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="NotificationType">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="Notification">
              <PropertyRef Name="NotificationTypeId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_PreLoanRequest_LoanRequestStatus">
          <End Role="LoanRequestStatus" Type="Self.LoanRequestStatus" Multiplicity="1" />
          <End Role="PreLoanRequest" Type="Self.PreLoanRequest" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="LoanRequestStatus">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="PreLoanRequest">
              <PropertyRef Name="LoanRequestStatusId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_PreLoanRequest_Profile">
          <End Role="Profile" Type="Self.Profile" Multiplicity="1" />
          <End Role="PreLoanRequest" Type="Self.PreLoanRequest" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="Profile">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="PreLoanRequest">
              <PropertyRef Name="BorrowerId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_PreLoanRequest_TermType">
          <End Role="TermType" Type="Self.TermType" Multiplicity="1" />
          <End Role="PreLoanRequest" Type="Self.PreLoanRequest" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="TermType">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="PreLoanRequest">
              <PropertyRef Name="TermTypeId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_Profile_Country">
          <End Role="Country" Type="Self.Country" Multiplicity="0..1" />
          <End Role="Profile" Type="Self.Profile" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="Country">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="Profile">
              <PropertyRef Name="CountryOfBirthId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_Profile_EmploymentStatus">
          <End Role="EmploymentStatus" Type="Self.EmploymentStatus" Multiplicity="0..1" />
          <End Role="Profile" Type="Self.Profile" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="EmploymentStatus">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="Profile">
              <PropertyRef Name="EmploymentStatusId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_Profile_Ethnicity">
          <End Role="Ethnicity" Type="Self.Ethnicity" Multiplicity="0..1" />
          <End Role="Profile" Type="Self.Profile" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="Ethnicity">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="Profile">
              <PropertyRef Name="EthnicityId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_Profile_Gender">
          <End Role="Gender" Type="Self.Gender" Multiplicity="0..1" />
          <End Role="Profile" Type="Self.Profile" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="Gender">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="Profile">
              <PropertyRef Name="GenderId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_Profile_IdentificationType">
          <End Role="IdentificationType" Type="Self.IdentificationType" Multiplicity="0..1" />
          <End Role="Profile" Type="Self.Profile" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="IdentificationType">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="Profile">
              <PropertyRef Name="IdentificationTypeId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_Profile_ProfileStatus">
          <End Role="ProfileStatus" Type="Self.ProfileStatus" Multiplicity="1" />
          <End Role="Profile" Type="Self.Profile" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="ProfileStatus">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="Profile">
              <PropertyRef Name="StatusId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_Profile_SourceOfIncome">
          <End Role="SourceOfIncome" Type="Self.SourceOfIncome" Multiplicity="0..1" />
          <End Role="Profile" Type="Self.Profile" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="SourceOfIncome">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="Profile">
              <PropertyRef Name="SourceOfIncomeId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_ProfileAddress_AddressType">
          <End Role="AddressType" Type="Self.AddressType" Multiplicity="1" />
          <End Role="ProfileAddress" Type="Self.ProfileAddress" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="AddressType">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="ProfileAddress">
              <PropertyRef Name="AddressTypeId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_ProfileAddress_Country">
          <End Role="Country" Type="Self.Country" Multiplicity="0..1" />
          <End Role="ProfileAddress" Type="Self.ProfileAddress" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="Country">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="ProfileAddress">
              <PropertyRef Name="CountryId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_ProfileAddress_Profile">
          <End Role="Profile" Type="Self.Profile" Multiplicity="1" />
          <End Role="ProfileAddress" Type="Self.ProfileAddress" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="Profile">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="ProfileAddress">
              <PropertyRef Name="ProfileId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_ProfileAddress_Province">
          <End Role="Province" Type="Self.Province" Multiplicity="0..1" />
          <End Role="ProfileAddress" Type="Self.ProfileAddress" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="Province">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="ProfileAddress">
              <PropertyRef Name="ProvinceId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_ProfileApproval_Profile">
          <End Role="Profile" Type="Self.Profile" Multiplicity="1" />
          <End Role="ProfileApproval" Type="Self.ProfileApproval" Multiplicity="0..1" />
          <ReferentialConstraint>
            <Principal Role="Profile">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="ProfileApproval">
              <PropertyRef Name="ProfileId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_ProfileApproval_ProfileStatusId">
          <End Role="ProfileStatus" Type="Self.ProfileStatus" Multiplicity="1" />
          <End Role="ProfileApproval" Type="Self.ProfileApproval" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="ProfileStatus">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="ProfileApproval">
              <PropertyRef Name="ProfileStatusId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_ProfileApproval_User">
          <End Role="User" Type="Self.User" Multiplicity="1" />
          <End Role="ProfileApproval" Type="Self.ProfileApproval" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="User">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="ProfileApproval">
              <PropertyRef Name="ReviewerId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_ProfileCreditRatingScore_Borrower">
          <End Role="Profile" Type="Self.Profile" Multiplicity="0..1" />
          <End Role="ProfileCreditRatingScore" Type="Self.ProfileCreditRatingScore" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="Profile">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="ProfileCreditRatingScore">
              <PropertyRef Name="BorrowerId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_ProfileCreditRatingScore_CrediBureauRobotScore">
          <End Role="RobotScore" Type="Self.RobotScore" Multiplicity="1" />
          <End Role="ProfileCreditRatingScore" Type="Self.ProfileCreditRatingScore" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="RobotScore">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="ProfileCreditRatingScore">
              <PropertyRef Name="CreditBureauRobotScoreId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_ProfileCreditRatingScore_LoanRequestOffer">
          <End Role="LoanRequestOffer" Type="Self.LoanRequestOffer" Multiplicity="0..1" />
          <End Role="ProfileCreditRatingScore" Type="Self.ProfileCreditRatingScore" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="LoanRequestOffer">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="ProfileCreditRatingScore">
              <PropertyRef Name="LoanRequestOfferId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_ProfileCreditRatingScore_Profile">
          <End Role="Profile" Type="Self.Profile" Multiplicity="1" />
          <End Role="ProfileCreditRatingScore" Type="Self.ProfileCreditRatingScore" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="Profile">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="ProfileCreditRatingScore">
              <PropertyRef Name="ProfileId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_ProfileCreditRatingScore_RobotScore">
          <End Role="RobotScore" Type="Self.RobotScore" Multiplicity="1" />
          <End Role="ProfileCreditRatingScore" Type="Self.ProfileCreditRatingScore" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="RobotScore">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="ProfileCreditRatingScore">
              <PropertyRef Name="DerivedRobotScoreId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_ProfileDocument_DocumentType">
          <End Role="DocumentType" Type="Self.DocumentType" Multiplicity="1" />
          <End Role="ProfileDocument" Type="Self.ProfileDocument" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="DocumentType">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="ProfileDocument">
              <PropertyRef Name="DocumentTypeId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_ProfileDocument_FileData">
          <End Role="FileData" Type="Self.FileData" Multiplicity="1" />
          <End Role="ProfileDocument" Type="Self.ProfileDocument" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="FileData">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="ProfileDocument">
              <PropertyRef Name="FileId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_ProfileDocument_Profile">
          <End Role="Profile" Type="Self.Profile" Multiplicity="1" />
          <End Role="ProfileDocument" Type="Self.ProfileDocument" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="Profile">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="ProfileDocument">
              <PropertyRef Name="ProfileId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_ProfileSuspension_Profile">
          <End Role="Profile" Type="Self.Profile" Multiplicity="1" />
          <End Role="ProfileSuspension" Type="Self.ProfileSuspension" Multiplicity="0..1" />
          <ReferentialConstraint>
            <Principal Role="Profile">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="ProfileSuspension">
              <PropertyRef Name="ProfileId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_ProfileSuspension_User">
          <End Role="User" Type="Self.User" Multiplicity="1" />
          <End Role="ProfileSuspension" Type="Self.ProfileSuspension" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="User">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="ProfileSuspension">
              <PropertyRef Name="ReviewerId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_TaxInformation_Country">
          <End Role="Country" Type="Self.Country" Multiplicity="1" />
          <End Role="TaxInformation" Type="Self.TaxInformation" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="Country">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="TaxInformation">
              <PropertyRef Name="TaxCountryId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_TaxInformation_Profile">
          <End Role="Profile" Type="Self.Profile" Multiplicity="1" />
          <End Role="TaxInformation" Type="Self.TaxInformation" Multiplicity="0..1" />
          <ReferentialConstraint>
            <Principal Role="Profile">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="TaxInformation">
              <PropertyRef Name="ProfileId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_TaxInformation_TaxIdentificationType">
          <End Role="TaxIdentificationType" Type="Self.TaxIdentificationType" Multiplicity="1" />
          <End Role="TaxInformation" Type="Self.TaxInformation" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="TaxIdentificationType">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="TaxInformation">
              <PropertyRef Name="TaxIdentificationTypeId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_Transaction_Loan">
          <End Role="Loan" Type="Self.Loan" Multiplicity="0..1" />
          <End Role="Transaction" Type="Self.Transaction" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="Loan">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="Transaction">
              <PropertyRef Name="LoanId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_Transaction_LoanRequest">
          <End Role="LoanRequest" Type="Self.LoanRequest" Multiplicity="0..1" />
          <End Role="Transaction" Type="Self.Transaction" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="LoanRequest">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="Transaction">
              <PropertyRef Name="LoanRequestId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_Transaction_Profile">
          <End Role="Profile" Type="Self.Profile" Multiplicity="1" />
          <End Role="Transaction" Type="Self.Transaction" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="Profile">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="Transaction">
              <PropertyRef Name="ProfileId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_Transaction_ProfileType">
          <End Role="ProfileType" Type="Self.ProfileType" Multiplicity="1" />
          <End Role="Transaction" Type="Self.Transaction" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="ProfileType">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="Transaction">
              <PropertyRef Name="ProfileTypeId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_Transaction_Repayment">
          <End Role="LoanRepayment" Type="Self.LoanRepayment" Multiplicity="0..1" />
          <End Role="Transaction" Type="Self.Transaction" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="LoanRepayment">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="Transaction">
              <PropertyRef Name="LoanRepaymentId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_Transaction_TransactionStatus">
          <End Role="TransactionStatus" Type="Self.TransactionStatus" Multiplicity="1" />
          <End Role="Transaction" Type="Self.Transaction" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="TransactionStatus">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="Transaction">
              <PropertyRef Name="TransactionStatusId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_Transaction_TransactionType">
          <End Role="TransactionType" Type="Self.TransactionType" Multiplicity="1" />
          <End Role="Transaction" Type="Self.Transaction" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="TransactionType">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="Transaction">
              <PropertyRef Name="TransactionTypeId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_TransactionFee_FeeType">
          <End Role="FeeType" Type="Self.FeeType" Multiplicity="1" />
          <End Role="TransactionFee" Type="Self.TransactionFee" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="FeeType">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="TransactionFee">
              <PropertyRef Name="FeeTypeId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_TransactionFee_Transaction">
          <End Role="Transaction" Type="Self.Transaction" Multiplicity="1" />
          <End Role="TransactionFee" Type="Self.TransactionFee" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="Transaction">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="TransactionFee">
              <PropertyRef Name="TransactionId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_User_Profile">
          <End Role="Profile" Type="Self.Profile" Multiplicity="1" />
          <End Role="User" Type="Self.User" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="Profile">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="User">
              <PropertyRef Name="ProfileId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_User_UserRole">
          <End Role="UserRole" Type="Self.UserRole" Multiplicity="1" />
          <End Role="User" Type="Self.User" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="UserRole">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="User">
              <PropertyRef Name="RoleId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Function Name="ProfileTransactions" Aggregate="false" BuiltIn="false" NiladicFunction="false" IsComposable="false" ParameterTypeSemantics="AllowImplicitConversion" Schema="dbo">
          <Parameter Name="profileId" Type="int" Mode="In" />
          <Parameter Name="startDate" Type="nvarchar" Mode="In" />
          <Parameter Name="endDate" Type="nvarchar" Mode="In" />
        </Function>
        <EntityContainer Name="BuddyFinanceModelStoreContainer">
          <EntitySet Name="ActivityLog" EntityType="Self.ActivityLog" Schema="dbo" store:Type="Tables" />
          <EntitySet Name="AddressType" EntityType="Self.AddressType" Schema="dbo" store:Type="Tables" />
          <EntitySet Name="AuthenticationCode" EntityType="Self.AuthenticationCode" Schema="dbo" store:Type="Tables" />
          <EntitySet Name="BankingDetail" EntityType="Self.BankingDetail" Schema="dbo" store:Type="Tables" />
          <EntitySet Name="Borrower" EntityType="Self.Borrower" Schema="dbo" store:Type="Tables" />
          <EntitySet Name="CashDeposit" EntityType="Self.CashDeposit" Schema="dbo" store:Type="Tables" />
          <EntitySet Name="CashWithdrawal" EntityType="Self.CashWithdrawal" Schema="dbo" store:Type="Tables" />
          <EntitySet Name="CashWithdrawalStatus" EntityType="Self.CashWithdrawalStatus" Schema="dbo" store:Type="Tables" />
          <EntitySet Name="Country" EntityType="Self.Country" Schema="dbo" store:Type="Tables" />
          <EntitySet Name="DocumentType" EntityType="Self.DocumentType" Schema="dbo" store:Type="Tables" />
          <EntitySet Name="EmploymentDetail" EntityType="Self.EmploymentDetail" Schema="dbo" store:Type="Tables" />
          <EntitySet Name="EmploymentStatus" EntityType="Self.EmploymentStatus" Schema="dbo" store:Type="Tables" />
          <EntitySet Name="EmploymentType" EntityType="Self.EmploymentType" Schema="dbo" store:Type="Tables" />
          <EntitySet Name="Ethnicity" EntityType="Self.Ethnicity" Schema="dbo" store:Type="Tables" />
          <EntitySet Name="FeeType" EntityType="Self.FeeType" Schema="dbo" store:Type="Tables" />
          <EntitySet Name="FicaCompliance" EntityType="Self.FicaCompliance" Schema="dbo" store:Type="Tables" />
          <EntitySet Name="FicaComplianceDocuments" EntityType="Self.FicaComplianceDocuments" Schema="dbo" store:Type="Tables" />
          <EntitySet Name="FicaStatus" EntityType="Self.FicaStatus" Schema="dbo" store:Type="Tables" />
          <EntitySet Name="FileData" EntityType="Self.FileData" Schema="dbo" store:Type="Tables" />
          <EntitySet Name="Gender" EntityType="Self.Gender" Schema="dbo" store:Type="Tables" />
          <EntitySet Name="GlobalSetup" EntityType="Self.GlobalSetup" Schema="dbo" store:Type="Tables" />
          <EntitySet Name="IdentificationType" EntityType="Self.IdentificationType" Schema="dbo" store:Type="Tables" />
          <EntitySet Name="Lender" EntityType="Self.Lender" Schema="dbo" store:Type="Tables" />
          <EntitySet Name="Loan" EntityType="Self.Loan" Schema="dbo" store:Type="Tables" />
          <EntitySet Name="LoanEarningBracket" EntityType="Self.LoanEarningBracket" Schema="dbo" store:Type="Tables" />
          <EntitySet Name="LoanOffer" EntityType="Self.LoanOffer" Schema="dbo" store:Type="Tables" />
          <EntitySet Name="LoanPayout" EntityType="Self.LoanPayout" Schema="dbo" store:Type="Tables" />
          <EntitySet Name="LoanRepayment" EntityType="Self.LoanRepayment" Schema="dbo" store:Type="Tables" />
          <EntitySet Name="LoanRepaymentStatus" EntityType="Self.LoanRepaymentStatus" Schema="dbo" store:Type="Tables" />
          <EntitySet Name="LoanRequest" EntityType="Self.LoanRequest" Schema="dbo" store:Type="Tables" />
          <EntitySet Name="LoanRequestOffer" EntityType="Self.LoanRequestOffer" Schema="dbo" store:Type="Tables" />
          <EntitySet Name="LoanRequestScore" EntityType="Self.LoanRequestScore" Schema="dbo" store:Type="Tables" />
          <EntitySet Name="LoanRequestStatus" EntityType="Self.LoanRequestStatus" Schema="dbo" store:Type="Tables" />
          <EntitySet Name="LoanSchedule" EntityType="Self.LoanSchedule" Schema="dbo" store:Type="Tables" />
          <EntitySet Name="LoanScheduleFee" EntityType="Self.LoanScheduleFee" Schema="dbo" store:Type="Tables" />
          <EntitySet Name="LoanScheduleStatus" EntityType="Self.LoanScheduleStatus" Schema="dbo" store:Type="Tables" />
          <EntitySet Name="LoanStatus" EntityType="Self.LoanStatus" Schema="dbo" store:Type="Tables" />
          <EntitySet Name="LoanTermBracket" EntityType="Self.LoanTermBracket" Schema="dbo" store:Type="Tables" />
          <EntitySet Name="ManualDeduction" EntityType="Self.ManualDeduction" Schema="dbo" store:Type="Tables" />
          <EntitySet Name="NextOfKin" EntityType="Self.NextOfKin" Schema="dbo" store:Type="Tables" />
          <EntitySet Name="Notification" EntityType="Self.Notification" Schema="dbo" store:Type="Tables" />
          <EntitySet Name="NotificationType" EntityType="Self.NotificationType" Schema="dbo" store:Type="Tables" />
          <EntitySet Name="OfferStatus" EntityType="Self.OfferStatus" Schema="dbo" store:Type="Tables" />
          <EntitySet Name="PreLoanRequest" EntityType="Self.PreLoanRequest" Schema="dbo" store:Type="Tables" />
          <EntitySet Name="Profile" EntityType="Self.Profile" Schema="dbo" store:Type="Tables" />
          <EntitySet Name="ProfileAddress" EntityType="Self.ProfileAddress" Schema="dbo" store:Type="Tables" />
          <EntitySet Name="ProfileApproval" EntityType="Self.ProfileApproval" Schema="dbo" store:Type="Tables" />
          <EntitySet Name="ProfileCreditRatingScore" EntityType="Self.ProfileCreditRatingScore" Schema="dbo" store:Type="Tables" />
          <EntitySet Name="ProfileDocument" EntityType="Self.ProfileDocument" Schema="dbo" store:Type="Tables" />
          <EntitySet Name="ProfileStatus" EntityType="Self.ProfileStatus" Schema="dbo" store:Type="Tables" />
          <EntitySet Name="ProfileSuspension" EntityType="Self.ProfileSuspension" Schema="dbo" store:Type="Tables" />
          <EntitySet Name="ProfileType" EntityType="Self.ProfileType" Schema="dbo" store:Type="Tables" />
          <EntitySet Name="Province" EntityType="Self.Province" Schema="dbo" store:Type="Tables" />
          <EntitySet Name="RequestLog" EntityType="Self.RequestLog" Schema="dbo" store:Type="Tables" />
          <EntitySet Name="RobotScore" EntityType="Self.RobotScore" Schema="dbo" store:Type="Tables" />
          <EntitySet Name="SourceOfFunds" EntityType="Self.SourceOfFunds" Schema="dbo" store:Type="Tables" />
          <EntitySet Name="SourceOfIncome" EntityType="Self.SourceOfIncome" Schema="dbo" store:Type="Tables" />
          <EntitySet Name="TaxIdentificationType" EntityType="Self.TaxIdentificationType" Schema="dbo" store:Type="Tables" />
          <EntitySet Name="TaxInformation" EntityType="Self.TaxInformation" Schema="dbo" store:Type="Tables" />
          <EntitySet Name="TermType" EntityType="Self.TermType" Schema="dbo" store:Type="Tables" />
          <EntitySet Name="Transaction" EntityType="Self.Transaction" Schema="dbo" store:Type="Tables" />
          <EntitySet Name="TransactionFee" EntityType="Self.TransactionFee" Schema="dbo" store:Type="Tables" />
          <EntitySet Name="TransactionStatus" EntityType="Self.TransactionStatus" Schema="dbo" store:Type="Tables" />
          <EntitySet Name="TransactionType" EntityType="Self.TransactionType" Schema="dbo" store:Type="Tables" />
          <EntitySet Name="User" EntityType="Self.User" Schema="dbo" store:Type="Tables" />
          <EntitySet Name="UserRole" EntityType="Self.UserRole" Schema="dbo" store:Type="Tables" />
          <AssociationSet Name="FK_ActivityLog_User" Association="Self.FK_ActivityLog_User">
            <End Role="User" EntitySet="User" />
            <End Role="ActivityLog" EntitySet="ActivityLog" />
          </AssociationSet>
          <AssociationSet Name="FK_BankingDetail_Profile" Association="Self.FK_BankingDetail_Profile">
            <End Role="Profile" EntitySet="Profile" />
            <End Role="BankingDetail" EntitySet="BankingDetail" />
          </AssociationSet>
          <AssociationSet Name="FK_Borrower_Profile" Association="Self.FK_Borrower_Profile">
            <End Role="Profile" EntitySet="Profile" />
            <End Role="Borrower" EntitySet="Borrower" />
          </AssociationSet>
          <AssociationSet Name="FK_Borrower_ProfileStatus" Association="Self.FK_Borrower_ProfileStatus">
            <End Role="ProfileStatus" EntitySet="ProfileStatus" />
            <End Role="Borrower" EntitySet="Borrower" />
          </AssociationSet>
          <AssociationSet Name="FK_Borrower_ProfileType" Association="Self.FK_Borrower_ProfileType">
            <End Role="ProfileType" EntitySet="ProfileType" />
            <End Role="Borrower" EntitySet="Borrower" />
          </AssociationSet>
          <AssociationSet Name="FK_CashDeposit_Profile" Association="Self.FK_CashDeposit_Profile">
            <End Role="Profile" EntitySet="Profile" />
            <End Role="CashDeposit" EntitySet="CashDeposit" />
          </AssociationSet>
          <AssociationSet Name="FK_CashDeposit_User" Association="Self.FK_CashDeposit_User">
            <End Role="User" EntitySet="User" />
            <End Role="CashDeposit" EntitySet="CashDeposit" />
          </AssociationSet>
          <AssociationSet Name="FK_CashWithdrawal_Profile" Association="Self.FK_CashWithdrawal_Profile">
            <End Role="Profile" EntitySet="Profile" />
            <End Role="CashWithdrawal" EntitySet="CashWithdrawal" />
          </AssociationSet>
          <AssociationSet Name="FK_CashWithdrawal_Status" Association="Self.FK_CashWithdrawal_Status">
            <End Role="CashWithdrawalStatus" EntitySet="CashWithdrawalStatus" />
            <End Role="CashWithdrawal" EntitySet="CashWithdrawal" />
          </AssociationSet>
          <AssociationSet Name="FK_CashWithdrawal_User" Association="Self.FK_CashWithdrawal_User">
            <End Role="User" EntitySet="User" />
            <End Role="CashWithdrawal" EntitySet="CashWithdrawal" />
          </AssociationSet>
          <AssociationSet Name="FK_EmploymentDetail_EmploymentType" Association="Self.FK_EmploymentDetail_EmploymentType">
            <End Role="EmploymentType" EntitySet="EmploymentType" />
            <End Role="EmploymentDetail" EntitySet="EmploymentDetail" />
          </AssociationSet>
          <AssociationSet Name="FK_EmploymentDetail_ProfileId" Association="Self.FK_EmploymentDetail_ProfileId">
            <End Role="Profile" EntitySet="Profile" />
            <End Role="EmploymentDetail" EntitySet="EmploymentDetail" />
          </AssociationSet>
          <AssociationSet Name="FK_FicaCompliance_FicaStatus" Association="Self.FK_FicaCompliance_FicaStatus">
            <End Role="FicaStatus" EntitySet="FicaStatus" />
            <End Role="FicaCompliance" EntitySet="FicaCompliance" />
          </AssociationSet>
          <AssociationSet Name="FK_FicaCompliance_Profile" Association="Self.FK_FicaCompliance_Profile">
            <End Role="Profile" EntitySet="Profile" />
            <End Role="FicaCompliance" EntitySet="FicaCompliance" />
          </AssociationSet>
          <AssociationSet Name="FK_FicaComplianceDocuments_DocumentType" Association="Self.FK_FicaComplianceDocuments_DocumentType">
            <End Role="DocumentType" EntitySet="DocumentType" />
            <End Role="FicaComplianceDocuments" EntitySet="FicaComplianceDocuments" />
          </AssociationSet>
          <AssociationSet Name="FK_FicaComplianceDocuments_FicaCompliance" Association="Self.FK_FicaComplianceDocuments_FicaCompliance">
            <End Role="FicaCompliance" EntitySet="FicaCompliance" />
            <End Role="FicaComplianceDocuments" EntitySet="FicaComplianceDocuments" />
          </AssociationSet>
          <AssociationSet Name="FK_FicaComplianceDocuments_FileData" Association="Self.FK_FicaComplianceDocuments_FileData">
            <End Role="FileData" EntitySet="FileData" />
            <End Role="FicaComplianceDocuments" EntitySet="FicaComplianceDocuments" />
          </AssociationSet>
          <AssociationSet Name="FK_Lender_Profile" Association="Self.FK_Lender_Profile">
            <End Role="Profile" EntitySet="Profile" />
            <End Role="Lender" EntitySet="Lender" />
          </AssociationSet>
          <AssociationSet Name="FK_Lender_ProfileStatus" Association="Self.FK_Lender_ProfileStatus">
            <End Role="ProfileStatus" EntitySet="ProfileStatus" />
            <End Role="Lender" EntitySet="Lender" />
          </AssociationSet>
          <AssociationSet Name="FK_Lender_ProfileType" Association="Self.FK_Lender_ProfileType">
            <End Role="ProfileType" EntitySet="ProfileType" />
            <End Role="Lender" EntitySet="Lender" />
          </AssociationSet>
          <AssociationSet Name="FK_Loan_Borrower" Association="Self.FK_Loan_Borrower">
            <End Role="Borrower" EntitySet="Borrower" />
            <End Role="Loan" EntitySet="Loan" />
          </AssociationSet>
          <AssociationSet Name="FK_Loan_Lender" Association="Self.FK_Loan_Lender">
            <End Role="Lender" EntitySet="Lender" />
            <End Role="Loan" EntitySet="Loan" />
          </AssociationSet>
          <AssociationSet Name="FK_Loan_LoanOffer" Association="Self.FK_Loan_LoanOffer">
            <End Role="LoanOffer" EntitySet="LoanOffer" />
            <End Role="Loan" EntitySet="Loan" />
          </AssociationSet>
          <AssociationSet Name="FK_Loan_LoanRequest" Association="Self.FK_Loan_LoanRequest">
            <End Role="LoanRequest" EntitySet="LoanRequest" />
            <End Role="Loan" EntitySet="Loan" />
          </AssociationSet>
          <AssociationSet Name="FK_Loan_LoanStatus" Association="Self.FK_Loan_LoanStatus">
            <End Role="LoanStatus" EntitySet="LoanStatus" />
            <End Role="Loan" EntitySet="Loan" />
          </AssociationSet>
          <AssociationSet Name="FK_Loan_TermType" Association="Self.FK_Loan_TermType">
            <End Role="TermType" EntitySet="TermType" />
            <End Role="Loan" EntitySet="Loan" />
          </AssociationSet>
          <AssociationSet Name="FK_LoanOffer_Lender" Association="Self.FK_LoanOffer_Lender">
            <End Role="Lender" EntitySet="Lender" />
            <End Role="LoanOffer" EntitySet="LoanOffer" />
          </AssociationSet>
          <AssociationSet Name="FK_LoanOffer_TermType" Association="Self.FK_LoanOffer_TermType">
            <End Role="TermType" EntitySet="TermType" />
            <End Role="LoanOffer" EntitySet="LoanOffer" />
          </AssociationSet>
          <AssociationSet Name="FK_LoanPayout_Loan" Association="Self.FK_LoanPayout_Loan">
            <End Role="Loan" EntitySet="Loan" />
            <End Role="LoanPayout" EntitySet="LoanPayout" />
          </AssociationSet>
          <AssociationSet Name="FK_LoanRepayment_Loan" Association="Self.FK_LoanRepayment_Loan">
            <End Role="Loan" EntitySet="Loan" />
            <End Role="LoanRepayment" EntitySet="LoanRepayment" />
          </AssociationSet>
          <AssociationSet Name="FK_LoanRepayment_LoanRepaymentStatus" Association="Self.FK_LoanRepayment_LoanRepaymentStatus">
            <End Role="LoanRepaymentStatus" EntitySet="LoanRepaymentStatus" />
            <End Role="LoanRepayment" EntitySet="LoanRepayment" />
          </AssociationSet>
          <AssociationSet Name="FK_LoanRepayment_LoanSchedule" Association="Self.FK_LoanRepayment_LoanSchedule">
            <End Role="LoanSchedule" EntitySet="LoanSchedule" />
            <End Role="LoanRepayment" EntitySet="LoanRepayment" />
          </AssociationSet>
          <AssociationSet Name="FK_LoanRequest_Borrower" Association="Self.FK_LoanRequest_Borrower">
            <End Role="Borrower" EntitySet="Borrower" />
            <End Role="LoanRequest" EntitySet="LoanRequest" />
          </AssociationSet>
          <AssociationSet Name="FK_LoanRequest_LoanRequestStatus" Association="Self.FK_LoanRequest_LoanRequestStatus">
            <End Role="LoanRequestStatus" EntitySet="LoanRequestStatus" />
            <End Role="LoanRequest" EntitySet="LoanRequest" />
          </AssociationSet>
          <AssociationSet Name="FK_LoanRequest_TermType" Association="Self.FK_LoanRequest_TermType">
            <End Role="TermType" EntitySet="TermType" />
            <End Role="LoanRequest" EntitySet="LoanRequest" />
          </AssociationSet>
          <AssociationSet Name="FK_LoanRequestOffer_LoanOffer" Association="Self.FK_LoanRequestOffer_LoanOffer">
            <End Role="LoanOffer" EntitySet="LoanOffer" />
            <End Role="LoanRequestOffer" EntitySet="LoanRequestOffer" />
          </AssociationSet>
          <AssociationSet Name="FK_LoanRequestOffer_LoanRequest" Association="Self.FK_LoanRequestOffer_LoanRequest">
            <End Role="LoanRequest" EntitySet="LoanRequest" />
            <End Role="LoanRequestOffer" EntitySet="LoanRequestOffer" />
          </AssociationSet>
          <AssociationSet Name="FK_LoanRequestOffer_OfferStaus" Association="Self.FK_LoanRequestOffer_OfferStaus">
            <End Role="OfferStatus" EntitySet="OfferStatus" />
            <End Role="LoanRequestOffer" EntitySet="LoanRequestOffer" />
          </AssociationSet>
          <AssociationSet Name="FK_LoanSchedule_Loan" Association="Self.FK_LoanSchedule_Loan">
            <End Role="Loan" EntitySet="Loan" />
            <End Role="LoanSchedule" EntitySet="LoanSchedule" />
          </AssociationSet>
          <AssociationSet Name="FK_LoanSchedule_LoanScheduleStatus" Association="Self.FK_LoanSchedule_LoanScheduleStatus">
            <End Role="LoanScheduleStatus" EntitySet="LoanScheduleStatus" />
            <End Role="LoanSchedule" EntitySet="LoanSchedule" />
          </AssociationSet>
          <AssociationSet Name="FK_LoanScheduleFee_LoanSchedule" Association="Self.FK_LoanScheduleFee_LoanSchedule">
            <End Role="LoanSchedule" EntitySet="LoanSchedule" />
            <End Role="LoanScheduleFee" EntitySet="LoanScheduleFee" />
          </AssociationSet>
          <AssociationSet Name="FK_LoanScheduleFee_TransactionFee" Association="Self.FK_LoanScheduleFee_TransactionFee">
            <End Role="TransactionFee" EntitySet="TransactionFee" />
            <End Role="LoanScheduleFee" EntitySet="LoanScheduleFee" />
          </AssociationSet>
          <AssociationSet Name="FK_ManualDeduction_Profile" Association="Self.FK_ManualDeduction_Profile">
            <End Role="Profile" EntitySet="Profile" />
            <End Role="ManualDeduction" EntitySet="ManualDeduction" />
          </AssociationSet>
          <AssociationSet Name="FK_ManualDeduction_User" Association="Self.FK_ManualDeduction_User">
            <End Role="User" EntitySet="User" />
            <End Role="ManualDeduction" EntitySet="ManualDeduction" />
          </AssociationSet>
          <AssociationSet Name="FK_NextOfKin_Profile" Association="Self.FK_NextOfKin_Profile">
            <End Role="Profile" EntitySet="Profile" />
            <End Role="NextOfKin" EntitySet="NextOfKin" />
          </AssociationSet>
          <AssociationSet Name="FK_Notification_NotificationType" Association="Self.FK_Notification_NotificationType">
            <End Role="NotificationType" EntitySet="NotificationType" />
            <End Role="Notification" EntitySet="Notification" />
          </AssociationSet>
          <AssociationSet Name="FK_PreLoanRequest_LoanRequestStatus" Association="Self.FK_PreLoanRequest_LoanRequestStatus">
            <End Role="LoanRequestStatus" EntitySet="LoanRequestStatus" />
            <End Role="PreLoanRequest" EntitySet="PreLoanRequest" />
          </AssociationSet>
          <AssociationSet Name="FK_PreLoanRequest_Profile" Association="Self.FK_PreLoanRequest_Profile">
            <End Role="Profile" EntitySet="Profile" />
            <End Role="PreLoanRequest" EntitySet="PreLoanRequest" />
          </AssociationSet>
          <AssociationSet Name="FK_PreLoanRequest_TermType" Association="Self.FK_PreLoanRequest_TermType">
            <End Role="TermType" EntitySet="TermType" />
            <End Role="PreLoanRequest" EntitySet="PreLoanRequest" />
          </AssociationSet>
          <AssociationSet Name="FK_Profile_Country" Association="Self.FK_Profile_Country">
            <End Role="Country" EntitySet="Country" />
            <End Role="Profile" EntitySet="Profile" />
          </AssociationSet>
          <AssociationSet Name="FK_Profile_EmploymentStatus" Association="Self.FK_Profile_EmploymentStatus">
            <End Role="EmploymentStatus" EntitySet="EmploymentStatus" />
            <End Role="Profile" EntitySet="Profile" />
          </AssociationSet>
          <AssociationSet Name="FK_Profile_Ethnicity" Association="Self.FK_Profile_Ethnicity">
            <End Role="Ethnicity" EntitySet="Ethnicity" />
            <End Role="Profile" EntitySet="Profile" />
          </AssociationSet>
          <AssociationSet Name="FK_Profile_Gender" Association="Self.FK_Profile_Gender">
            <End Role="Gender" EntitySet="Gender" />
            <End Role="Profile" EntitySet="Profile" />
          </AssociationSet>
          <AssociationSet Name="FK_Profile_IdentificationType" Association="Self.FK_Profile_IdentificationType">
            <End Role="IdentificationType" EntitySet="IdentificationType" />
            <End Role="Profile" EntitySet="Profile" />
          </AssociationSet>
          <AssociationSet Name="FK_Profile_ProfileStatus" Association="Self.FK_Profile_ProfileStatus">
            <End Role="ProfileStatus" EntitySet="ProfileStatus" />
            <End Role="Profile" EntitySet="Profile" />
          </AssociationSet>
          <AssociationSet Name="FK_Profile_SourceOfIncome" Association="Self.FK_Profile_SourceOfIncome">
            <End Role="SourceOfIncome" EntitySet="SourceOfIncome" />
            <End Role="Profile" EntitySet="Profile" />
          </AssociationSet>
          <AssociationSet Name="FK_ProfileAddress_AddressType" Association="Self.FK_ProfileAddress_AddressType">
            <End Role="AddressType" EntitySet="AddressType" />
            <End Role="ProfileAddress" EntitySet="ProfileAddress" />
          </AssociationSet>
          <AssociationSet Name="FK_ProfileAddress_Country" Association="Self.FK_ProfileAddress_Country">
            <End Role="Country" EntitySet="Country" />
            <End Role="ProfileAddress" EntitySet="ProfileAddress" />
          </AssociationSet>
          <AssociationSet Name="FK_ProfileAddress_Profile" Association="Self.FK_ProfileAddress_Profile">
            <End Role="Profile" EntitySet="Profile" />
            <End Role="ProfileAddress" EntitySet="ProfileAddress" />
          </AssociationSet>
          <AssociationSet Name="FK_ProfileAddress_Province" Association="Self.FK_ProfileAddress_Province">
            <End Role="Province" EntitySet="Province" />
            <End Role="ProfileAddress" EntitySet="ProfileAddress" />
          </AssociationSet>
          <AssociationSet Name="FK_ProfileApproval_Profile" Association="Self.FK_ProfileApproval_Profile">
            <End Role="Profile" EntitySet="Profile" />
            <End Role="ProfileApproval" EntitySet="ProfileApproval" />
          </AssociationSet>
          <AssociationSet Name="FK_ProfileApproval_ProfileStatusId" Association="Self.FK_ProfileApproval_ProfileStatusId">
            <End Role="ProfileStatus" EntitySet="ProfileStatus" />
            <End Role="ProfileApproval" EntitySet="ProfileApproval" />
          </AssociationSet>
          <AssociationSet Name="FK_ProfileApproval_User" Association="Self.FK_ProfileApproval_User">
            <End Role="User" EntitySet="User" />
            <End Role="ProfileApproval" EntitySet="ProfileApproval" />
          </AssociationSet>
          <AssociationSet Name="FK_ProfileCreditRatingScore_Borrower" Association="Self.FK_ProfileCreditRatingScore_Borrower">
            <End Role="Profile" EntitySet="Profile" />
            <End Role="ProfileCreditRatingScore" EntitySet="ProfileCreditRatingScore" />
          </AssociationSet>
          <AssociationSet Name="FK_ProfileCreditRatingScore_CrediBureauRobotScore" Association="Self.FK_ProfileCreditRatingScore_CrediBureauRobotScore">
            <End Role="RobotScore" EntitySet="RobotScore" />
            <End Role="ProfileCreditRatingScore" EntitySet="ProfileCreditRatingScore" />
          </AssociationSet>
          <AssociationSet Name="FK_ProfileCreditRatingScore_LoanRequestOffer" Association="Self.FK_ProfileCreditRatingScore_LoanRequestOffer">
            <End Role="LoanRequestOffer" EntitySet="LoanRequestOffer" />
            <End Role="ProfileCreditRatingScore" EntitySet="ProfileCreditRatingScore" />
          </AssociationSet>
          <AssociationSet Name="FK_ProfileCreditRatingScore_Profile" Association="Self.FK_ProfileCreditRatingScore_Profile">
            <End Role="Profile" EntitySet="Profile" />
            <End Role="ProfileCreditRatingScore" EntitySet="ProfileCreditRatingScore" />
          </AssociationSet>
          <AssociationSet Name="FK_ProfileCreditRatingScore_RobotScore" Association="Self.FK_ProfileCreditRatingScore_RobotScore">
            <End Role="RobotScore" EntitySet="RobotScore" />
            <End Role="ProfileCreditRatingScore" EntitySet="ProfileCreditRatingScore" />
          </AssociationSet>
          <AssociationSet Name="FK_ProfileDocument_DocumentType" Association="Self.FK_ProfileDocument_DocumentType">
            <End Role="DocumentType" EntitySet="DocumentType" />
            <End Role="ProfileDocument" EntitySet="ProfileDocument" />
          </AssociationSet>
          <AssociationSet Name="FK_ProfileDocument_FileData" Association="Self.FK_ProfileDocument_FileData">
            <End Role="FileData" EntitySet="FileData" />
            <End Role="ProfileDocument" EntitySet="ProfileDocument" />
          </AssociationSet>
          <AssociationSet Name="FK_ProfileDocument_Profile" Association="Self.FK_ProfileDocument_Profile">
            <End Role="Profile" EntitySet="Profile" />
            <End Role="ProfileDocument" EntitySet="ProfileDocument" />
          </AssociationSet>
          <AssociationSet Name="FK_ProfileSuspension_Profile" Association="Self.FK_ProfileSuspension_Profile">
            <End Role="Profile" EntitySet="Profile" />
            <End Role="ProfileSuspension" EntitySet="ProfileSuspension" />
          </AssociationSet>
          <AssociationSet Name="FK_ProfileSuspension_User" Association="Self.FK_ProfileSuspension_User">
            <End Role="User" EntitySet="User" />
            <End Role="ProfileSuspension" EntitySet="ProfileSuspension" />
          </AssociationSet>
          <AssociationSet Name="FK_TaxInformation_Country" Association="Self.FK_TaxInformation_Country">
            <End Role="Country" EntitySet="Country" />
            <End Role="TaxInformation" EntitySet="TaxInformation" />
          </AssociationSet>
          <AssociationSet Name="FK_TaxInformation_Profile" Association="Self.FK_TaxInformation_Profile">
            <End Role="Profile" EntitySet="Profile" />
            <End Role="TaxInformation" EntitySet="TaxInformation" />
          </AssociationSet>
          <AssociationSet Name="FK_TaxInformation_TaxIdentificationType" Association="Self.FK_TaxInformation_TaxIdentificationType">
            <End Role="TaxIdentificationType" EntitySet="TaxIdentificationType" />
            <End Role="TaxInformation" EntitySet="TaxInformation" />
          </AssociationSet>
          <AssociationSet Name="FK_Transaction_Loan" Association="Self.FK_Transaction_Loan">
            <End Role="Loan" EntitySet="Loan" />
            <End Role="Transaction" EntitySet="Transaction" />
          </AssociationSet>
          <AssociationSet Name="FK_Transaction_LoanRequest" Association="Self.FK_Transaction_LoanRequest">
            <End Role="LoanRequest" EntitySet="LoanRequest" />
            <End Role="Transaction" EntitySet="Transaction" />
          </AssociationSet>
          <AssociationSet Name="FK_Transaction_Profile" Association="Self.FK_Transaction_Profile">
            <End Role="Profile" EntitySet="Profile" />
            <End Role="Transaction" EntitySet="Transaction" />
          </AssociationSet>
          <AssociationSet Name="FK_Transaction_ProfileType" Association="Self.FK_Transaction_ProfileType">
            <End Role="ProfileType" EntitySet="ProfileType" />
            <End Role="Transaction" EntitySet="Transaction" />
          </AssociationSet>
          <AssociationSet Name="FK_Transaction_Repayment" Association="Self.FK_Transaction_Repayment">
            <End Role="LoanRepayment" EntitySet="LoanRepayment" />
            <End Role="Transaction" EntitySet="Transaction" />
          </AssociationSet>
          <AssociationSet Name="FK_Transaction_TransactionStatus" Association="Self.FK_Transaction_TransactionStatus">
            <End Role="TransactionStatus" EntitySet="TransactionStatus" />
            <End Role="Transaction" EntitySet="Transaction" />
          </AssociationSet>
          <AssociationSet Name="FK_Transaction_TransactionType" Association="Self.FK_Transaction_TransactionType">
            <End Role="TransactionType" EntitySet="TransactionType" />
            <End Role="Transaction" EntitySet="Transaction" />
          </AssociationSet>
          <AssociationSet Name="FK_TransactionFee_FeeType" Association="Self.FK_TransactionFee_FeeType">
            <End Role="FeeType" EntitySet="FeeType" />
            <End Role="TransactionFee" EntitySet="TransactionFee" />
          </AssociationSet>
          <AssociationSet Name="FK_TransactionFee_Transaction" Association="Self.FK_TransactionFee_Transaction">
            <End Role="Transaction" EntitySet="Transaction" />
            <End Role="TransactionFee" EntitySet="TransactionFee" />
          </AssociationSet>
          <AssociationSet Name="FK_User_Profile" Association="Self.FK_User_Profile">
            <End Role="Profile" EntitySet="Profile" />
            <End Role="User" EntitySet="User" />
          </AssociationSet>
          <AssociationSet Name="FK_User_UserRole" Association="Self.FK_User_UserRole">
            <End Role="UserRole" EntitySet="UserRole" />
            <End Role="User" EntitySet="User" />
          </AssociationSet>
        </EntityContainer>
      </Schema></edmx:StorageModels>
    <!-- CSDL content -->
    <edmx:ConceptualModels>
      <Schema Namespace="BuddyFinance.Model" Alias="Self" annotation:UseStrongSpatialTypes="false" xmlns:annotation="http://schemas.microsoft.com/ado/2009/02/edm/annotation" xmlns:customannotation="http://schemas.microsoft.com/ado/2013/11/edm/customannotation" xmlns="http://schemas.microsoft.com/ado/2009/11/edm">
        <EntityType Name="ActivityLog">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="Int32" Nullable="false" annotation:StoreGeneratedPattern="Identity" />
          <Property Name="Type" Type="String" MaxLength="200" FixedLength="false" Unicode="true" Nullable="false" />
          <Property Name="TimeStamp" Type="DateTime" Nullable="false" Precision="3" />
          <Property Name="Description" Type="String" MaxLength="Max" FixedLength="false" Unicode="true" Nullable="false" />
          <Property Name="UserId" Type="Int32" />
          <Property Name="IpAddress" Type="String" MaxLength="200" FixedLength="false" Unicode="true" Nullable="false" />
          <Property Name="UserAgent" Type="String" MaxLength="200" FixedLength="false" Unicode="true" Nullable="false" />
          <NavigationProperty Name="User" Relationship="Self.FK_ActivityLog_User" FromRole="ActivityLog" ToRole="User" />
        </EntityType>
        <EntityType Name="AddressType">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="Int32" Nullable="false" annotation:StoreGeneratedPattern="Identity" />
          <Property Name="Description" Type="String" MaxLength="150" FixedLength="false" Unicode="true" Nullable="false" />
          <NavigationProperty Name="ProfileAddresses" Relationship="BuddyFinance.Model.FK_ProfileAddress_AddressType" FromRole="AddressType" ToRole="ProfileAddress" />
        </EntityType>
        <EntityType Name="AuthenticationCode">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="Int32" Nullable="false" annotation:StoreGeneratedPattern="Identity" />
          <Property Name="Code" Type="String" MaxLength="Max" FixedLength="false" Unicode="true" Nullable="false" />
          <Property Name="Number" Type="String" MaxLength="150" FixedLength="false" Unicode="true" />
          <Property Name="Type" Type="String" MaxLength="50" FixedLength="false" Unicode="false" />
          <Property Name="IsValid" Type="Boolean" Nullable="false" />
        </EntityType>
        <EntityType Name="BankingDetail">
          <Key>
            <PropertyRef Name="ProfileId" />
          </Key>
          <Property Name="ProfileId" Type="Int32" Nullable="false" />
          <Property Name="BankName" Type="String" MaxLength="50" FixedLength="false" Unicode="true" />
          <Property Name="AccountType" Type="String" MaxLength="50" FixedLength="false" Unicode="true" />
          <Property Name="BranchName" Type="String" MaxLength="50" FixedLength="false" Unicode="true" />
          <Property Name="BranchCode" Type="String" MaxLength="50" FixedLength="false" Unicode="true" />
          <Property Name="AccountName" Type="String" MaxLength="50" FixedLength="false" Unicode="true" />
          <Property Name="AccountNumber" Type="String" MaxLength="50" FixedLength="false" Unicode="true" />
          <NavigationProperty Name="Profile" Relationship="BuddyFinance.Model.FK_BankingDetail_Profile" FromRole="BankingDetail" ToRole="Profile" />
        </EntityType>
        <EntityType Name="CashDeposit">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="Int32" Nullable="false" annotation:StoreGeneratedPattern="Identity" />
          <Property Name="ProfileId" Type="Int32" Nullable="false" />
          <Property Name="Amount" Type="Double" Nullable="false" />
          <Property Name="Date" Type="DateTime" Nullable="false" Precision="3" />
          <Property Name="Comment" Type="String" MaxLength="Max" FixedLength="false" Unicode="true" />
          <Property Name="UserId" Type="Int32" Nullable="false" />
          <NavigationProperty Name="User" Relationship="Self.FK_CashDeposit_User" FromRole="CashDeposit" ToRole="User" />
          <NavigationProperty Name="Profile" Relationship="BuddyFinance.Model.FK_CashDeposit_Profile" FromRole="CashDeposit" ToRole="Profile" />
        </EntityType>
        <EntityType Name="CashWithdrawal">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="Int32" Nullable="false" annotation:StoreGeneratedPattern="Identity" />
          <Property Name="ProfileId" Type="Int32" Nullable="false" />
          <Property Name="Amount" Type="Double" Nullable="false" />
          <Property Name="Date" Type="DateTime" Nullable="false" Precision="3" />
          <Property Name="Comment" Type="String" MaxLength="Max" FixedLength="false" Unicode="true" />
          <Property Name="StatusId" Type="Int32" Nullable="false" />
          <Property Name="ReviewerId" Type="Int32" />
          <Property Name="ReviewDate" Type="DateTime" Precision="3" />
          <NavigationProperty Name="CashWithdrawalStatus" Relationship="Self.FK_CashWithdrawal_Status" FromRole="CashWithdrawal" ToRole="CashWithdrawalStatus" />
          <NavigationProperty Name="User" Relationship="Self.FK_CashWithdrawal_User" FromRole="CashWithdrawal" ToRole="User" />
          <NavigationProperty Name="Profile" Relationship="BuddyFinance.Model.FK_CashWithdrawal_Profile" FromRole="CashWithdrawal" ToRole="Profile" />
        </EntityType>
        <EntityType Name="CashWithdrawalStatus">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="Int32" Nullable="false" annotation:StoreGeneratedPattern="Identity" />
          <Property Name="Description" Type="String" MaxLength="90" FixedLength="false" Unicode="true" Nullable="false" />
          <NavigationProperty Name="CashWithdrawals" Relationship="Self.FK_CashWithdrawal_Status" FromRole="CashWithdrawalStatus" ToRole="CashWithdrawal" />
        </EntityType>
        <EntityType Name="Country">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="Int32" Nullable="false" annotation:StoreGeneratedPattern="Identity" />
          <Property Name="CountryCode" Type="String" MaxLength="20" FixedLength="false" Unicode="true" Nullable="false" />
          <Property Name="CountryName" Type="String" MaxLength="70" FixedLength="false" Unicode="true" Nullable="false" />
          <NavigationProperty Name="TaxInformations" Relationship="Self.FK_TaxInformation_Country" FromRole="Country" ToRole="TaxInformation" />
          <NavigationProperty Name="Profiles" Relationship="BuddyFinance.Model.FK_Profile_Country" FromRole="Country" ToRole="Profile" />
          <NavigationProperty Name="ProfileAddresses" Relationship="BuddyFinance.Model.FK_ProfileAddress_Country" FromRole="Country" ToRole="ProfileAddress" />
        </EntityType>
        <EntityType Name="DocumentType">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="Int32" Nullable="false" annotation:StoreGeneratedPattern="Identity" />
          <Property Name="Description" Type="String" MaxLength="70" FixedLength="false" Unicode="true" Nullable="false" />
          <NavigationProperty Name="FicaComplianceDocuments" Relationship="Self.FK_FicaComplianceDocuments_DocumentType" FromRole="DocumentType" ToRole="FicaComplianceDocuments" />
          <NavigationProperty Name="ProfileDocuments" Relationship="Self.FK_ProfileDocument_DocumentType" FromRole="DocumentType" ToRole="ProfileDocument" />
        </EntityType>
        <EntityType Name="EmploymentDetail">
          <Key>
            <PropertyRef Name="ProfileId" />
          </Key>
          <Property Name="ProfileId" Type="Int32" Nullable="false" />
          <Property Name="EmploymentTypeId" Type="Int32" />
          <Property Name="EmployerName" Type="String" MaxLength="50" FixedLength="false" Unicode="true" />
          <Property Name="EmployerContactNumber" Type="String" MaxLength="50" FixedLength="false" Unicode="true" />
          <Property Name="EmploymentStartDate" Type="DateTime" Precision="3" />
          <Property Name="EmploymentEndDate" Type="DateTime" Precision="3" />
          <Property Name="GrossMonthlyIncome" Type="Double" />
          <Property Name="NetMonthlyIncome" Type="Double" />
          <Property Name="EmployerNumber" Type="String" MaxLength="50" FixedLength="false" Unicode="true" />
          <Property Name="SalaryDay" Type="Int32" />
          <NavigationProperty Name="EmploymentType" Relationship="Self.FK_EmploymentDetail_EmploymentType" FromRole="EmploymentDetail" ToRole="EmploymentType" />
          <NavigationProperty Name="Profile" Relationship="BuddyFinance.Model.FK_EmploymentDetail_ProfileId" FromRole="EmploymentDetail" ToRole="Profile" />
          <Property Name="BillingDay" Type="Int32" />
        </EntityType>
        <EntityType Name="EmploymentStatus">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="Int32" Nullable="false" annotation:StoreGeneratedPattern="Identity" />
          <Property Name="Description" Type="String" MaxLength="50" FixedLength="false" Unicode="true" Nullable="false" />
          <NavigationProperty Name="Profiles" Relationship="BuddyFinance.Model.FK_Profile_EmploymentStatus" FromRole="EmploymentStatus" ToRole="Profile" />
        </EntityType>
        <EntityType Name="EmploymentType">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="Int32" Nullable="false" annotation:StoreGeneratedPattern="Identity" />
          <Property Name="Description" Type="String" MaxLength="70" FixedLength="false" Unicode="true" Nullable="false" />
          <NavigationProperty Name="EmploymentDetails" Relationship="Self.FK_EmploymentDetail_EmploymentType" FromRole="EmploymentType" ToRole="EmploymentDetail" />
        </EntityType>
        <EntityType Name="Ethnicity">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="Int32" Nullable="false" annotation:StoreGeneratedPattern="Identity" />
          <Property Name="Description" Type="String" MaxLength="70" FixedLength="false" Unicode="true" Nullable="false" />
          <NavigationProperty Name="Profiles" Relationship="BuddyFinance.Model.FK_Profile_Ethnicity" FromRole="Ethnicity" ToRole="Profile" />
        </EntityType>
        <EntityType Name="FicaCompliance">
          <Key>
            <PropertyRef Name="ProfileId" />
          </Key>
          <Property Name="ProfileId" Type="Int32" Nullable="false" />
          <Property Name="FicaStatusId" Type="Int32" Nullable="false" />
          <Property Name="VerificationDate" Type="DateTime" Precision="3" />
          <NavigationProperty Name="FicaStatus" Relationship="Self.FK_FicaCompliance_FicaStatus" FromRole="FicaCompliance" ToRole="FicaStatus" />
          <NavigationProperty Name="FicaComplianceDocuments" Relationship="Self.FK_FicaComplianceDocuments_FicaCompliance" FromRole="FicaCompliance" ToRole="FicaComplianceDocuments" />
          <NavigationProperty Name="Profile" Relationship="BuddyFinance.Model.FK_FicaCompliance_Profile" FromRole="FicaCompliance" ToRole="Profile" />
        </EntityType>
        <EntityType Name="FicaComplianceDocument">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="Int32" Nullable="false" annotation:StoreGeneratedPattern="Identity" />
          <Property Name="FicaComplianceId" Type="Int32" Nullable="false" />
          <Property Name="DocumentTypeId" Type="Int32" Nullable="false" />
          <Property Name="FileId" Type="Int32" Nullable="false" />
          <NavigationProperty Name="DocumentType" Relationship="Self.FK_FicaComplianceDocuments_DocumentType" FromRole="FicaComplianceDocuments" ToRole="DocumentType" />
          <NavigationProperty Name="FicaCompliance" Relationship="Self.FK_FicaComplianceDocuments_FicaCompliance" FromRole="FicaComplianceDocuments" ToRole="FicaCompliance" />
          <NavigationProperty Name="FileData" Relationship="Self.FK_FicaComplianceDocuments_FileData" FromRole="FicaComplianceDocuments" ToRole="FileData" />
        </EntityType>
        <EntityType Name="FicaStatus">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="Int32" Nullable="false" annotation:StoreGeneratedPattern="Identity" />
          <Property Name="Description" Type="String" MaxLength="50" FixedLength="false" Unicode="true" Nullable="false" />
          <NavigationProperty Name="FicaCompliances" Relationship="Self.FK_FicaCompliance_FicaStatus" FromRole="FicaStatus" ToRole="FicaCompliance" />
        </EntityType>
        <EntityType Name="FileData">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="Int32" Nullable="false" annotation:StoreGeneratedPattern="Identity" />
          <Property Name="FileName" Type="String" MaxLength="150" FixedLength="false" Unicode="true" Nullable="false" />
          <Property Name="Contents" Type="Binary" MaxLength="Max" FixedLength="false" Nullable="false" />
          <Property Name="Size" Type="Int32" Nullable="false" />
          <Property Name="ContentType" Type="String" MaxLength="Max" FixedLength="false" Unicode="true" Nullable="false" />
          <Property Name="FileUrl" Type="String" MaxLength="Max" FixedLength="false" Unicode="true" />
          <NavigationProperty Name="FicaComplianceDocuments" Relationship="Self.FK_FicaComplianceDocuments_FileData" FromRole="FileData" ToRole="FicaComplianceDocuments" />
          <NavigationProperty Name="ProfileDocuments" Relationship="Self.FK_ProfileDocument_FileData" FromRole="FileData" ToRole="ProfileDocument" />
        </EntityType>
        <EntityType Name="Gender">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="Int32" Nullable="false" annotation:StoreGeneratedPattern="Identity" />
          <Property Name="Description" Type="String" MaxLength="50" FixedLength="false" Unicode="true" />
          <NavigationProperty Name="Profiles" Relationship="BuddyFinance.Model.FK_Profile_Gender" FromRole="Gender" ToRole="Profile" />
        </EntityType>
        <EntityType Name="GlobalSetup">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="Guid" Nullable="false" />
          <Property Name="InterestType" Type="Int32" Nullable="false" />
          <Property Name="ExpenseFactor" Type="Decimal" Precision="18" Scale="4" Nullable="false" />
          <Property Name="ServiceFee" Type="Decimal" Precision="18" Scale="4" Nullable="false" />
          <Property Name="TransUnionSecurityCode" Type="String" MaxLength="50" FixedLength="false" Unicode="true" Nullable="false" />
          <Property Name="TransUnionSubscriberCode" Type="String" MaxLength="50" FixedLength="false" Unicode="true" Nullable="false" />
        </EntityType>
        <EntityType Name="IdentificationType">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="Int32" Nullable="false" annotation:StoreGeneratedPattern="Identity" />
          <Property Name="Description" Type="String" MaxLength="50" FixedLength="false" Unicode="true" />
          <NavigationProperty Name="Profiles" Relationship="BuddyFinance.Model.FK_Profile_IdentificationType" FromRole="IdentificationType" ToRole="Profile" />
        </EntityType>
        <EntityType Name="LoanEarningBracket">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="Int32" Nullable="false" annotation:StoreGeneratedPattern="Identity" />
          <Property Name="MinAmount" Type="Double" Nullable="false" />
          <Property Name="MaxAmount" Type="Double" Nullable="false" />
          <Property Name="QualifyingAmount" Type="Double" Nullable="false" />
        </EntityType>
        <EntityType Name="LoanPayout">
          <Key>
            <PropertyRef Name="LoanId" />
          </Key>
          <Property Name="LoanId" Type="Int32" Nullable="false" />
          <Property Name="PayoutDate" Type="DateTime" Nullable="false" Precision="3" />
          <Property Name="PayoutAmount" Type="Double" Nullable="false" />
          <NavigationProperty Name="Loan" Relationship="BuddyFinance.Model.FK_LoanPayout_Loan" FromRole="LoanPayout" ToRole="Loan" />
        </EntityType>
        <EntityType Name="LoanRepayment">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="Int32" Nullable="false" annotation:StoreGeneratedPattern="Identity" />
          <Property Name="LoanId" Type="Int32" Nullable="false" />
          <Property Name="PaymentAmount" Type="Double" Nullable="false" />
          <Property Name="PaymentDate" Type="DateTime" Nullable="false" Precision="3" />
          <Property Name="PaymentMethod" Type="String" MaxLength="50" FixedLength="false" Unicode="true" Nullable="false" />
          <Property Name="LoanScheduleId" Type="Int32" />
          <Property Name="LoanRepaymentStatusId" Type="Int32" Nullable="false" />
          <NavigationProperty Name="LoanRepaymentStatus" Relationship="Self.FK_LoanRepayment_LoanRepaymentStatus" FromRole="LoanRepayment" ToRole="LoanRepaymentStatus" />
          <NavigationProperty Name="LoanSchedule" Relationship="Self.FK_LoanRepayment_LoanSchedule" FromRole="LoanRepayment" ToRole="LoanSchedule" />
          <NavigationProperty Name="Transactions" Relationship="Self.FK_Transaction_Repayment" FromRole="LoanRepayment" ToRole="Transaction" />
          <NavigationProperty Name="Loan" Relationship="BuddyFinance.Model.FK_LoanRepayment_Loan" FromRole="LoanRepayment" ToRole="Loan" />
        </EntityType>
        <EntityType Name="LoanRepaymentStatus">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="Int32" Nullable="false" annotation:StoreGeneratedPattern="Identity" />
          <Property Name="Description" Type="String" MaxLength="90" FixedLength="false" Unicode="true" Nullable="false" />
          <NavigationProperty Name="LoanRepayments" Relationship="Self.FK_LoanRepayment_LoanRepaymentStatus" FromRole="LoanRepaymentStatus" ToRole="LoanRepayment" />
        </EntityType>
        <EntityType Name="LoanRequestScore">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="Int32" Nullable="false" />
        </EntityType>
        <EntityType Name="LoanRequestStatus">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="Int32" Nullable="false" annotation:StoreGeneratedPattern="Identity" />
          <Property Name="Description" Type="String" MaxLength="70" FixedLength="false" Unicode="true" Nullable="false" />
          <NavigationProperty Name="PreLoanRequests" Relationship="Self.FK_PreLoanRequest_LoanRequestStatus" FromRole="LoanRequestStatus" ToRole="PreLoanRequest" />
          <NavigationProperty Name="LoanRequests" Relationship="BuddyFinance.Model.FK_LoanRequest_LoanRequestStatus" FromRole="LoanRequestStatus" ToRole="LoanRequest" />
        </EntityType>
        <EntityType Name="LoanSchedule">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="Int32" Nullable="false" annotation:StoreGeneratedPattern="Identity" />
          <Property Name="Description" Type="String" MaxLength="70" FixedLength="false" Unicode="true" Nullable="false" />
          <Property Name="Amount" Type="Double" Nullable="false" />
          <Property Name="ExpectedPayDate" Type="DateTime" Nullable="false" Precision="3" />
          <Property Name="StatusId" Type="Int32" Nullable="false" />
          <Property Name="LoanId" Type="Int32" Nullable="false" />
          <NavigationProperty Name="LoanRepayments" Relationship="Self.FK_LoanRepayment_LoanSchedule" FromRole="LoanSchedule" ToRole="LoanRepayment" />
          <NavigationProperty Name="LoanScheduleStatus" Relationship="Self.FK_LoanSchedule_LoanScheduleStatus" FromRole="LoanSchedule" ToRole="LoanScheduleStatus" />
          <NavigationProperty Name="LoanScheduleFee" Relationship="Self.FK_LoanScheduleFee_LoanSchedule" FromRole="LoanSchedule" ToRole="LoanScheduleFee" />
          <NavigationProperty Name="Loan" Relationship="BuddyFinance.Model.FK_LoanSchedule_Loan" FromRole="LoanSchedule" ToRole="Loan" />
        </EntityType>
        <EntityType Name="LoanScheduleFee">
          <Key>
            <PropertyRef Name="LoanScheduleId" />
          </Key>
          <Property Name="LoanScheduleId" Type="Int32" Nullable="false" />
          <Property Name="BillDate" Type="DateTime" Nullable="false" Precision="3" />
          <Property Name="TransactionFeeId" Type="Int32" Nullable="false" />
          <NavigationProperty Name="LoanSchedule" Relationship="Self.FK_LoanScheduleFee_LoanSchedule" FromRole="LoanScheduleFee" ToRole="LoanSchedule" />
          <NavigationProperty Name="TransactionFee" Relationship="Self.FK_LoanScheduleFee_TransactionFee" FromRole="LoanScheduleFee" ToRole="TransactionFee" />
        </EntityType>
        <EntityType Name="LoanScheduleStatus">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="Int32" Nullable="false" annotation:StoreGeneratedPattern="Identity" />
          <Property Name="Description" Type="String" MaxLength="70" FixedLength="false" Unicode="true" Nullable="false" />
          <NavigationProperty Name="LoanSchedules" Relationship="Self.FK_LoanSchedule_LoanScheduleStatus" FromRole="LoanScheduleStatus" ToRole="LoanSchedule" />
        </EntityType>
        <EntityType Name="LoanStatus">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="Int32" Nullable="false" annotation:StoreGeneratedPattern="Identity" />
          <Property Name="Description" Type="String" MaxLength="70" FixedLength="false" Unicode="true" Nullable="false" />
          <NavigationProperty Name="Loans" Relationship="BuddyFinance.Model.FK_Loan_LoanStatus" FromRole="LoanStatus" ToRole="Loan" />
        </EntityType>
        <EntityType Name="LoanTermBracket">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="Int32" Nullable="false" annotation:StoreGeneratedPattern="Identity" />
          <Property Name="MinAmount" Type="Double" Nullable="false" />
          <Property Name="MaxAmount" Type="Double" Nullable="false" />
          <Property Name="Duration" Type="Int32" Nullable="false" />
        </EntityType>
        <EntityType Name="ManualDeduction">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="Int32" Nullable="false" annotation:StoreGeneratedPattern="Identity" />
          <Property Name="Amount" Type="Double" Nullable="false" />
          <Property Name="Description" Type="String" MaxLength="Max" FixedLength="false" Unicode="true" />
          <Property Name="DeductionDate" Type="DateTime" Nullable="false" Precision="3" />
          <Property Name="ProfileId" Type="Int32" Nullable="false" />
          <Property Name="UserId" Type="Int32" Nullable="false" />
          <NavigationProperty Name="User" Relationship="Self.FK_ManualDeduction_User" FromRole="ManualDeduction" ToRole="User" />
          <NavigationProperty Name="Profile" Relationship="BuddyFinance.Model.FK_ManualDeduction_Profile" FromRole="ManualDeduction" ToRole="Profile" />
        </EntityType>
        <EntityType Name="NextOfKin">
          <Key>
            <PropertyRef Name="ProfileId" />
          </Key>
          <Property Name="ProfileId" Type="Int32" Nullable="false" />
          <Property Name="Name" Type="String" MaxLength="100" FixedLength="false" Unicode="true" />
          <Property Name="RelationshipType" Type="String" MaxLength="100" FixedLength="false" Unicode="true" />
          <Property Name="ContactNumber" Type="String" MaxLength="20" FixedLength="false" Unicode="true" />
          <Property Name="Income" Type="Double" />
          <NavigationProperty Name="Profile" Relationship="BuddyFinance.Model.FK_NextOfKin_Profile" FromRole="NextOfKin" ToRole="Profile" />
        </EntityType>
        <EntityType Name="Notification">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="Int32" Nullable="false" annotation:StoreGeneratedPattern="Identity" />
          <Property Name="Recipient" Type="String" MaxLength="100" FixedLength="false" Unicode="true" Nullable="false" />
          <Property Name="Message" Type="String" MaxLength="Max" FixedLength="false" Unicode="true" Nullable="false" />
          <Property Name="Status" Type="String" MaxLength="100" FixedLength="false" Unicode="true" Nullable="false" />
          <Property Name="NotificationTypeId" Type="Int32" Nullable="false" />
          <Property Name="DateSent" Type="DateTime" Nullable="false" Precision="3" />
          <NavigationProperty Name="NotificationType" Relationship="Self.FK_Notification_NotificationType" FromRole="Notification" ToRole="NotificationType" />
        </EntityType>
        <EntityType Name="NotificationType">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="Int32" Nullable="false" annotation:StoreGeneratedPattern="Identity" />
          <Property Name="Description" Type="String" MaxLength="50" FixedLength="false" Unicode="true" Nullable="false" />
          <NavigationProperty Name="Notifications" Relationship="Self.FK_Notification_NotificationType" FromRole="NotificationType" ToRole="Notification" />
        </EntityType>
        <EntityType Name="OfferStatus">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="Int32" Nullable="false" annotation:StoreGeneratedPattern="Identity" />
          <Property Name="Description" Type="String" MaxLength="50" FixedLength="false" Unicode="true" Nullable="false" />
          <NavigationProperty Name="LoanRequestOffers" Relationship="BuddyFinance.Model.FK_LoanRequestOffer_OfferStaus" FromRole="OfferStatus" ToRole="LoanRequestOffer" />
        </EntityType>
        <EntityType Name="PreLoanRequest">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="Int32" Nullable="false" annotation:StoreGeneratedPattern="Identity" />
          <Property Name="RequestedDate" Type="DateTime" Nullable="false" Precision="3" />
          <Property Name="BorrowerId" Type="Int32" Nullable="false" />
          <Property Name="Amount" Type="Double" Nullable="false" />
          <Property Name="Term" Type="Int32" Nullable="false" />
          <Property Name="TermTypeId" Type="Int32" Nullable="false" />
          <Property Name="FirstPaymentDate" Type="DateTime" Nullable="false" Precision="3" />
          <Property Name="ReferenceNumber" Type="String" MaxLength="50" FixedLength="false" Unicode="true" />
          <Property Name="LoanRequestStatusId" Type="Int32" Nullable="false" />
          <NavigationProperty Name="LoanRequestStatus" Relationship="Self.FK_PreLoanRequest_LoanRequestStatus" FromRole="PreLoanRequest" ToRole="LoanRequestStatus" />
          <NavigationProperty Name="TermType" Relationship="Self.FK_PreLoanRequest_TermType" FromRole="PreLoanRequest" ToRole="TermType" />
          <NavigationProperty Name="Profile" Relationship="BuddyFinance.Model.FK_PreLoanRequest_Profile" FromRole="PreLoanRequest" ToRole="Profile" />
        </EntityType>
        <EntityType Name="ProfileApproval">
          <Key>
            <PropertyRef Name="ProfileId" />
          </Key>
          <Property Name="ProfileId" Type="Int32" Nullable="false" />
          <Property Name="ProfileStatusId" Type="Int32" Nullable="false" />
          <Property Name="RejectReason" Type="String" MaxLength="2000" FixedLength="false" Unicode="true" />
          <Property Name="ReviewDate" Type="DateTime" Nullable="false" Precision="3" />
          <Property Name="ReviewerId" Type="Int32" Nullable="false" />
          <NavigationProperty Name="ProfileStatus" Relationship="Self.FK_ProfileApproval_ProfileStatusId" FromRole="ProfileApproval" ToRole="ProfileStatus" />
          <NavigationProperty Name="User" Relationship="Self.FK_ProfileApproval_User" FromRole="ProfileApproval" ToRole="User" />
          <NavigationProperty Name="Profile" Relationship="BuddyFinance.Model.FK_ProfileApproval_Profile" FromRole="ProfileApproval" ToRole="Profile" />
        </EntityType>
        <EntityType Name="ProfileCreditRatingScore">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="Int32" Nullable="false" annotation:StoreGeneratedPattern="Identity" />
          <Property Name="ProfileId" Type="Int32" Nullable="false" />
          <Property Name="BorrowerId" Type="Int32" />
          <Property Name="LoanRequestOfferId" Type="Int32" />
          <Property Name="CreditBureauScore" Type="Int32" Nullable="false" />
          <Property Name="DerivedScore" Type="Int32" Nullable="false" />
          <Property Name="CreditBureauRobotScoreId" Type="Int32" Nullable="false" />
          <Property Name="DerivedRobotScoreId" Type="Int32" Nullable="false" />
          <Property Name="ScoreDate" Type="DateTime" Nullable="false" Precision="3" />
          <Property Name="Firstname" Type="String" MaxLength="50" FixedLength="false" Unicode="true" Nullable="false" />
          <Property Name="Lastname" Type="String" MaxLength="50" FixedLength="false" Unicode="true" Nullable="false" />
          <NavigationProperty Name="CreditBureauRobotScore" Relationship="Self.FK_ProfileCreditRatingScore_CrediBureauRobotScore" FromRole="ProfileCreditRatingScore" ToRole="RobotScore" />
          <NavigationProperty Name="DerivedScoreRobotScore" Relationship="Self.FK_ProfileCreditRatingScore_RobotScore" FromRole="ProfileCreditRatingScore" ToRole="RobotScore" />
          <NavigationProperty Name="LoanRequestOffer" Relationship="BuddyFinance.Model.FK_ProfileCreditRatingScore_LoanRequestOffer" FromRole="ProfileCreditRatingScore" ToRole="LoanRequestOffer" />
          <NavigationProperty Name="Profile" Relationship="BuddyFinance.Model.FK_ProfileCreditRatingScore_Borrower" FromRole="ProfileCreditRatingScore" ToRole="Profile" />
          <NavigationProperty Name="Profile1" Relationship="BuddyFinance.Model.FK_ProfileCreditRatingScore_Profile" FromRole="ProfileCreditRatingScore" ToRole="Profile" />
          </EntityType>
        <EntityType Name="ProfileDocument">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="Int32" Nullable="false" annotation:StoreGeneratedPattern="Identity" />
          <Property Name="FileId" Type="Int32" Nullable="false" />
          <Property Name="UploadedDate" Type="DateTime" Nullable="false" Precision="3" />
          <Property Name="DocumentTypeId" Type="Int32" Nullable="false" />
          <Property Name="ProfileId" Type="Int32" Nullable="false" />
          <Property Name="IsDeleted" Type="Boolean" Nullable="false" />
          <NavigationProperty Name="DocumentType" Relationship="Self.FK_ProfileDocument_DocumentType" FromRole="ProfileDocument" ToRole="DocumentType" />
          <NavigationProperty Name="FileData" Relationship="Self.FK_ProfileDocument_FileData" FromRole="ProfileDocument" ToRole="FileData" />
          <NavigationProperty Name="Profile" Relationship="BuddyFinance.Model.FK_ProfileDocument_Profile" FromRole="ProfileDocument" ToRole="Profile" />
        </EntityType>
        <EntityType Name="ProfileStatus">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="Int32" Nullable="false" annotation:StoreGeneratedPattern="Identity" />
          <Property Name="Description" Type="String" MaxLength="50" FixedLength="false" Unicode="true" />
          <NavigationProperty Name="ProfileApprovals" Relationship="Self.FK_ProfileApproval_ProfileStatusId" FromRole="ProfileStatus" ToRole="ProfileApproval" />
          <NavigationProperty Name="Borrowers" Relationship="BuddyFinance.Model.FK_Borrower_ProfileStatus" FromRole="ProfileStatus" ToRole="Borrower" />
          <NavigationProperty Name="Lenders" Relationship="BuddyFinance.Model.FK_Lender_ProfileStatus" FromRole="ProfileStatus" ToRole="Lender" />
          <NavigationProperty Name="Profiles" Relationship="BuddyFinance.Model.FK_Profile_ProfileStatus" FromRole="ProfileStatus" ToRole="Profile" />
        </EntityType>
        <EntityType Name="ProfileSuspension">
          <Key>
            <PropertyRef Name="ProfileId" />
          </Key>
          <Property Name="ProfileId" Type="Int32" Nullable="false" />
          <Property Name="StartDate" Type="DateTime" Nullable="false" Precision="3" />
          <Property Name="EndDate" Type="DateTime" Precision="3" />
          <Property Name="Reason" Type="String" MaxLength="Max" FixedLength="false" Unicode="true" />
          <Property Name="ReviewerId" Type="Int32" Nullable="false" />
          <NavigationProperty Name="User" Relationship="Self.FK_ProfileSuspension_User" FromRole="ProfileSuspension" ToRole="User" />
          <NavigationProperty Name="Profile" Relationship="BuddyFinance.Model.FK_ProfileSuspension_Profile" FromRole="ProfileSuspension" ToRole="Profile" />
        </EntityType>
        <EntityType Name="ProfileType">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="Int32" Nullable="false" annotation:StoreGeneratedPattern="Identity" />
          <Property Name="Description" Type="String" MaxLength="50" FixedLength="false" Unicode="true" Nullable="false" />
          <NavigationProperty Name="Transactions" Relationship="BuddyFinance.Model.FK_Transaction_ProfileType" FromRole="ProfileType" ToRole="Transaction" />
          <NavigationProperty Name="Borrowers" Relationship="BuddyFinance.Model.FK_Borrower_ProfileType" FromRole="ProfileType" ToRole="Borrower" />
          <NavigationProperty Name="Lenders" Relationship="BuddyFinance.Model.FK_Lender_ProfileType" FromRole="ProfileType" ToRole="Lender" />
        </EntityType>
        <EntityType Name="Province">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="Int32" Nullable="false" annotation:StoreGeneratedPattern="Identity" />
          <Property Name="Description" Type="String" MaxLength="150" FixedLength="false" Unicode="false" Nullable="false" />
          <NavigationProperty Name="ProfileAddresses" Relationship="BuddyFinance.Model.FK_ProfileAddress_Province" FromRole="Province" ToRole="ProfileAddress" />
        </EntityType>
        <EntityType Name="RequestLog">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="Int32" Nullable="false" annotation:StoreGeneratedPattern="Identity" />
          <Property Name="RequestType" Type="String" MaxLength="50" FixedLength="false" Unicode="true" Nullable="false" />
          <Property Name="Timestamp" Type="DateTime" Nullable="false" Precision="3" />
          <Property Name="RequestXML" Type="String" MaxLength="Max" FixedLength="false" Unicode="true" Nullable="false" />
          <Property Name="ResponseCode" Type="String" MaxLength="50" FixedLength="false" Unicode="true" />
          <Property Name="ResponseMessage" Type="String" MaxLength="500" FixedLength="false" Unicode="true" />
          <Property Name="ResponseXML" Type="String" MaxLength="Max" FixedLength="false" Unicode="true" />
        </EntityType>
        <EntityType Name="RobotScore">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="Int32" Nullable="false" annotation:StoreGeneratedPattern="Identity" />
          <Property Name="MinScore" Type="Int32" Nullable="false" />
          <Property Name="MaxScore" Type="Int32" Nullable="false" />
          <Property Name="RobotColor" Type="String" MaxLength="50" FixedLength="false" Unicode="true" Nullable="false" />
          <Property Name="Description" Type="String" MaxLength="250" FixedLength="false" Unicode="true" Nullable="false" />
          <NavigationProperty Name="ProfileCreditRatingScores" Relationship="Self.FK_ProfileCreditRatingScore_CrediBureauRobotScore" FromRole="RobotScore" ToRole="ProfileCreditRatingScore" />
          <NavigationProperty Name="ProfileCreditRatingScores1" Relationship="Self.FK_ProfileCreditRatingScore_RobotScore" FromRole="RobotScore" ToRole="ProfileCreditRatingScore" />
        </EntityType>
        <EntityType Name="SourceOfFund">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="Int32" Nullable="false" annotation:StoreGeneratedPattern="Identity" />
          <Property Name="Description" Type="String" MaxLength="50" FixedLength="false" Unicode="true" Nullable="false" />
        </EntityType>
        <EntityType Name="SourceOfIncome">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="Int32" Nullable="false" annotation:StoreGeneratedPattern="Identity" />
          <Property Name="Description" Type="String" MaxLength="50" FixedLength="false" Unicode="true" Nullable="false" />
          <NavigationProperty Name="Profiles" Relationship="BuddyFinance.Model.FK_Profile_SourceOfIncome" FromRole="SourceOfIncome" ToRole="Profile" />
        </EntityType>
        <EntityType Name="TaxIdentificationType">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="Int32" Nullable="false" annotation:StoreGeneratedPattern="Identity" />
          <Property Name="Description" Type="String" MaxLength="50" FixedLength="false" Unicode="true" />
          <NavigationProperty Name="TaxInformations" Relationship="Self.FK_TaxInformation_TaxIdentificationType" FromRole="TaxIdentificationType" ToRole="TaxInformation" />
        </EntityType>
        <EntityType Name="TaxInformation">
          <Key>
            <PropertyRef Name="ProfileId" />
          </Key>
          <Property Name="ProfileId" Type="Int32" Nullable="false" />
          <Property Name="TaxIdentificationTypeId" Type="Int32" Nullable="false" />
          <Property Name="TaxNumber" Type="String" MaxLength="50" FixedLength="false" Unicode="true" Nullable="false" />
          <Property Name="TaxCountryId" Type="Int32" Nullable="false" />
          <NavigationProperty Name="Country" Relationship="Self.FK_TaxInformation_Country" FromRole="TaxInformation" ToRole="Country" />
          <NavigationProperty Name="TaxIdentificationType" Relationship="Self.FK_TaxInformation_TaxIdentificationType" FromRole="TaxInformation" ToRole="TaxIdentificationType" />
          <NavigationProperty Name="Profile" Relationship="BuddyFinance.Model.FK_TaxInformation_Profile" FromRole="TaxInformation" ToRole="Profile" />
        </EntityType>
        <EntityType Name="TermType">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="Int32" Nullable="false" annotation:StoreGeneratedPattern="Identity" />
          <Property Name="Description" Type="String" MaxLength="70" FixedLength="false" Unicode="true" Nullable="false" />
          <NavigationProperty Name="PreLoanRequests" Relationship="Self.FK_PreLoanRequest_TermType" FromRole="TermType" ToRole="PreLoanRequest" />
          <NavigationProperty Name="Loans" Relationship="BuddyFinance.Model.FK_Loan_TermType" FromRole="TermType" ToRole="Loan" />
          <NavigationProperty Name="LoanOffers" Relationship="BuddyFinance.Model.FK_LoanOffer_TermType" FromRole="TermType" ToRole="LoanOffer" />
          <NavigationProperty Name="LoanRequests" Relationship="BuddyFinance.Model.FK_LoanRequest_TermType" FromRole="TermType" ToRole="LoanRequest" />
        </EntityType>
        <EntityType Name="Transaction">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="Int32" Nullable="false" annotation:StoreGeneratedPattern="Identity" />
          <Property Name="ProfileId" Type="Int32" Nullable="false" />
          <Property Name="TransactionDate" Type="DateTime" Nullable="false" Precision="3" />
          <Property Name="Description" Type="String" MaxLength="250" FixedLength="false" Unicode="true" Nullable="false" />
          <Property Name="Reference" Type="String" MaxLength="70" FixedLength="false" Unicode="true" Nullable="false" />
          <Property Name="TransactionTypeId" Type="Int32" Nullable="false" />
          <Property Name="Amount" Type="Double" Nullable="false" />
          <Property Name="TransactionStatusId" Type="Int32" Nullable="false" />
          <Property Name="LoanId" Type="Int32" />
          <Property Name="LoanRequestId" Type="Int32" />
          <Property Name="LoanRepaymentId" Type="Int32" />
          <NavigationProperty Name="LoanRepayment" Relationship="Self.FK_Transaction_Repayment" FromRole="Transaction" ToRole="LoanRepayment" />
          <NavigationProperty Name="TransactionStatus" Relationship="Self.FK_Transaction_TransactionStatus" FromRole="Transaction" ToRole="TransactionStatus" />
          <NavigationProperty Name="TransactionType" Relationship="Self.FK_Transaction_TransactionType" FromRole="Transaction" ToRole="TransactionType" />
          <NavigationProperty Name="TransactionFees" Relationship="Self.FK_TransactionFee_Transaction" FromRole="Transaction" ToRole="TransactionFee" />
          <NavigationProperty Name="Loan" Relationship="BuddyFinance.Model.FK_Transaction_Loan" FromRole="Transaction" ToRole="Loan" />
          <Property Name="ProfileTypeId" Type="Int32" Nullable="false" />
          <NavigationProperty Name="ProfileType" Relationship="BuddyFinance.Model.FK_Transaction_ProfileType" FromRole="Transaction" ToRole="ProfileType" />
          <NavigationProperty Name="LoanRequest" Relationship="BuddyFinance.Model.FK_Transaction_LoanRequest" FromRole="Transaction" ToRole="LoanRequest" />
          <NavigationProperty Name="Profile" Relationship="BuddyFinance.Model.FK_Transaction_Profile" FromRole="Transaction" ToRole="Profile" />
        </EntityType>
        <EntityType Name="TransactionFee">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="Int32" Nullable="false" annotation:StoreGeneratedPattern="Identity" />
          <Property Name="TransactionId" Type="Int32" Nullable="false" />
          <Property Name="FeeTypeId" Type="Int32" Nullable="false" />
          <Property Name="FeeAmount" Type="Double" Nullable="false" />
          <NavigationProperty Name="LoanScheduleFees" Relationship="Self.FK_LoanScheduleFee_TransactionFee" FromRole="TransactionFee" ToRole="LoanScheduleFee" />
          <NavigationProperty Name="Transaction" Relationship="Self.FK_TransactionFee_Transaction" FromRole="TransactionFee" ToRole="Transaction" />
          <NavigationProperty Name="FeeType" Relationship="BuddyFinance.Model.FK_TransactionFee_FeeType" FromRole="TransactionFee" ToRole="FeeType" />
        </EntityType>
        <EntityType Name="TransactionStatus">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="Int32" Nullable="false" annotation:StoreGeneratedPattern="Identity" />
          <Property Name="Description" Type="String" MaxLength="90" FixedLength="false" Unicode="true" Nullable="false" />
          <NavigationProperty Name="Transactions" Relationship="Self.FK_Transaction_TransactionStatus" FromRole="TransactionStatus" ToRole="Transaction" />
        </EntityType>
        <EntityType Name="TransactionType">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="Int32" Nullable="false" annotation:StoreGeneratedPattern="Identity" />
          <Property Name="Description" Type="String" MaxLength="70" FixedLength="false" Unicode="true" Nullable="false" />
          <NavigationProperty Name="Transactions" Relationship="Self.FK_Transaction_TransactionType" FromRole="TransactionType" ToRole="Transaction" />
        </EntityType>
        <EntityType Name="User">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="Int32" Nullable="false" annotation:StoreGeneratedPattern="Identity" />
          <Property Name="UserName" Type="String" MaxLength="250" FixedLength="false" Unicode="true" Nullable="false" />
          <Property Name="Name" Type="String" MaxLength="150" FixedLength="false" Unicode="true" />
          <Property Name="Surname" Type="String" MaxLength="150" FixedLength="false" Unicode="true" />
          <Property Name="MobileNumber" Type="String" MaxLength="150" FixedLength="false" Unicode="true" />
          <Property Name="Password" Type="String" MaxLength="Max" FixedLength="false" Unicode="true" Nullable="false" />
          <Property Name="PasswordHash" Type="String" MaxLength="Max" FixedLength="false" Unicode="true" Nullable="false" />
          <Property Name="SignUpDate" Type="DateTime" Precision="3" />
          <Property Name="LastLoginDate" Type="DateTime" Precision="3" />
          <Property Name="MustChangePassword" Type="Boolean" Nullable="false" />
          <Property Name="ProfileId" Type="Int32" Nullable="false" />
          <Property Name="RoleId" Type="Int32" Nullable="false" />
          <Property Name="IsActive" Type="Boolean" Nullable="false" />
          <Property Name="AccountVerified" Type="Boolean" Nullable="false" />
          <NavigationProperty Name="ActivityLogs" Relationship="Self.FK_ActivityLog_User" FromRole="User" ToRole="ActivityLog" />
          <NavigationProperty Name="CashDeposits" Relationship="Self.FK_CashDeposit_User" FromRole="User" ToRole="CashDeposit" />
          <NavigationProperty Name="CashWithdrawals" Relationship="Self.FK_CashWithdrawal_User" FromRole="User" ToRole="CashWithdrawal" />
          <NavigationProperty Name="ManualDeductions" Relationship="Self.FK_ManualDeduction_User" FromRole="User" ToRole="ManualDeduction" />
          <NavigationProperty Name="ProfileApprovals" Relationship="Self.FK_ProfileApproval_User" FromRole="User" ToRole="ProfileApproval" />
          <NavigationProperty Name="ProfileSuspensions" Relationship="Self.FK_ProfileSuspension_User" FromRole="User" ToRole="ProfileSuspension" />
          <NavigationProperty Name="UserRole" Relationship="Self.FK_User_UserRole" FromRole="User" ToRole="UserRole" />
          <NavigationProperty Name="Profile" Relationship="BuddyFinance.Model.FK_User_Profile" FromRole="User" ToRole="Profile" />
        </EntityType>
        <EntityType Name="UserRole">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="Int32" Nullable="false" annotation:StoreGeneratedPattern="Identity" />
          <Property Name="Name" Type="String" MaxLength="90" FixedLength="false" Unicode="true" Nullable="false" />
          <NavigationProperty Name="Users" Relationship="Self.FK_User_UserRole" FromRole="UserRole" ToRole="User" />
        </EntityType>
        <Association Name="FK_ActivityLog_User">
          <End Role="User" Type="Self.User" Multiplicity="0..1" />
          <End Role="ActivityLog" Type="Self.ActivityLog" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="User">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="ActivityLog">
              <PropertyRef Name="UserId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_CashDeposit_User">
          <End Role="User" Type="Self.User" Multiplicity="1" />
          <End Role="CashDeposit" Type="Self.CashDeposit" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="User">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="CashDeposit">
              <PropertyRef Name="UserId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_CashWithdrawal_Status">
          <End Role="CashWithdrawalStatus" Type="BuddyFinance.Model.CashWithdrawalStatus" Multiplicity="1" />
          <End Role="CashWithdrawal" Type="Self.CashWithdrawal" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="CashWithdrawalStatus">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="CashWithdrawal">
              <PropertyRef Name="StatusId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_CashWithdrawal_User">
          <End Role="User" Type="Self.User" Multiplicity="0..1" />
          <End Role="CashWithdrawal" Type="Self.CashWithdrawal" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="User">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="CashWithdrawal">
              <PropertyRef Name="ReviewerId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_TaxInformation_Country">
          <End Role="Country" Type="Self.Country" Multiplicity="1" />
          <End Role="TaxInformation" Type="Self.TaxInformation" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="Country">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="TaxInformation">
              <PropertyRef Name="TaxCountryId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_FicaComplianceDocuments_DocumentType">
          <End Role="DocumentType" Type="Self.DocumentType" Multiplicity="1" />
          <End Role="FicaComplianceDocuments" Type="Self.FicaComplianceDocument" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="DocumentType">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="FicaComplianceDocuments">
              <PropertyRef Name="DocumentTypeId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_ProfileDocument_DocumentType">
          <End Role="DocumentType" Type="Self.DocumentType" Multiplicity="1" />
          <End Role="ProfileDocument" Type="Self.ProfileDocument" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="DocumentType">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="ProfileDocument">
              <PropertyRef Name="DocumentTypeId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_EmploymentDetail_EmploymentType">
          <End Role="EmploymentType" Type="Self.EmploymentType" Multiplicity="0..1" />
          <End Role="EmploymentDetail" Type="Self.EmploymentDetail" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="EmploymentType">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="EmploymentDetail">
              <PropertyRef Name="EmploymentTypeId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_FicaCompliance_FicaStatus">
          <End Role="FicaStatus" Type="BuddyFinance.Model.FicaStatus" Multiplicity="1" />
          <End Role="FicaCompliance" Type="Self.FicaCompliance" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="FicaStatus">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="FicaCompliance">
              <PropertyRef Name="FicaStatusId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_FicaComplianceDocuments_FicaCompliance">
          <End Role="FicaCompliance" Type="Self.FicaCompliance" Multiplicity="1" />
          <End Role="FicaComplianceDocuments" Type="Self.FicaComplianceDocument" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="FicaCompliance">
              <PropertyRef Name="ProfileId" />
            </Principal>
            <Dependent Role="FicaComplianceDocuments">
              <PropertyRef Name="FicaComplianceId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_FicaComplianceDocuments_FileData">
          <End Role="FileData" Type="Self.FileData" Multiplicity="1" />
          <End Role="FicaComplianceDocuments" Type="Self.FicaComplianceDocument" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="FileData">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="FicaComplianceDocuments">
              <PropertyRef Name="FileId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_ProfileDocument_FileData">
          <End Role="FileData" Type="Self.FileData" Multiplicity="1" />
          <End Role="ProfileDocument" Type="Self.ProfileDocument" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="FileData">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="ProfileDocument">
              <PropertyRef Name="FileId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_LoanRepayment_LoanRepaymentStatus">
          <End Role="LoanRepaymentStatus" Type="BuddyFinance.Model.LoanRepaymentStatus" Multiplicity="1" />
          <End Role="LoanRepayment" Type="Self.LoanRepayment" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="LoanRepaymentStatus">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="LoanRepayment">
              <PropertyRef Name="LoanRepaymentStatusId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_LoanRepayment_LoanSchedule">
          <End Role="LoanSchedule" Type="Self.LoanSchedule" Multiplicity="0..1" />
          <End Role="LoanRepayment" Type="Self.LoanRepayment" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="LoanSchedule">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="LoanRepayment">
              <PropertyRef Name="LoanScheduleId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_Transaction_Repayment">
          <End Role="LoanRepayment" Type="Self.LoanRepayment" Multiplicity="0..1" />
          <End Role="Transaction" Type="Self.Transaction" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="LoanRepayment">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="Transaction">
              <PropertyRef Name="LoanRepaymentId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_PreLoanRequest_LoanRequestStatus">
          <End Role="LoanRequestStatus" Type="BuddyFinance.Model.LoanRequestStatus" Multiplicity="1" />
          <End Role="PreLoanRequest" Type="Self.PreLoanRequest" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="LoanRequestStatus">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="PreLoanRequest">
              <PropertyRef Name="LoanRequestStatusId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_LoanSchedule_LoanScheduleStatus">
          <End Role="LoanScheduleStatus" Type="BuddyFinance.Model.LoanScheduleStatus" Multiplicity="1" />
          <End Role="LoanSchedule" Type="Self.LoanSchedule" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="LoanScheduleStatus">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="LoanSchedule">
              <PropertyRef Name="StatusId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_LoanScheduleFee_LoanSchedule">
          <End Role="LoanSchedule" Type="Self.LoanSchedule" Multiplicity="1" />
          <End Role="LoanScheduleFee" Type="Self.LoanScheduleFee" Multiplicity="0..1" />
          <ReferentialConstraint>
            <Principal Role="LoanSchedule">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="LoanScheduleFee">
              <PropertyRef Name="LoanScheduleId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_LoanScheduleFee_TransactionFee">
          <End Role="TransactionFee" Type="Self.TransactionFee" Multiplicity="1" />
          <End Role="LoanScheduleFee" Type="Self.LoanScheduleFee" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="TransactionFee">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="LoanScheduleFee">
              <PropertyRef Name="TransactionFeeId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_ManualDeduction_User">
          <End Role="User" Type="Self.User" Multiplicity="1" />
          <End Role="ManualDeduction" Type="Self.ManualDeduction" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="User">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="ManualDeduction">
              <PropertyRef Name="UserId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_Notification_NotificationType">
          <End Role="NotificationType" Type="Self.NotificationType" Multiplicity="1" />
          <End Role="Notification" Type="Self.Notification" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="NotificationType">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="Notification">
              <PropertyRef Name="NotificationTypeId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_PreLoanRequest_TermType">
          <End Role="TermType" Type="Self.TermType" Multiplicity="1" />
          <End Role="PreLoanRequest" Type="Self.PreLoanRequest" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="TermType">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="PreLoanRequest">
              <PropertyRef Name="TermTypeId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_ProfileApproval_ProfileStatusId">
          <End Role="ProfileStatus" Type="BuddyFinance.Model.ProfileStatus" Multiplicity="1" />
          <End Role="ProfileApproval" Type="Self.ProfileApproval" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="ProfileStatus">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="ProfileApproval">
              <PropertyRef Name="ProfileStatusId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_ProfileApproval_User">
          <End Role="User" Type="Self.User" Multiplicity="1" />
          <End Role="ProfileApproval" Type="Self.ProfileApproval" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="User">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="ProfileApproval">
              <PropertyRef Name="ReviewerId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_ProfileCreditRatingScore_CrediBureauRobotScore">
          <End Role="RobotScore" Type="Self.RobotScore" Multiplicity="1" />
          <End Role="ProfileCreditRatingScore" Type="Self.ProfileCreditRatingScore" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="RobotScore">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="ProfileCreditRatingScore">
              <PropertyRef Name="CreditBureauRobotScoreId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_ProfileCreditRatingScore_RobotScore">
          <End Role="RobotScore" Type="Self.RobotScore" Multiplicity="1" />
          <End Role="ProfileCreditRatingScore" Type="Self.ProfileCreditRatingScore" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="RobotScore">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="ProfileCreditRatingScore">
              <PropertyRef Name="DerivedRobotScoreId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_ProfileSuspension_User">
          <End Role="User" Type="Self.User" Multiplicity="1" />
          <End Role="ProfileSuspension" Type="Self.ProfileSuspension" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="User">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="ProfileSuspension">
              <PropertyRef Name="ReviewerId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_TaxInformation_TaxIdentificationType">
          <End Role="TaxIdentificationType" Type="Self.TaxIdentificationType" Multiplicity="1" />
          <End Role="TaxInformation" Type="Self.TaxInformation" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="TaxIdentificationType">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="TaxInformation">
              <PropertyRef Name="TaxIdentificationTypeId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_Transaction_TransactionStatus">
          <End Role="TransactionStatus" Type="BuddyFinance.Model.TransactionStatus" Multiplicity="1" />
          <End Role="Transaction" Type="Self.Transaction" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="TransactionStatus">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="Transaction">
              <PropertyRef Name="TransactionStatusId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_Transaction_TransactionType">
          <End Role="TransactionType" Type="Self.TransactionType" Multiplicity="1" />
          <End Role="Transaction" Type="Self.Transaction" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="TransactionType">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="Transaction">
              <PropertyRef Name="TransactionTypeId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_TransactionFee_Transaction">
          <End Role="Transaction" Type="Self.Transaction" Multiplicity="1" />
          <End Role="TransactionFee" Type="Self.TransactionFee" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="Transaction">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="TransactionFee">
              <PropertyRef Name="TransactionId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_User_UserRole">
          <End Role="UserRole" Type="Self.UserRole" Multiplicity="1" />
          <End Role="User" Type="Self.User" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="UserRole">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="User">
              <PropertyRef Name="RoleId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <EntityContainer Name="BuddyFinanceDBEntities" annotation:LazyLoadingEnabled="true">
          <EntitySet Name="ActivityLogs" EntityType="Self.ActivityLog" />
          <EntitySet Name="AddressTypes" EntityType="Self.AddressType" />
          <EntitySet Name="AuthenticationCodes" EntityType="Self.AuthenticationCode" />
          <EntitySet Name="BankingDetails" EntityType="Self.BankingDetail" />
          <EntitySet Name="CashDeposits" EntityType="Self.CashDeposit" />
          <EntitySet Name="CashWithdrawals" EntityType="Self.CashWithdrawal" />
          <EntitySet Name="CashWithdrawalStatus1" EntityType="BuddyFinance.Model.CashWithdrawalStatus" />
          <EntitySet Name="Countries" EntityType="Self.Country" />
          <EntitySet Name="DocumentTypes" EntityType="Self.DocumentType" />
          <EntitySet Name="EmploymentDetails" EntityType="Self.EmploymentDetail" />
          <EntitySet Name="EmploymentStatus1" EntityType="BuddyFinance.Model.EmploymentStatus" />
          <EntitySet Name="EmploymentTypes" EntityType="Self.EmploymentType" />
          <EntitySet Name="Ethnicities" EntityType="Self.Ethnicity" />
          <EntitySet Name="FicaCompliances" EntityType="Self.FicaCompliance" />
          <EntitySet Name="FicaComplianceDocuments" EntityType="Self.FicaComplianceDocument" />
          <EntitySet Name="FicaStatus1" EntityType="BuddyFinance.Model.FicaStatus" />
          <EntitySet Name="FileDatas" EntityType="Self.FileData" />
          <EntitySet Name="Genders" EntityType="Self.Gender" />
          <EntitySet Name="GlobalSetups" EntityType="Self.GlobalSetup" />
          <EntitySet Name="IdentificationTypes" EntityType="Self.IdentificationType" />
          <EntitySet Name="LoanEarningBrackets" EntityType="Self.LoanEarningBracket" />
          <EntitySet Name="LoanPayouts" EntityType="Self.LoanPayout" />
          <EntitySet Name="LoanRepayments" EntityType="Self.LoanRepayment" />
          <EntitySet Name="LoanRepaymentStatus1" EntityType="BuddyFinance.Model.LoanRepaymentStatus" />
          <EntitySet Name="LoanRequestScores" EntityType="Self.LoanRequestScore" />
          <EntitySet Name="LoanRequestStatus1" EntityType="BuddyFinance.Model.LoanRequestStatus" />
          <EntitySet Name="LoanSchedules" EntityType="Self.LoanSchedule" />
          <EntitySet Name="LoanScheduleFees" EntityType="Self.LoanScheduleFee" />
          <EntitySet Name="LoanScheduleStatus1" EntityType="BuddyFinance.Model.LoanScheduleStatus" />
          <EntitySet Name="LoanStatus1" EntityType="BuddyFinance.Model.LoanStatus" />
          <EntitySet Name="LoanTermBrackets" EntityType="Self.LoanTermBracket" />
          <EntitySet Name="ManualDeductions" EntityType="Self.ManualDeduction" />
          <EntitySet Name="NextOfKins" EntityType="Self.NextOfKin" />
          <EntitySet Name="Notifications" EntityType="Self.Notification" />
          <EntitySet Name="NotificationTypes" EntityType="Self.NotificationType" />
          <EntitySet Name="OfferStatus1" EntityType="BuddyFinance.Model.OfferStatus" />
          <EntitySet Name="PreLoanRequests" EntityType="Self.PreLoanRequest" />
          <EntitySet Name="ProfileApprovals" EntityType="Self.ProfileApproval" />
          <EntitySet Name="ProfileCreditRatingScores" EntityType="Self.ProfileCreditRatingScore" />
          <EntitySet Name="ProfileDocuments" EntityType="Self.ProfileDocument" />
          <EntitySet Name="ProfileStatus1" EntityType="BuddyFinance.Model.ProfileStatus" />
          <EntitySet Name="ProfileSuspensions" EntityType="Self.ProfileSuspension" />
          <EntitySet Name="ProfileTypes" EntityType="Self.ProfileType" />
          <EntitySet Name="Provinces" EntityType="Self.Province" />
          <EntitySet Name="RequestLogs" EntityType="Self.RequestLog" />
          <EntitySet Name="RobotScores" EntityType="Self.RobotScore" />
          <EntitySet Name="SourceOfFunds" EntityType="Self.SourceOfFund" />
          <EntitySet Name="SourceOfIncomes" EntityType="Self.SourceOfIncome" />
          <EntitySet Name="TaxIdentificationTypes" EntityType="Self.TaxIdentificationType" />
          <EntitySet Name="TaxInformations" EntityType="Self.TaxInformation" />
          <EntitySet Name="TermTypes" EntityType="Self.TermType" />
          <EntitySet Name="Transactions" EntityType="Self.Transaction" />
          <EntitySet Name="TransactionFees" EntityType="Self.TransactionFee" />
          <EntitySet Name="TransactionStatus1" EntityType="BuddyFinance.Model.TransactionStatus" />
          <EntitySet Name="TransactionTypes" EntityType="Self.TransactionType" />
          <EntitySet Name="Users" EntityType="Self.User" />
          <EntitySet Name="UserRoles" EntityType="Self.UserRole" />
          <AssociationSet Name="FK_ActivityLog_User" Association="Self.FK_ActivityLog_User">
            <End Role="User" EntitySet="Users" />
            <End Role="ActivityLog" EntitySet="ActivityLogs" />
          </AssociationSet>
          <AssociationSet Name="FK_CashDeposit_User" Association="Self.FK_CashDeposit_User">
            <End Role="User" EntitySet="Users" />
            <End Role="CashDeposit" EntitySet="CashDeposits" />
          </AssociationSet>
          <AssociationSet Name="FK_CashWithdrawal_Status" Association="Self.FK_CashWithdrawal_Status">
            <End Role="CashWithdrawalStatus" EntitySet="CashWithdrawalStatus1" />
            <End Role="CashWithdrawal" EntitySet="CashWithdrawals" />
          </AssociationSet>
          <AssociationSet Name="FK_CashWithdrawal_User" Association="Self.FK_CashWithdrawal_User">
            <End Role="User" EntitySet="Users" />
            <End Role="CashWithdrawal" EntitySet="CashWithdrawals" />
          </AssociationSet>
          <AssociationSet Name="FK_TaxInformation_Country" Association="Self.FK_TaxInformation_Country">
            <End Role="Country" EntitySet="Countries" />
            <End Role="TaxInformation" EntitySet="TaxInformations" />
          </AssociationSet>
          <AssociationSet Name="FK_FicaComplianceDocuments_DocumentType" Association="Self.FK_FicaComplianceDocuments_DocumentType">
            <End Role="DocumentType" EntitySet="DocumentTypes" />
            <End Role="FicaComplianceDocuments" EntitySet="FicaComplianceDocuments" />
          </AssociationSet>
          <AssociationSet Name="FK_ProfileDocument_DocumentType" Association="Self.FK_ProfileDocument_DocumentType">
            <End Role="DocumentType" EntitySet="DocumentTypes" />
            <End Role="ProfileDocument" EntitySet="ProfileDocuments" />
          </AssociationSet>
          <AssociationSet Name="FK_EmploymentDetail_EmploymentType" Association="Self.FK_EmploymentDetail_EmploymentType">
            <End Role="EmploymentType" EntitySet="EmploymentTypes" />
            <End Role="EmploymentDetail" EntitySet="EmploymentDetails" />
          </AssociationSet>
          <AssociationSet Name="FK_FicaCompliance_FicaStatus" Association="Self.FK_FicaCompliance_FicaStatus">
            <End Role="FicaStatus" EntitySet="FicaStatus1" />
            <End Role="FicaCompliance" EntitySet="FicaCompliances" />
          </AssociationSet>
          <AssociationSet Name="FK_FicaComplianceDocuments_FicaCompliance" Association="Self.FK_FicaComplianceDocuments_FicaCompliance">
            <End Role="FicaCompliance" EntitySet="FicaCompliances" />
            <End Role="FicaComplianceDocuments" EntitySet="FicaComplianceDocuments" />
          </AssociationSet>
          <AssociationSet Name="FK_FicaComplianceDocuments_FileData" Association="Self.FK_FicaComplianceDocuments_FileData">
            <End Role="FileData" EntitySet="FileDatas" />
            <End Role="FicaComplianceDocuments" EntitySet="FicaComplianceDocuments" />
          </AssociationSet>
          <AssociationSet Name="FK_ProfileDocument_FileData" Association="Self.FK_ProfileDocument_FileData">
            <End Role="FileData" EntitySet="FileDatas" />
            <End Role="ProfileDocument" EntitySet="ProfileDocuments" />
          </AssociationSet>
          <AssociationSet Name="FK_LoanRepayment_LoanRepaymentStatus" Association="Self.FK_LoanRepayment_LoanRepaymentStatus">
            <End Role="LoanRepaymentStatus" EntitySet="LoanRepaymentStatus1" />
            <End Role="LoanRepayment" EntitySet="LoanRepayments" />
          </AssociationSet>
          <AssociationSet Name="FK_LoanRepayment_LoanSchedule" Association="Self.FK_LoanRepayment_LoanSchedule">
            <End Role="LoanSchedule" EntitySet="LoanSchedules" />
            <End Role="LoanRepayment" EntitySet="LoanRepayments" />
          </AssociationSet>
          <AssociationSet Name="FK_Transaction_Repayment" Association="Self.FK_Transaction_Repayment">
            <End Role="LoanRepayment" EntitySet="LoanRepayments" />
            <End Role="Transaction" EntitySet="Transactions" />
          </AssociationSet>
          <AssociationSet Name="FK_PreLoanRequest_LoanRequestStatus" Association="Self.FK_PreLoanRequest_LoanRequestStatus">
            <End Role="LoanRequestStatus" EntitySet="LoanRequestStatus1" />
            <End Role="PreLoanRequest" EntitySet="PreLoanRequests" />
          </AssociationSet>
          <AssociationSet Name="FK_LoanSchedule_LoanScheduleStatus" Association="Self.FK_LoanSchedule_LoanScheduleStatus">
            <End Role="LoanScheduleStatus" EntitySet="LoanScheduleStatus1" />
            <End Role="LoanSchedule" EntitySet="LoanSchedules" />
          </AssociationSet>
          <AssociationSet Name="FK_LoanScheduleFee_LoanSchedule" Association="Self.FK_LoanScheduleFee_LoanSchedule">
            <End Role="LoanSchedule" EntitySet="LoanSchedules" />
            <End Role="LoanScheduleFee" EntitySet="LoanScheduleFees" />
          </AssociationSet>
          <AssociationSet Name="FK_LoanScheduleFee_TransactionFee" Association="Self.FK_LoanScheduleFee_TransactionFee">
            <End Role="TransactionFee" EntitySet="TransactionFees" />
            <End Role="LoanScheduleFee" EntitySet="LoanScheduleFees" />
          </AssociationSet>
          <AssociationSet Name="FK_ManualDeduction_User" Association="Self.FK_ManualDeduction_User">
            <End Role="User" EntitySet="Users" />
            <End Role="ManualDeduction" EntitySet="ManualDeductions" />
          </AssociationSet>
          <AssociationSet Name="FK_Notification_NotificationType" Association="Self.FK_Notification_NotificationType">
            <End Role="NotificationType" EntitySet="NotificationTypes" />
            <End Role="Notification" EntitySet="Notifications" />
          </AssociationSet>
          <AssociationSet Name="FK_PreLoanRequest_TermType" Association="Self.FK_PreLoanRequest_TermType">
            <End Role="TermType" EntitySet="TermTypes" />
            <End Role="PreLoanRequest" EntitySet="PreLoanRequests" />
          </AssociationSet>
          <AssociationSet Name="FK_ProfileApproval_ProfileStatusId" Association="Self.FK_ProfileApproval_ProfileStatusId">
            <End Role="ProfileStatus" EntitySet="ProfileStatus1" />
            <End Role="ProfileApproval" EntitySet="ProfileApprovals" />
          </AssociationSet>
          <AssociationSet Name="FK_ProfileApproval_User" Association="Self.FK_ProfileApproval_User">
            <End Role="User" EntitySet="Users" />
            <End Role="ProfileApproval" EntitySet="ProfileApprovals" />
          </AssociationSet>
          <AssociationSet Name="FK_ProfileCreditRatingScore_CrediBureauRobotScore" Association="Self.FK_ProfileCreditRatingScore_CrediBureauRobotScore">
            <End Role="RobotScore" EntitySet="RobotScores" />
            <End Role="ProfileCreditRatingScore" EntitySet="ProfileCreditRatingScores" />
          </AssociationSet>
          <AssociationSet Name="FK_ProfileCreditRatingScore_RobotScore" Association="Self.FK_ProfileCreditRatingScore_RobotScore">
            <End Role="RobotScore" EntitySet="RobotScores" />
            <End Role="ProfileCreditRatingScore" EntitySet="ProfileCreditRatingScores" />
          </AssociationSet>
          <AssociationSet Name="FK_ProfileSuspension_User" Association="Self.FK_ProfileSuspension_User">
            <End Role="User" EntitySet="Users" />
            <End Role="ProfileSuspension" EntitySet="ProfileSuspensions" />
          </AssociationSet>
          <AssociationSet Name="FK_TaxInformation_TaxIdentificationType" Association="Self.FK_TaxInformation_TaxIdentificationType">
            <End Role="TaxIdentificationType" EntitySet="TaxIdentificationTypes" />
            <End Role="TaxInformation" EntitySet="TaxInformations" />
          </AssociationSet>
          <AssociationSet Name="FK_Transaction_TransactionStatus" Association="Self.FK_Transaction_TransactionStatus">
            <End Role="TransactionStatus" EntitySet="TransactionStatus1" />
            <End Role="Transaction" EntitySet="Transactions" />
          </AssociationSet>
          <AssociationSet Name="FK_Transaction_TransactionType" Association="Self.FK_Transaction_TransactionType">
            <End Role="TransactionType" EntitySet="TransactionTypes" />
            <End Role="Transaction" EntitySet="Transactions" />
          </AssociationSet>
          <AssociationSet Name="FK_TransactionFee_Transaction" Association="Self.FK_TransactionFee_Transaction">
            <End Role="Transaction" EntitySet="Transactions" />
            <End Role="TransactionFee" EntitySet="TransactionFees" />
          </AssociationSet>
          <AssociationSet Name="FK_User_UserRole" Association="Self.FK_User_UserRole">
            <End Role="UserRole" EntitySet="UserRoles" />
            <End Role="User" EntitySet="Users" />
          </AssociationSet>
          <FunctionImport Name="ProfileTransactions" ReturnType="Collection(BuddyFinance.Model.ProfileTransactions_Result)">
            <Parameter Name="profileId" Mode="In" Type="Int32" />
            <Parameter Name="startDate" Mode="In" Type="String" />
            <Parameter Name="endDate" Mode="In" Type="String" />
          </FunctionImport>
          <EntitySet Name="Loans" EntityType="BuddyFinance.Model.Loan" />
          <AssociationSet Name="FK_Loan_LoanStatus" Association="BuddyFinance.Model.FK_Loan_LoanStatus">
            <End Role="LoanStatus" EntitySet="LoanStatus1" />
            <End Role="Loan" EntitySet="Loans" />
          </AssociationSet>
          <AssociationSet Name="FK_Loan_TermType" Association="BuddyFinance.Model.FK_Loan_TermType">
            <End Role="TermType" EntitySet="TermTypes" />
            <End Role="Loan" EntitySet="Loans" />
          </AssociationSet>
          <AssociationSet Name="FK_LoanPayout_Loan" Association="BuddyFinance.Model.FK_LoanPayout_Loan">
            <End Role="Loan" EntitySet="Loans" />
            <End Role="LoanPayout" EntitySet="LoanPayouts" />
          </AssociationSet>
          <AssociationSet Name="FK_LoanRepayment_Loan" Association="BuddyFinance.Model.FK_LoanRepayment_Loan">
            <End Role="Loan" EntitySet="Loans" />
            <End Role="LoanRepayment" EntitySet="LoanRepayments" />
          </AssociationSet>
          <AssociationSet Name="FK_LoanSchedule_Loan" Association="BuddyFinance.Model.FK_LoanSchedule_Loan">
            <End Role="Loan" EntitySet="Loans" />
            <End Role="LoanSchedule" EntitySet="LoanSchedules" />
          </AssociationSet>
          <AssociationSet Name="FK_Transaction_Loan" Association="BuddyFinance.Model.FK_Transaction_Loan">
            <End Role="Loan" EntitySet="Loans" />
            <End Role="Transaction" EntitySet="Transactions" />
          </AssociationSet>
          <EntitySet Name="LoanRequestOffers" EntityType="BuddyFinance.Model.LoanRequestOffer" />
          <AssociationSet Name="FK_LoanRequestOffer_OfferStaus" Association="BuddyFinance.Model.FK_LoanRequestOffer_OfferStaus">
            <End Role="OfferStatus" EntitySet="OfferStatus1" />
            <End Role="LoanRequestOffer" EntitySet="LoanRequestOffers" />
          </AssociationSet>
          <AssociationSet Name="FK_ProfileCreditRatingScore_LoanRequestOffer" Association="BuddyFinance.Model.FK_ProfileCreditRatingScore_LoanRequestOffer">
            <End Role="LoanRequestOffer" EntitySet="LoanRequestOffers" />
            <End Role="ProfileCreditRatingScore" EntitySet="ProfileCreditRatingScores" />
          </AssociationSet>
          <EntitySet Name="FeeTypes" EntityType="BuddyFinance.Model.FeeType" />
          <AssociationSet Name="FK_TransactionFee_FeeType" Association="BuddyFinance.Model.FK_TransactionFee_FeeType">
            <End Role="FeeType" EntitySet="FeeTypes" />
            <End Role="TransactionFee" EntitySet="TransactionFees" />
          </AssociationSet>
          <AssociationSet Name="FK_Transaction_ProfileType" Association="BuddyFinance.Model.FK_Transaction_ProfileType">
            <End Role="ProfileType" EntitySet="ProfileTypes" />
            <End Role="Transaction" EntitySet="Transactions" />
          </AssociationSet>
          <EntitySet Name="LoanOffers" EntityType="BuddyFinance.Model.LoanOffer" />
          <EntitySet Name="LoanRequests" EntityType="BuddyFinance.Model.LoanRequest" />
          <AssociationSet Name="FK_Loan_LoanOffer" Association="BuddyFinance.Model.FK_Loan_LoanOffer">
            <End Role="LoanOffer" EntitySet="LoanOffers" />
            <End Role="Loan" EntitySet="Loans" />
          </AssociationSet>
          <AssociationSet Name="FK_Loan_LoanRequest" Association="BuddyFinance.Model.FK_Loan_LoanRequest">
            <End Role="LoanRequest" EntitySet="LoanRequests" />
            <End Role="Loan" EntitySet="Loans" />
          </AssociationSet>
          <AssociationSet Name="FK_LoanOffer_TermType" Association="BuddyFinance.Model.FK_LoanOffer_TermType">
            <End Role="TermType" EntitySet="TermTypes" />
            <End Role="LoanOffer" EntitySet="LoanOffers" />
          </AssociationSet>
          <AssociationSet Name="FK_LoanRequestOffer_LoanOffer" Association="BuddyFinance.Model.FK_LoanRequestOffer_LoanOffer">
            <End Role="LoanOffer" EntitySet="LoanOffers" />
            <End Role="LoanRequestOffer" EntitySet="LoanRequestOffers" />
          </AssociationSet>
          <AssociationSet Name="FK_LoanRequest_LoanRequestStatus" Association="BuddyFinance.Model.FK_LoanRequest_LoanRequestStatus">
            <End Role="LoanRequestStatus" EntitySet="LoanRequestStatus1" />
            <End Role="LoanRequest" EntitySet="LoanRequests" />
          </AssociationSet>
          <AssociationSet Name="FK_LoanRequest_TermType" Association="BuddyFinance.Model.FK_LoanRequest_TermType">
            <End Role="TermType" EntitySet="TermTypes" />
            <End Role="LoanRequest" EntitySet="LoanRequests" />
          </AssociationSet>
          <AssociationSet Name="FK_LoanRequestOffer_LoanRequest" Association="BuddyFinance.Model.FK_LoanRequestOffer_LoanRequest">
            <End Role="LoanRequest" EntitySet="LoanRequests" />
            <End Role="LoanRequestOffer" EntitySet="LoanRequestOffers" />
          </AssociationSet>
          <AssociationSet Name="FK_Transaction_LoanRequest" Association="BuddyFinance.Model.FK_Transaction_LoanRequest">
            <End Role="LoanRequest" EntitySet="LoanRequests" />
            <End Role="Transaction" EntitySet="Transactions" />
          </AssociationSet>
          <EntitySet Name="Borrowers" EntityType="BuddyFinance.Model.Borrower" />
          <EntitySet Name="Lenders" EntityType="BuddyFinance.Model.Lender" />
          <AssociationSet Name="FK_Borrower_ProfileStatus" Association="BuddyFinance.Model.FK_Borrower_ProfileStatus">
            <End Role="ProfileStatus" EntitySet="ProfileStatus1" />
            <End Role="Borrower" EntitySet="Borrowers" />
          </AssociationSet>
          <AssociationSet Name="FK_Borrower_ProfileType" Association="BuddyFinance.Model.FK_Borrower_ProfileType">
            <End Role="ProfileType" EntitySet="ProfileTypes" />
            <End Role="Borrower" EntitySet="Borrowers" />
          </AssociationSet>
          <AssociationSet Name="FK_Loan_Borrower" Association="BuddyFinance.Model.FK_Loan_Borrower">
            <End Role="Borrower" EntitySet="Borrowers" />
            <End Role="Loan" EntitySet="Loans" />
          </AssociationSet>
          <AssociationSet Name="FK_LoanRequest_Borrower" Association="BuddyFinance.Model.FK_LoanRequest_Borrower">
            <End Role="Borrower" EntitySet="Borrowers" />
            <End Role="LoanRequest" EntitySet="LoanRequests" />
          </AssociationSet>
          <AssociationSet Name="FK_Lender_ProfileStatus" Association="BuddyFinance.Model.FK_Lender_ProfileStatus">
            <End Role="ProfileStatus" EntitySet="ProfileStatus1" />
            <End Role="Lender" EntitySet="Lenders" />
          </AssociationSet>
          <AssociationSet Name="FK_Lender_ProfileType" Association="BuddyFinance.Model.FK_Lender_ProfileType">
            <End Role="ProfileType" EntitySet="ProfileTypes" />
            <End Role="Lender" EntitySet="Lenders" />
          </AssociationSet>
          <AssociationSet Name="FK_Loan_Lender" Association="BuddyFinance.Model.FK_Loan_Lender">
            <End Role="Lender" EntitySet="Lenders" />
            <End Role="Loan" EntitySet="Loans" />
          </AssociationSet>
          <AssociationSet Name="FK_LoanOffer_Lender" Association="BuddyFinance.Model.FK_LoanOffer_Lender">
            <End Role="Lender" EntitySet="Lenders" />
            <End Role="LoanOffer" EntitySet="LoanOffers" />
          </AssociationSet>
          <EntitySet Name="Profiles" EntityType="BuddyFinance.Model.Profile" />
          <AssociationSet Name="FK_BankingDetail_Profile" Association="BuddyFinance.Model.FK_BankingDetail_Profile">
            <End Role="Profile" EntitySet="Profiles" />
            <End Role="BankingDetail" EntitySet="BankingDetails" />
          </AssociationSet>
          <AssociationSet Name="FK_Borrower_Profile" Association="BuddyFinance.Model.FK_Borrower_Profile">
            <End Role="Profile" EntitySet="Profiles" />
            <End Role="Borrower" EntitySet="Borrowers" />
          </AssociationSet>
          <AssociationSet Name="FK_CashDeposit_Profile" Association="BuddyFinance.Model.FK_CashDeposit_Profile">
            <End Role="Profile" EntitySet="Profiles" />
            <End Role="CashDeposit" EntitySet="CashDeposits" />
          </AssociationSet>
          <AssociationSet Name="FK_CashWithdrawal_Profile" Association="BuddyFinance.Model.FK_CashWithdrawal_Profile">
            <End Role="Profile" EntitySet="Profiles" />
            <End Role="CashWithdrawal" EntitySet="CashWithdrawals" />
          </AssociationSet>
          <AssociationSet Name="FK_Profile_Country" Association="BuddyFinance.Model.FK_Profile_Country">
            <End Role="Country" EntitySet="Countries" />
            <End Role="Profile" EntitySet="Profiles" />
          </AssociationSet>
          <AssociationSet Name="FK_EmploymentDetail_ProfileId" Association="BuddyFinance.Model.FK_EmploymentDetail_ProfileId">
            <End Role="Profile" EntitySet="Profiles" />
            <End Role="EmploymentDetail" EntitySet="EmploymentDetails" />
          </AssociationSet>
          <AssociationSet Name="FK_Profile_EmploymentStatus" Association="BuddyFinance.Model.FK_Profile_EmploymentStatus">
            <End Role="EmploymentStatus" EntitySet="EmploymentStatus1" />
            <End Role="Profile" EntitySet="Profiles" />
          </AssociationSet>
          <AssociationSet Name="FK_Profile_Ethnicity" Association="BuddyFinance.Model.FK_Profile_Ethnicity">
            <End Role="Ethnicity" EntitySet="Ethnicities" />
            <End Role="Profile" EntitySet="Profiles" />
          </AssociationSet>
          <AssociationSet Name="FK_FicaCompliance_Profile" Association="BuddyFinance.Model.FK_FicaCompliance_Profile">
            <End Role="Profile" EntitySet="Profiles" />
            <End Role="FicaCompliance" EntitySet="FicaCompliances" />
          </AssociationSet>
          <AssociationSet Name="FK_Profile_Gender" Association="BuddyFinance.Model.FK_Profile_Gender">
            <End Role="Gender" EntitySet="Genders" />
            <End Role="Profile" EntitySet="Profiles" />
          </AssociationSet>
          <AssociationSet Name="FK_Profile_IdentificationType" Association="BuddyFinance.Model.FK_Profile_IdentificationType">
            <End Role="IdentificationType" EntitySet="IdentificationTypes" />
            <End Role="Profile" EntitySet="Profiles" />
          </AssociationSet>
          <AssociationSet Name="FK_Lender_Profile" Association="BuddyFinance.Model.FK_Lender_Profile">
            <End Role="Profile" EntitySet="Profiles" />
            <End Role="Lender" EntitySet="Lenders" />
          </AssociationSet>
          <AssociationSet Name="FK_ManualDeduction_Profile" Association="BuddyFinance.Model.FK_ManualDeduction_Profile">
            <End Role="Profile" EntitySet="Profiles" />
            <End Role="ManualDeduction" EntitySet="ManualDeductions" />
          </AssociationSet>
          <AssociationSet Name="FK_NextOfKin_Profile" Association="BuddyFinance.Model.FK_NextOfKin_Profile">
            <End Role="Profile" EntitySet="Profiles" />
            <End Role="NextOfKin" EntitySet="NextOfKins" />
          </AssociationSet>
          <AssociationSet Name="FK_PreLoanRequest_Profile" Association="BuddyFinance.Model.FK_PreLoanRequest_Profile">
            <End Role="Profile" EntitySet="Profiles" />
            <End Role="PreLoanRequest" EntitySet="PreLoanRequests" />
          </AssociationSet>
          <AssociationSet Name="FK_Profile_ProfileStatus" Association="BuddyFinance.Model.FK_Profile_ProfileStatus">
            <End Role="ProfileStatus" EntitySet="ProfileStatus1" />
            <End Role="Profile" EntitySet="Profiles" />
          </AssociationSet>
          <AssociationSet Name="FK_Profile_SourceOfIncome" Association="BuddyFinance.Model.FK_Profile_SourceOfIncome">
            <End Role="SourceOfIncome" EntitySet="SourceOfIncomes" />
            <End Role="Profile" EntitySet="Profiles" />
          </AssociationSet>
          <AssociationSet Name="FK_ProfileApproval_Profile" Association="BuddyFinance.Model.FK_ProfileApproval_Profile">
            <End Role="Profile" EntitySet="Profiles" />
            <End Role="ProfileApproval" EntitySet="ProfileApprovals" />
          </AssociationSet>
          <AssociationSet Name="FK_ProfileCreditRatingScore_Borrower" Association="BuddyFinance.Model.FK_ProfileCreditRatingScore_Borrower">
            <End Role="Profile" EntitySet="Profiles" />
            <End Role="ProfileCreditRatingScore" EntitySet="ProfileCreditRatingScores" />
          </AssociationSet>
          <AssociationSet Name="FK_ProfileCreditRatingScore_Profile" Association="BuddyFinance.Model.FK_ProfileCreditRatingScore_Profile">
            <End Role="Profile" EntitySet="Profiles" />
            <End Role="ProfileCreditRatingScore" EntitySet="ProfileCreditRatingScores" />
          </AssociationSet>
          <AssociationSet Name="FK_ProfileDocument_Profile" Association="BuddyFinance.Model.FK_ProfileDocument_Profile">
            <End Role="Profile" EntitySet="Profiles" />
            <End Role="ProfileDocument" EntitySet="ProfileDocuments" />
          </AssociationSet>
          <AssociationSet Name="FK_ProfileSuspension_Profile" Association="BuddyFinance.Model.FK_ProfileSuspension_Profile">
            <End Role="Profile" EntitySet="Profiles" />
            <End Role="ProfileSuspension" EntitySet="ProfileSuspensions" />
          </AssociationSet>
          <AssociationSet Name="FK_TaxInformation_Profile" Association="BuddyFinance.Model.FK_TaxInformation_Profile">
            <End Role="Profile" EntitySet="Profiles" />
            <End Role="TaxInformation" EntitySet="TaxInformations" />
          </AssociationSet>
          <AssociationSet Name="FK_Transaction_Profile" Association="BuddyFinance.Model.FK_Transaction_Profile">
            <End Role="Profile" EntitySet="Profiles" />
            <End Role="Transaction" EntitySet="Transactions" />
          </AssociationSet>
          <AssociationSet Name="FK_User_Profile" Association="BuddyFinance.Model.FK_User_Profile">
            <End Role="Profile" EntitySet="Profiles" />
            <End Role="User" EntitySet="Users" />
          </AssociationSet>
          <EntitySet Name="ProfileAddresses" EntityType="BuddyFinance.Model.ProfileAddress" />
          <AssociationSet Name="FK_ProfileAddress_AddressType" Association="BuddyFinance.Model.FK_ProfileAddress_AddressType">
            <End Role="AddressType" EntitySet="AddressTypes" />
            <End Role="ProfileAddress" EntitySet="ProfileAddresses" />
          </AssociationSet>
          <AssociationSet Name="FK_ProfileAddress_Country" Association="BuddyFinance.Model.FK_ProfileAddress_Country">
            <End Role="Country" EntitySet="Countries" />
            <End Role="ProfileAddress" EntitySet="ProfileAddresses" />
          </AssociationSet>
          <AssociationSet Name="FK_ProfileAddress_Profile" Association="BuddyFinance.Model.FK_ProfileAddress_Profile">
            <End Role="Profile" EntitySet="Profiles" />
            <End Role="ProfileAddress" EntitySet="ProfileAddresses" />
          </AssociationSet>
          <AssociationSet Name="FK_ProfileAddress_Province" Association="BuddyFinance.Model.FK_ProfileAddress_Province">
            <End Role="Province" EntitySet="Provinces" />
            <End Role="ProfileAddress" EntitySet="ProfileAddresses" />
          </AssociationSet>
          </EntityContainer>
        <ComplexType Name="ProfileTransactions_Result">
          <Property Type="Int32" Name="Id" Nullable="false" />
          <Property Type="Int32" Name="ProfileId" Nullable="false" />
          <Property Type="DateTime" Name="TransactionDate" Nullable="false" Precision="23" />
          <Property Type="String" Name="Description" Nullable="false" MaxLength="250" />
          <Property Type="String" Name="Reference" Nullable="false" MaxLength="70" />
          <Property Type="String" Name="Type" Nullable="false" MaxLength="70" />
          <Property Type="String" Name="StatusType" Nullable="false" MaxLength="90" />
          <Property Type="Double" Name="Amount" Nullable="false" />
          <Property Type="String" Name="FeeTypeDescription" Nullable="false" MaxLength="50" />
          <Property Type="Double" Name="FeeAmount" Nullable="false" />
        </ComplexType>
        <EntityType Name="Loan">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="Int32" Nullable="false" annotation:StoreGeneratedPattern="Identity" />
          <Property Name="LoanRequestId" Type="Int32" Nullable="false" />
          <Property Name="LoanOfferId" Type="Int32" Nullable="false" />
          <Property Name="LoanAmount" Type="Double" Nullable="false" />
          <Property Name="FirstRepaymentDate" Type="DateTime" Nullable="false" Precision="3" />
          <Property Name="LoanDuration" Type="Int32" Nullable="false" />
          <Property Name="TermTypeId" Type="Int32" Nullable="false" />
          <Property Name="LoanStatusId" Type="Int32" Nullable="false" />
          <Property Name="CreatedDate" Type="DateTime" Nullable="false" Precision="3" />
          <Property Name="InitialPaymentAmount" Type="Double" Nullable="false" />
          <Property Name="DateAccepted" Type="DateTime" Precision="3" />
          <Property Name="MonthlyInstallmentAmount" Type="Double" Nullable="false" />
          <Property Name="TotalPayment" Type="Double" Nullable="false" />
          <Property Name="Comment" Type="String" MaxLength="Max" FixedLength="false" Unicode="true" />
          <Property Name="RepayCompletedDate" Type="DateTime" Precision="3" />
          <NavigationProperty Name="LoanStatus" Relationship="BuddyFinance.Model.FK_Loan_LoanStatus" FromRole="Loan" ToRole="LoanStatus" />
          <NavigationProperty Name="TermType" Relationship="BuddyFinance.Model.FK_Loan_TermType" FromRole="Loan" ToRole="TermType" />
          <NavigationProperty Name="LoanPayout" Relationship="BuddyFinance.Model.FK_LoanPayout_Loan" FromRole="Loan" ToRole="LoanPayout" />
          <NavigationProperty Name="LoanRepayments" Relationship="BuddyFinance.Model.FK_LoanRepayment_Loan" FromRole="Loan" ToRole="LoanRepayment" />
          <NavigationProperty Name="LoanSchedules" Relationship="BuddyFinance.Model.FK_LoanSchedule_Loan" FromRole="Loan" ToRole="LoanSchedule" />
          <NavigationProperty Name="Transactions" Relationship="BuddyFinance.Model.FK_Transaction_Loan" FromRole="Loan" ToRole="Transaction" />
          <Property Name="BorrowerId" Type="Int32" />
          <Property Name="LenderId" Type="Int32" />
          <NavigationProperty Name="LoanOffer" Relationship="BuddyFinance.Model.FK_Loan_LoanOffer" FromRole="Loan" ToRole="LoanOffer" />
          <NavigationProperty Name="LoanRequest" Relationship="BuddyFinance.Model.FK_Loan_LoanRequest" FromRole="Loan" ToRole="LoanRequest" />
          <NavigationProperty Name="Borrower" Relationship="BuddyFinance.Model.FK_Loan_Borrower" FromRole="Loan" ToRole="Borrower" />
          <NavigationProperty Name="Lender" Relationship="BuddyFinance.Model.FK_Loan_Lender" FromRole="Loan" ToRole="Lender" />
        </EntityType>
        <Association Name="FK_Loan_LoanStatus">
          <End Type="BuddyFinance.Model.LoanStatus" Role="LoanStatus" Multiplicity="1" />
          <End Type="BuddyFinance.Model.Loan" Role="Loan" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="LoanStatus">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="Loan">
              <PropertyRef Name="LoanStatusId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_Loan_TermType">
          <End Type="BuddyFinance.Model.TermType" Role="TermType" Multiplicity="1" />
          <End Type="BuddyFinance.Model.Loan" Role="Loan" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="TermType">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="Loan">
              <PropertyRef Name="TermTypeId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_LoanPayout_Loan">
          <End Type="BuddyFinance.Model.Loan" Role="Loan" Multiplicity="1" />
          <End Type="BuddyFinance.Model.LoanPayout" Role="LoanPayout" Multiplicity="0..1" />
          <ReferentialConstraint>
            <Principal Role="Loan">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="LoanPayout">
              <PropertyRef Name="LoanId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_LoanRepayment_Loan">
          <End Type="BuddyFinance.Model.Loan" Role="Loan" Multiplicity="1" />
          <End Type="BuddyFinance.Model.LoanRepayment" Role="LoanRepayment" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="Loan">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="LoanRepayment">
              <PropertyRef Name="LoanId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_LoanSchedule_Loan">
          <End Type="BuddyFinance.Model.Loan" Role="Loan" Multiplicity="1" />
          <End Type="BuddyFinance.Model.LoanSchedule" Role="LoanSchedule" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="Loan">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="LoanSchedule">
              <PropertyRef Name="LoanId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_Transaction_Loan">
          <End Type="BuddyFinance.Model.Loan" Role="Loan" Multiplicity="0..1" />
          <End Type="BuddyFinance.Model.Transaction" Role="Transaction" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="Loan">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="Transaction">
              <PropertyRef Name="LoanId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <EntityType Name="LoanRequestOffer">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="Int32" Nullable="false" annotation:StoreGeneratedPattern="Identity" />
          <Property Name="RequestDate" Type="DateTime" Nullable="false" Precision="3" />
          <Property Name="Comments" Type="String" MaxLength="500" FixedLength="false" Unicode="true" />
          <Property Name="OfferStausId" Type="Int32" Nullable="false" />
          <Property Name="LoanOfferId" Type="Int32" Nullable="false" />
          <Property Name="LoanRequestId" Type="Int32" Nullable="false" />
          <Property Name="IsActive" Type="Boolean" Nullable="false" />
          <Property Name="IOU_Accepted" Type="Boolean" Nullable="false" />
          <NavigationProperty Name="OfferStatus" Relationship="BuddyFinance.Model.FK_LoanRequestOffer_OfferStaus" FromRole="LoanRequestOffer" ToRole="OfferStatus" />
          <NavigationProperty Name="ProfileCreditRatingScores" Relationship="BuddyFinance.Model.FK_ProfileCreditRatingScore_LoanRequestOffer" FromRole="LoanRequestOffer" ToRole="ProfileCreditRatingScore" />
          <NavigationProperty Name="LoanOffer" Relationship="BuddyFinance.Model.FK_LoanRequestOffer_LoanOffer" FromRole="LoanRequestOffer" ToRole="LoanOffer" />
          <NavigationProperty Name="LoanRequest" Relationship="BuddyFinance.Model.FK_LoanRequestOffer_LoanRequest" FromRole="LoanRequestOffer" ToRole="LoanRequest" />
        </EntityType>
        <Association Name="FK_LoanRequestOffer_OfferStaus">
          <End Type="BuddyFinance.Model.OfferStatus" Role="OfferStatus" Multiplicity="1" />
          <End Type="BuddyFinance.Model.LoanRequestOffer" Role="LoanRequestOffer" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="OfferStatus">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="LoanRequestOffer">
              <PropertyRef Name="OfferStausId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_ProfileCreditRatingScore_LoanRequestOffer">
          <End Type="BuddyFinance.Model.LoanRequestOffer" Role="LoanRequestOffer" Multiplicity="0..1" />
          <End Type="BuddyFinance.Model.ProfileCreditRatingScore" Role="ProfileCreditRatingScore" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="LoanRequestOffer">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="ProfileCreditRatingScore">
              <PropertyRef Name="LoanRequestOfferId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <EntityType Name="FeeType">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="Int32" Nullable="false" annotation:StoreGeneratedPattern="Identity" />
          <Property Name="Description" Type="String" Nullable="false" MaxLength="50" FixedLength="false" Unicode="true" />
          <Property Name="Basis" Type="Double" Nullable="false" />
          <Property Name="Amount" Type="Double" Nullable="false" />
          <Property Name="Percentage" Type="Double" Nullable="false" />
          <Property Name="VatPercentage" Type="Double" Nullable="false" />
          <Property Name="AmountForPercentUse" Type="Double" Nullable="false" />
          <NavigationProperty Name="TransactionFees" Relationship="BuddyFinance.Model.FK_TransactionFee_FeeType" FromRole="FeeType" ToRole="TransactionFee" />
        </EntityType>
        <Association Name="FK_TransactionFee_FeeType">
          <End Type="BuddyFinance.Model.FeeType" Role="FeeType" Multiplicity="1" />
          <End Type="BuddyFinance.Model.TransactionFee" Role="TransactionFee" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="FeeType">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="TransactionFee">
              <PropertyRef Name="FeeTypeId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_Transaction_ProfileType">
          <End Type="BuddyFinance.Model.ProfileType" Role="ProfileType" Multiplicity="1" />
          <End Type="BuddyFinance.Model.Transaction" Role="Transaction" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="ProfileType">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="Transaction">
              <PropertyRef Name="ProfileTypeId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <EntityType Name="LoanOffer">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="Int32" Nullable="false" annotation:StoreGeneratedPattern="Identity" />
          <Property Name="LenderId" Type="Int32" Nullable="false" />
          <Property Name="Amount" Type="Double" Nullable="false" />
          <Property Name="Balance" Type="Double" Nullable="false" />
          <Property Name="InterestRate" Type="Double" Nullable="false" />
          <Property Name="Term" Type="Int32" Nullable="false" />
          <Property Name="TermTypeId" Type="Int32" Nullable="false" />
          <Property Name="IsActive" Type="Boolean" Nullable="false" />
          <Property Name="DateCreated" Type="DateTime" Nullable="false" Precision="3" />
          <Property Name="ExpiryDate" Type="DateTime" Precision="3" />
          <Property Name="IsDeleted" Type="Boolean" Nullable="false" />
          <NavigationProperty Name="Loans" Relationship="BuddyFinance.Model.FK_Loan_LoanOffer" FromRole="LoanOffer" ToRole="Loan" />
          <NavigationProperty Name="TermType" Relationship="BuddyFinance.Model.FK_LoanOffer_TermType" FromRole="LoanOffer" ToRole="TermType" />
          <NavigationProperty Name="LoanRequestOffers" Relationship="BuddyFinance.Model.FK_LoanRequestOffer_LoanOffer" FromRole="LoanOffer" ToRole="LoanRequestOffer" />
          <NavigationProperty Name="Lender" Relationship="BuddyFinance.Model.FK_LoanOffer_Lender" FromRole="LoanOffer" ToRole="Lender" />
        </EntityType>
        <EntityType Name="LoanRequest">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="Int32" Nullable="false" annotation:StoreGeneratedPattern="Identity" />
          <Property Name="RequestedDate" Type="DateTime" Nullable="false" Precision="3" />
          <Property Name="BorrowerId" Type="Int32" Nullable="false" />
          <Property Name="Amount" Type="Double" Nullable="false" />
          <Property Name="Term" Type="Int32" Nullable="false" />
          <Property Name="TermTypeId" Type="Int32" Nullable="false" />
          <Property Name="FirstPaymentDate" Type="DateTime" Nullable="false" Precision="3" />
          <Property Name="ReferenceNumber" Type="String" MaxLength="50" FixedLength="false" Unicode="true" />
          <Property Name="LoanRequestStatusId" Type="Int32" Nullable="false" />
          <NavigationProperty Name="Loans" Relationship="BuddyFinance.Model.FK_Loan_LoanRequest" FromRole="LoanRequest" ToRole="Loan" />
          <NavigationProperty Name="LoanRequestStatus" Relationship="BuddyFinance.Model.FK_LoanRequest_LoanRequestStatus" FromRole="LoanRequest" ToRole="LoanRequestStatus" />
          <NavigationProperty Name="TermType" Relationship="BuddyFinance.Model.FK_LoanRequest_TermType" FromRole="LoanRequest" ToRole="TermType" />
          <NavigationProperty Name="LoanRequestOffers" Relationship="BuddyFinance.Model.FK_LoanRequestOffer_LoanRequest" FromRole="LoanRequest" ToRole="LoanRequestOffer" />
          <NavigationProperty Name="Transactions" Relationship="BuddyFinance.Model.FK_Transaction_LoanRequest" FromRole="LoanRequest" ToRole="Transaction" />
          <NavigationProperty Name="Borrower" Relationship="BuddyFinance.Model.FK_LoanRequest_Borrower" FromRole="LoanRequest" ToRole="Borrower" />
        </EntityType>
        <Association Name="FK_Loan_LoanOffer">
          <End Type="BuddyFinance.Model.LoanOffer" Role="LoanOffer" Multiplicity="1" />
          <End Type="BuddyFinance.Model.Loan" Role="Loan" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="LoanOffer">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="Loan">
              <PropertyRef Name="LoanOfferId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_Loan_LoanRequest">
          <End Type="BuddyFinance.Model.LoanRequest" Role="LoanRequest" Multiplicity="1" />
          <End Type="BuddyFinance.Model.Loan" Role="Loan" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="LoanRequest">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="Loan">
              <PropertyRef Name="LoanRequestId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_LoanOffer_TermType">
          <End Type="BuddyFinance.Model.TermType" Role="TermType" Multiplicity="1" />
          <End Type="BuddyFinance.Model.LoanOffer" Role="LoanOffer" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="TermType">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="LoanOffer">
              <PropertyRef Name="TermTypeId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_LoanRequestOffer_LoanOffer">
          <End Type="BuddyFinance.Model.LoanOffer" Role="LoanOffer" Multiplicity="1" />
          <End Type="BuddyFinance.Model.LoanRequestOffer" Role="LoanRequestOffer" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="LoanOffer">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="LoanRequestOffer">
              <PropertyRef Name="LoanOfferId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_LoanRequest_LoanRequestStatus">
          <End Type="BuddyFinance.Model.LoanRequestStatus" Role="LoanRequestStatus" Multiplicity="1" />
          <End Type="BuddyFinance.Model.LoanRequest" Role="LoanRequest" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="LoanRequestStatus">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="LoanRequest">
              <PropertyRef Name="LoanRequestStatusId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_LoanRequest_TermType">
          <End Type="BuddyFinance.Model.TermType" Role="TermType" Multiplicity="1" />
          <End Type="BuddyFinance.Model.LoanRequest" Role="LoanRequest" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="TermType">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="LoanRequest">
              <PropertyRef Name="TermTypeId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_LoanRequestOffer_LoanRequest">
          <End Type="BuddyFinance.Model.LoanRequest" Role="LoanRequest" Multiplicity="1" />
          <End Type="BuddyFinance.Model.LoanRequestOffer" Role="LoanRequestOffer" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="LoanRequest">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="LoanRequestOffer">
              <PropertyRef Name="LoanRequestId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_Transaction_LoanRequest">
          <End Type="BuddyFinance.Model.LoanRequest" Role="LoanRequest" Multiplicity="0..1" />
          <End Type="BuddyFinance.Model.Transaction" Role="Transaction" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="LoanRequest">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="Transaction">
              <PropertyRef Name="LoanRequestId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <EntityType Name="Borrower">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="Int32" Nullable="false" />
          <Property Name="BorrowerNumber" Type="String" Nullable="false" MaxLength="50" FixedLength="false" Unicode="true" />
          <Property Name="ProfileTypeId" Type="Int32" Nullable="false" />
          <Property Name="StatusId" Type="Int32" Nullable="false" />
          <NavigationProperty Name="ProfileStatus" Relationship="BuddyFinance.Model.FK_Borrower_ProfileStatus" FromRole="Borrower" ToRole="ProfileStatus" />
          <NavigationProperty Name="ProfileType" Relationship="BuddyFinance.Model.FK_Borrower_ProfileType" FromRole="Borrower" ToRole="ProfileType" />
          <NavigationProperty Name="Loans" Relationship="BuddyFinance.Model.FK_Loan_Borrower" FromRole="Borrower" ToRole="Loan" />
          <NavigationProperty Name="LoanRequests" Relationship="BuddyFinance.Model.FK_LoanRequest_Borrower" FromRole="Borrower" ToRole="LoanRequest" />
          <NavigationProperty Name="Profile" Relationship="BuddyFinance.Model.FK_Borrower_Profile" FromRole="Borrower" ToRole="Profile" />
        </EntityType>
        <EntityType Name="Lender">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="Int32" Nullable="false" />
          <Property Name="LenderNumber" Type="String" Nullable="false" MaxLength="50" FixedLength="false" Unicode="true" />
          <Property Name="ProfileTypeId" Type="Int32" Nullable="false" />
          <Property Name="StatusId" Type="Int32" Nullable="false" />
          <NavigationProperty Name="ProfileStatus" Relationship="BuddyFinance.Model.FK_Lender_ProfileStatus" FromRole="Lender" ToRole="ProfileStatus" />
          <NavigationProperty Name="ProfileType" Relationship="BuddyFinance.Model.FK_Lender_ProfileType" FromRole="Lender" ToRole="ProfileType" />
          <NavigationProperty Name="Loans" Relationship="BuddyFinance.Model.FK_Loan_Lender" FromRole="Lender" ToRole="Loan" />
          <NavigationProperty Name="LoanOffers" Relationship="BuddyFinance.Model.FK_LoanOffer_Lender" FromRole="Lender" ToRole="LoanOffer" />
          <NavigationProperty Name="Profile" Relationship="BuddyFinance.Model.FK_Lender_Profile" FromRole="Lender" ToRole="Profile" />
        </EntityType>
        <Association Name="FK_Borrower_ProfileStatus">
          <End Type="BuddyFinance.Model.ProfileStatus" Role="ProfileStatus" Multiplicity="1" />
          <End Type="BuddyFinance.Model.Borrower" Role="Borrower" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="ProfileStatus">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="Borrower">
              <PropertyRef Name="StatusId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_Borrower_ProfileType">
          <End Type="BuddyFinance.Model.ProfileType" Role="ProfileType" Multiplicity="1" />
          <End Type="BuddyFinance.Model.Borrower" Role="Borrower" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="ProfileType">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="Borrower">
              <PropertyRef Name="ProfileTypeId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_Loan_Borrower">
          <End Type="BuddyFinance.Model.Borrower" Role="Borrower" Multiplicity="0..1" />
          <End Type="BuddyFinance.Model.Loan" Role="Loan" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="Borrower">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="Loan">
              <PropertyRef Name="BorrowerId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_LoanRequest_Borrower">
          <End Type="BuddyFinance.Model.Borrower" Role="Borrower" Multiplicity="1" />
          <End Type="BuddyFinance.Model.LoanRequest" Role="LoanRequest" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="Borrower">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="LoanRequest">
              <PropertyRef Name="BorrowerId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_Lender_ProfileStatus">
          <End Type="BuddyFinance.Model.ProfileStatus" Role="ProfileStatus" Multiplicity="1" />
          <End Type="BuddyFinance.Model.Lender" Role="Lender" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="ProfileStatus">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="Lender">
              <PropertyRef Name="StatusId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_Lender_ProfileType">
          <End Type="BuddyFinance.Model.ProfileType" Role="ProfileType" Multiplicity="1" />
          <End Type="BuddyFinance.Model.Lender" Role="Lender" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="ProfileType">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="Lender">
              <PropertyRef Name="ProfileTypeId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_Loan_Lender">
          <End Type="BuddyFinance.Model.Lender" Role="Lender" Multiplicity="0..1" />
          <End Type="BuddyFinance.Model.Loan" Role="Loan" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="Lender">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="Loan">
              <PropertyRef Name="LenderId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_LoanOffer_Lender">
          <End Type="BuddyFinance.Model.Lender" Role="Lender" Multiplicity="1" />
          <End Type="BuddyFinance.Model.LoanOffer" Role="LoanOffer" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="Lender">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="LoanOffer">
              <PropertyRef Name="LenderId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <EntityType Name="Profile">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="Int32" Nullable="false" annotation:StoreGeneratedPattern="Identity" />
          <Property Name="ProfileNumber" Type="String" Nullable="false" MaxLength="50" FixedLength="false" Unicode="true" />
          <Property Name="Title" Type="String" MaxLength="50" FixedLength="false" Unicode="true" />
          <Property Name="Name" Type="String" Nullable="false" MaxLength="50" FixedLength="false" Unicode="true" />
          <Property Name="Surname" Type="String" Nullable="false" MaxLength="50" FixedLength="false" Unicode="true" />
          <Property Name="EmailAddress" Type="String" Nullable="false" MaxLength="50" FixedLength="false" Unicode="true" />
          <Property Name="ContactNumber" Type="String" MaxLength="50" FixedLength="false" Unicode="true" />
          <Property Name="DateOfBirth" Type="DateTime" Precision="3" />
          <Property Name="GenderId" Type="Int32" />
          <Property Name="CountryOfBirthId" Type="Int32" />
          <Property Name="EthnicityId" Type="Int32" />
          <Property Name="IdentificationTypeId" Type="Int32" />
          <Property Name="IdentificationNumber" Type="String" Nullable="false" MaxLength="50" FixedLength="false" Unicode="true" />
          <Property Name="AvailableFunds" Type="Double" Nullable="false" />
          <Property Name="CashDeposit" Type="Double" />
          <Property Name="CashWithdrawal" Type="Double" />
          <Property Name="TaxRegistered" Type="Boolean" />
          <Property Name="SourceOfIncomeId" Type="Int32" />
          <Property Name="OtherSourceOfIncome" Type="String" MaxLength="50" FixedLength="false" Unicode="true" />
          <Property Name="EmploymentStatusId" Type="Int32" />
          <Property Name="StatusId" Type="Int32" Nullable="false" />
          <Property Name="BillingDate" Type="DateTime" Precision="3" />
          <Property Name="LastBillDate" Type="DateTime" Precision="3" />
          <NavigationProperty Name="BankingDetail" Relationship="BuddyFinance.Model.FK_BankingDetail_Profile" FromRole="Profile" ToRole="BankingDetail" />
          <NavigationProperty Name="Borrower" Relationship="BuddyFinance.Model.FK_Borrower_Profile" FromRole="Profile" ToRole="Borrower" />
          <NavigationProperty Name="CashDeposits" Relationship="BuddyFinance.Model.FK_CashDeposit_Profile" FromRole="Profile" ToRole="CashDeposit" />
          <NavigationProperty Name="CashWithdrawals" Relationship="BuddyFinance.Model.FK_CashWithdrawal_Profile" FromRole="Profile" ToRole="CashWithdrawal" />
          <NavigationProperty Name="Country" Relationship="BuddyFinance.Model.FK_Profile_Country" FromRole="Profile" ToRole="Country" />
          <NavigationProperty Name="EmploymentDetail" Relationship="BuddyFinance.Model.FK_EmploymentDetail_ProfileId" FromRole="Profile" ToRole="EmploymentDetail" />
          <NavigationProperty Name="EmploymentStatus" Relationship="BuddyFinance.Model.FK_Profile_EmploymentStatus" FromRole="Profile" ToRole="EmploymentStatus" />
          <NavigationProperty Name="Ethnicity" Relationship="BuddyFinance.Model.FK_Profile_Ethnicity" FromRole="Profile" ToRole="Ethnicity" />
          <NavigationProperty Name="FicaCompliance" Relationship="BuddyFinance.Model.FK_FicaCompliance_Profile" FromRole="Profile" ToRole="FicaCompliance" />
          <NavigationProperty Name="Gender" Relationship="BuddyFinance.Model.FK_Profile_Gender" FromRole="Profile" ToRole="Gender" />
          <NavigationProperty Name="IdentificationType" Relationship="BuddyFinance.Model.FK_Profile_IdentificationType" FromRole="Profile" ToRole="IdentificationType" />
          <NavigationProperty Name="Lender" Relationship="BuddyFinance.Model.FK_Lender_Profile" FromRole="Profile" ToRole="Lender" />
          <NavigationProperty Name="ManualDeductions" Relationship="BuddyFinance.Model.FK_ManualDeduction_Profile" FromRole="Profile" ToRole="ManualDeduction" />
          <NavigationProperty Name="NextOfKin" Relationship="BuddyFinance.Model.FK_NextOfKin_Profile" FromRole="Profile" ToRole="NextOfKin" />
          <NavigationProperty Name="PreLoanRequests" Relationship="BuddyFinance.Model.FK_PreLoanRequest_Profile" FromRole="Profile" ToRole="PreLoanRequest" />
          <NavigationProperty Name="ProfileStatus" Relationship="BuddyFinance.Model.FK_Profile_ProfileStatus" FromRole="Profile" ToRole="ProfileStatus" />
          <NavigationProperty Name="SourceOfIncome" Relationship="BuddyFinance.Model.FK_Profile_SourceOfIncome" FromRole="Profile" ToRole="SourceOfIncome" />
          <NavigationProperty Name="ProfileApproval" Relationship="BuddyFinance.Model.FK_ProfileApproval_Profile" FromRole="Profile" ToRole="ProfileApproval" />
          <NavigationProperty Name="ProfileCreditRatingScores" Relationship="BuddyFinance.Model.FK_ProfileCreditRatingScore_Borrower" FromRole="Profile" ToRole="ProfileCreditRatingScore" />
          <NavigationProperty Name="ProfileCreditRatingScores1" Relationship="BuddyFinance.Model.FK_ProfileCreditRatingScore_Profile" FromRole="Profile" ToRole="ProfileCreditRatingScore" />
          <NavigationProperty Name="ProfileDocuments" Relationship="BuddyFinance.Model.FK_ProfileDocument_Profile" FromRole="Profile" ToRole="ProfileDocument" />
          <NavigationProperty Name="ProfileSuspension" Relationship="BuddyFinance.Model.FK_ProfileSuspension_Profile" FromRole="Profile" ToRole="ProfileSuspension" />
          <NavigationProperty Name="TaxInformation" Relationship="BuddyFinance.Model.FK_TaxInformation_Profile" FromRole="Profile" ToRole="TaxInformation" />
          <NavigationProperty Name="Transactions" Relationship="BuddyFinance.Model.FK_Transaction_Profile" FromRole="Profile" ToRole="Transaction" />
          <NavigationProperty Name="Users" Relationship="BuddyFinance.Model.FK_User_Profile" FromRole="Profile" ToRole="User" />
          <NavigationProperty Name="ProfileAddresses" Relationship="BuddyFinance.Model.FK_ProfileAddress_Profile" FromRole="Profile" ToRole="ProfileAddress" />
          <Property Name="LendServiceAccount" Type="Boolean" />
          <Property Name="BorrowServiceAccount" Type="Boolean" />
        </EntityType>
        <Association Name="FK_BankingDetail_Profile">
          <End Type="BuddyFinance.Model.Profile" Role="Profile" Multiplicity="1" />
          <End Type="BuddyFinance.Model.BankingDetail" Role="BankingDetail" Multiplicity="0..1" />
          <ReferentialConstraint>
            <Principal Role="Profile">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="BankingDetail">
              <PropertyRef Name="ProfileId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_Borrower_Profile">
          <End Type="BuddyFinance.Model.Profile" Role="Profile" Multiplicity="1" />
          <End Type="BuddyFinance.Model.Borrower" Role="Borrower" Multiplicity="0..1" />
          <ReferentialConstraint>
            <Principal Role="Profile">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="Borrower">
              <PropertyRef Name="Id" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_CashDeposit_Profile">
          <End Type="BuddyFinance.Model.Profile" Role="Profile" Multiplicity="1" />
          <End Type="BuddyFinance.Model.CashDeposit" Role="CashDeposit" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="Profile">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="CashDeposit">
              <PropertyRef Name="ProfileId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_CashWithdrawal_Profile">
          <End Type="BuddyFinance.Model.Profile" Role="Profile" Multiplicity="1" />
          <End Type="BuddyFinance.Model.CashWithdrawal" Role="CashWithdrawal" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="Profile">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="CashWithdrawal">
              <PropertyRef Name="ProfileId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_Profile_Country">
          <End Type="BuddyFinance.Model.Country" Role="Country" Multiplicity="0..1" />
          <End Type="BuddyFinance.Model.Profile" Role="Profile" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="Country">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="Profile">
              <PropertyRef Name="CountryOfBirthId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_EmploymentDetail_ProfileId">
          <End Type="BuddyFinance.Model.Profile" Role="Profile" Multiplicity="1" />
          <End Type="BuddyFinance.Model.EmploymentDetail" Role="EmploymentDetail" Multiplicity="0..1" />
          <ReferentialConstraint>
            <Principal Role="Profile">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="EmploymentDetail">
              <PropertyRef Name="ProfileId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_Profile_EmploymentStatus">
          <End Type="BuddyFinance.Model.EmploymentStatus" Role="EmploymentStatus" Multiplicity="0..1" />
          <End Type="BuddyFinance.Model.Profile" Role="Profile" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="EmploymentStatus">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="Profile">
              <PropertyRef Name="EmploymentStatusId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_Profile_Ethnicity">
          <End Type="BuddyFinance.Model.Ethnicity" Role="Ethnicity" Multiplicity="0..1" />
          <End Type="BuddyFinance.Model.Profile" Role="Profile" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="Ethnicity">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="Profile">
              <PropertyRef Name="EthnicityId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_FicaCompliance_Profile">
          <End Type="BuddyFinance.Model.Profile" Role="Profile" Multiplicity="1" />
          <End Type="BuddyFinance.Model.FicaCompliance" Role="FicaCompliance" Multiplicity="0..1" />
          <ReferentialConstraint>
            <Principal Role="Profile">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="FicaCompliance">
              <PropertyRef Name="ProfileId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_Profile_Gender">
          <End Type="BuddyFinance.Model.Gender" Role="Gender" Multiplicity="0..1" />
          <End Type="BuddyFinance.Model.Profile" Role="Profile" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="Gender">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="Profile">
              <PropertyRef Name="GenderId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_Profile_IdentificationType">
          <End Type="BuddyFinance.Model.IdentificationType" Role="IdentificationType" Multiplicity="0..1" />
          <End Type="BuddyFinance.Model.Profile" Role="Profile" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="IdentificationType">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="Profile">
              <PropertyRef Name="IdentificationTypeId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_Lender_Profile">
          <End Type="BuddyFinance.Model.Profile" Role="Profile" Multiplicity="1" />
          <End Type="BuddyFinance.Model.Lender" Role="Lender" Multiplicity="0..1" />
          <ReferentialConstraint>
            <Principal Role="Profile">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="Lender">
              <PropertyRef Name="Id" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_ManualDeduction_Profile">
          <End Type="BuddyFinance.Model.Profile" Role="Profile" Multiplicity="1" />
          <End Type="BuddyFinance.Model.ManualDeduction" Role="ManualDeduction" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="Profile">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="ManualDeduction">
              <PropertyRef Name="ProfileId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_NextOfKin_Profile">
          <End Type="BuddyFinance.Model.Profile" Role="Profile" Multiplicity="1" />
          <End Type="BuddyFinance.Model.NextOfKin" Role="NextOfKin" Multiplicity="0..1" />
          <ReferentialConstraint>
            <Principal Role="Profile">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="NextOfKin">
              <PropertyRef Name="ProfileId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_PreLoanRequest_Profile">
          <End Type="BuddyFinance.Model.Profile" Role="Profile" Multiplicity="1" />
          <End Type="BuddyFinance.Model.PreLoanRequest" Role="PreLoanRequest" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="Profile">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="PreLoanRequest">
              <PropertyRef Name="BorrowerId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_Profile_ProfileStatus">
          <End Type="BuddyFinance.Model.ProfileStatus" Role="ProfileStatus" Multiplicity="1" />
          <End Type="BuddyFinance.Model.Profile" Role="Profile" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="ProfileStatus">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="Profile">
              <PropertyRef Name="StatusId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_Profile_SourceOfIncome">
          <End Type="BuddyFinance.Model.SourceOfIncome" Role="SourceOfIncome" Multiplicity="0..1" />
          <End Type="BuddyFinance.Model.Profile" Role="Profile" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="SourceOfIncome">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="Profile">
              <PropertyRef Name="SourceOfIncomeId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_ProfileApproval_Profile">
          <End Type="BuddyFinance.Model.Profile" Role="Profile" Multiplicity="1" />
          <End Type="BuddyFinance.Model.ProfileApproval" Role="ProfileApproval" Multiplicity="0..1" />
          <ReferentialConstraint>
            <Principal Role="Profile">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="ProfileApproval">
              <PropertyRef Name="ProfileId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_ProfileCreditRatingScore_Borrower">
          <End Type="BuddyFinance.Model.Profile" Role="Profile" Multiplicity="0..1" />
          <End Type="BuddyFinance.Model.ProfileCreditRatingScore" Role="ProfileCreditRatingScore" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="Profile">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="ProfileCreditRatingScore">
              <PropertyRef Name="BorrowerId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_ProfileCreditRatingScore_Profile">
          <End Type="BuddyFinance.Model.Profile" Role="Profile" Multiplicity="1" />
          <End Type="BuddyFinance.Model.ProfileCreditRatingScore" Role="ProfileCreditRatingScore" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="Profile">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="ProfileCreditRatingScore">
              <PropertyRef Name="ProfileId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_ProfileDocument_Profile">
          <End Type="BuddyFinance.Model.Profile" Role="Profile" Multiplicity="1" />
          <End Type="BuddyFinance.Model.ProfileDocument" Role="ProfileDocument" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="Profile">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="ProfileDocument">
              <PropertyRef Name="ProfileId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_ProfileSuspension_Profile">
          <End Type="BuddyFinance.Model.Profile" Role="Profile" Multiplicity="1" />
          <End Type="BuddyFinance.Model.ProfileSuspension" Role="ProfileSuspension" Multiplicity="0..1" />
          <ReferentialConstraint>
            <Principal Role="Profile">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="ProfileSuspension">
              <PropertyRef Name="ProfileId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_TaxInformation_Profile">
          <End Type="BuddyFinance.Model.Profile" Role="Profile" Multiplicity="1" />
          <End Type="BuddyFinance.Model.TaxInformation" Role="TaxInformation" Multiplicity="0..1" />
          <ReferentialConstraint>
            <Principal Role="Profile">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="TaxInformation">
              <PropertyRef Name="ProfileId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_Transaction_Profile">
          <End Type="BuddyFinance.Model.Profile" Role="Profile" Multiplicity="1" />
          <End Type="BuddyFinance.Model.Transaction" Role="Transaction" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="Profile">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="Transaction">
              <PropertyRef Name="ProfileId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_User_Profile">
          <End Type="BuddyFinance.Model.Profile" Role="Profile" Multiplicity="1" />
          <End Type="BuddyFinance.Model.User" Role="User" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="Profile">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="User">
              <PropertyRef Name="ProfileId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <EntityType Name="ProfileAddress">
          <Key>
            <PropertyRef Name="Id" />
          </Key>
          <Property Name="Id" Type="Int32" Nullable="false" annotation:StoreGeneratedPattern="Identity" />
          <Property Name="ProfileId" Type="Int32" Nullable="false" />
          <Property Name="AddressTypeId" Type="Int32" Nullable="false" />
          <Property Name="Line1" Type="String" Nullable="false" MaxLength="50" FixedLength="false" Unicode="true" />
          <Property Name="Line2" Type="String" MaxLength="50" FixedLength="false" Unicode="true" />
          <Property Name="City" Type="String" MaxLength="50" FixedLength="false" Unicode="true" />
          <Property Name="PostalCode" Type="String" MaxLength="50" FixedLength="false" Unicode="true" />
          <Property Name="ProvinceId" Type="Int32" />
          <Property Name="CountryId" Type="Int32" />
          <Property Name="IsDeleted" Type="Boolean" Nullable="false" />
          <NavigationProperty Name="AddressType" Relationship="BuddyFinance.Model.FK_ProfileAddress_AddressType" FromRole="ProfileAddress" ToRole="AddressType" />
          <NavigationProperty Name="Country" Relationship="BuddyFinance.Model.FK_ProfileAddress_Country" FromRole="ProfileAddress" ToRole="Country" />
          <NavigationProperty Name="Profile" Relationship="BuddyFinance.Model.FK_ProfileAddress_Profile" FromRole="ProfileAddress" ToRole="Profile" />
          <NavigationProperty Name="Province" Relationship="BuddyFinance.Model.FK_ProfileAddress_Province" FromRole="ProfileAddress" ToRole="Province" />
        </EntityType>
        <Association Name="FK_ProfileAddress_AddressType">
          <End Type="BuddyFinance.Model.AddressType" Role="AddressType" Multiplicity="1" />
          <End Type="BuddyFinance.Model.ProfileAddress" Role="ProfileAddress" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="AddressType">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="ProfileAddress">
              <PropertyRef Name="AddressTypeId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_ProfileAddress_Country">
          <End Type="BuddyFinance.Model.Country" Role="Country" Multiplicity="0..1" />
          <End Type="BuddyFinance.Model.ProfileAddress" Role="ProfileAddress" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="Country">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="ProfileAddress">
              <PropertyRef Name="CountryId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_ProfileAddress_Profile">
          <End Type="BuddyFinance.Model.Profile" Role="Profile" Multiplicity="1" />
          <End Type="BuddyFinance.Model.ProfileAddress" Role="ProfileAddress" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="Profile">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="ProfileAddress">
              <PropertyRef Name="ProfileId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        <Association Name="FK_ProfileAddress_Province">
          <End Type="BuddyFinance.Model.Province" Role="Province" Multiplicity="0..1" />
          <End Type="BuddyFinance.Model.ProfileAddress" Role="ProfileAddress" Multiplicity="*" />
          <ReferentialConstraint>
            <Principal Role="Province">
              <PropertyRef Name="Id" />
            </Principal>
            <Dependent Role="ProfileAddress">
              <PropertyRef Name="ProvinceId" />
            </Dependent>
          </ReferentialConstraint>
        </Association>
        </Schema>
    </edmx:ConceptualModels>
    <!-- C-S mapping content -->
    <edmx:Mappings>
      <Mapping Space="C-S" xmlns="http://schemas.microsoft.com/ado/2009/11/mapping/cs">
        <EntityContainerMapping StorageEntityContainer="BuddyFinanceModelStoreContainer" CdmEntityContainer="BuddyFinanceDBEntities">
          <EntitySetMapping Name="ActivityLogs">
            <EntityTypeMapping TypeName="BuddyFinance.Model.ActivityLog">
              <MappingFragment StoreEntitySet="ActivityLog">
                <ScalarProperty Name="Id" ColumnName="Id" />
                <ScalarProperty Name="Type" ColumnName="Type" />
                <ScalarProperty Name="TimeStamp" ColumnName="TimeStamp" />
                <ScalarProperty Name="Description" ColumnName="Description" />
                <ScalarProperty Name="UserId" ColumnName="UserId" />
                <ScalarProperty Name="IpAddress" ColumnName="IpAddress" />
                <ScalarProperty Name="UserAgent" ColumnName="UserAgent" />
              </MappingFragment>
            </EntityTypeMapping>
          </EntitySetMapping>
          <EntitySetMapping Name="AddressTypes">
            <EntityTypeMapping TypeName="BuddyFinance.Model.AddressType">
              <MappingFragment StoreEntitySet="AddressType">
                <ScalarProperty Name="Id" ColumnName="Id" />
                <ScalarProperty Name="Description" ColumnName="Description" />
              </MappingFragment>
            </EntityTypeMapping>
          </EntitySetMapping>
          <EntitySetMapping Name="AuthenticationCodes">
            <EntityTypeMapping TypeName="BuddyFinance.Model.AuthenticationCode">
              <MappingFragment StoreEntitySet="AuthenticationCode">
                <ScalarProperty Name="Id" ColumnName="Id" />
                <ScalarProperty Name="Code" ColumnName="Code" />
                <ScalarProperty Name="Number" ColumnName="Number" />
                <ScalarProperty Name="Type" ColumnName="Type" />
                <ScalarProperty Name="IsValid" ColumnName="IsValid" />
              </MappingFragment>
            </EntityTypeMapping>
          </EntitySetMapping>
          <EntitySetMapping Name="BankingDetails">
            <EntityTypeMapping TypeName="BuddyFinance.Model.BankingDetail">
              <MappingFragment StoreEntitySet="BankingDetail">
                <ScalarProperty Name="ProfileId" ColumnName="ProfileId" />
                <ScalarProperty Name="BankName" ColumnName="BankName" />
                <ScalarProperty Name="AccountType" ColumnName="AccountType" />
                <ScalarProperty Name="BranchName" ColumnName="BranchName" />
                <ScalarProperty Name="BranchCode" ColumnName="BranchCode" />
                <ScalarProperty Name="AccountName" ColumnName="AccountName" />
                <ScalarProperty Name="AccountNumber" ColumnName="AccountNumber" />
              </MappingFragment>
            </EntityTypeMapping>
          </EntitySetMapping>
          <EntitySetMapping Name="CashDeposits">
            <EntityTypeMapping TypeName="BuddyFinance.Model.CashDeposit">
              <MappingFragment StoreEntitySet="CashDeposit">
                <ScalarProperty Name="Id" ColumnName="Id" />
                <ScalarProperty Name="ProfileId" ColumnName="ProfileId" />
                <ScalarProperty Name="Amount" ColumnName="Amount" />
                <ScalarProperty Name="Date" ColumnName="Date" />
                <ScalarProperty Name="Comment" ColumnName="Comment" />
                <ScalarProperty Name="UserId" ColumnName="UserId" />
              </MappingFragment>
            </EntityTypeMapping>
          </EntitySetMapping>
          <EntitySetMapping Name="CashWithdrawals">
            <EntityTypeMapping TypeName="BuddyFinance.Model.CashWithdrawal">
              <MappingFragment StoreEntitySet="CashWithdrawal">
                <ScalarProperty Name="Id" ColumnName="Id" />
                <ScalarProperty Name="ProfileId" ColumnName="ProfileId" />
                <ScalarProperty Name="Amount" ColumnName="Amount" />
                <ScalarProperty Name="Date" ColumnName="Date" />
                <ScalarProperty Name="Comment" ColumnName="Comment" />
                <ScalarProperty Name="StatusId" ColumnName="StatusId" />
                <ScalarProperty Name="ReviewerId" ColumnName="ReviewerId" />
                <ScalarProperty Name="ReviewDate" ColumnName="ReviewDate" />
              </MappingFragment>
            </EntityTypeMapping>
          </EntitySetMapping>
          <EntitySetMapping Name="CashWithdrawalStatus1">
            <EntityTypeMapping TypeName="BuddyFinance.Model.CashWithdrawalStatus">
              <MappingFragment StoreEntitySet="CashWithdrawalStatus">
                <ScalarProperty Name="Id" ColumnName="Id" />
                <ScalarProperty Name="Description" ColumnName="Description" />
              </MappingFragment>
            </EntityTypeMapping>
          </EntitySetMapping>
          <EntitySetMapping Name="Countries">
            <EntityTypeMapping TypeName="BuddyFinance.Model.Country">
              <MappingFragment StoreEntitySet="Country">
                <ScalarProperty Name="Id" ColumnName="Id" />
                <ScalarProperty Name="CountryCode" ColumnName="CountryCode" />
                <ScalarProperty Name="CountryName" ColumnName="CountryName" />
              </MappingFragment>
            </EntityTypeMapping>
          </EntitySetMapping>
          <EntitySetMapping Name="DocumentTypes">
            <EntityTypeMapping TypeName="BuddyFinance.Model.DocumentType">
              <MappingFragment StoreEntitySet="DocumentType">
                <ScalarProperty Name="Id" ColumnName="Id" />
                <ScalarProperty Name="Description" ColumnName="Description" />
              </MappingFragment>
            </EntityTypeMapping>
          </EntitySetMapping>
          <EntitySetMapping Name="EmploymentDetails">
            <EntityTypeMapping TypeName="BuddyFinance.Model.EmploymentDetail">
              <MappingFragment StoreEntitySet="EmploymentDetail">
                <ScalarProperty Name="BillingDay" ColumnName="BillingDay" />
                <ScalarProperty Name="ProfileId" ColumnName="ProfileId" />
                <ScalarProperty Name="EmploymentTypeId" ColumnName="EmploymentTypeId" />
                <ScalarProperty Name="EmployerName" ColumnName="EmployerName" />
                <ScalarProperty Name="EmployerContactNumber" ColumnName="EmployerContactNumber" />
                <ScalarProperty Name="EmploymentStartDate" ColumnName="EmploymentStartDate" />
                <ScalarProperty Name="EmploymentEndDate" ColumnName="EmploymentEndDate" />
                <ScalarProperty Name="GrossMonthlyIncome" ColumnName="GrossMonthlyIncome" />
                <ScalarProperty Name="NetMonthlyIncome" ColumnName="NetMonthlyIncome" />
                <ScalarProperty Name="EmployerNumber" ColumnName="EmployerNumber" />
                <ScalarProperty Name="SalaryDay" ColumnName="SalaryDay" />
              </MappingFragment>
            </EntityTypeMapping>
          </EntitySetMapping>
          <EntitySetMapping Name="EmploymentStatus1">
            <EntityTypeMapping TypeName="BuddyFinance.Model.EmploymentStatus">
              <MappingFragment StoreEntitySet="EmploymentStatus">
                <ScalarProperty Name="Id" ColumnName="Id" />
                <ScalarProperty Name="Description" ColumnName="Description" />
              </MappingFragment>
            </EntityTypeMapping>
          </EntitySetMapping>
          <EntitySetMapping Name="EmploymentTypes">
            <EntityTypeMapping TypeName="BuddyFinance.Model.EmploymentType">
              <MappingFragment StoreEntitySet="EmploymentType">
                <ScalarProperty Name="Id" ColumnName="Id" />
                <ScalarProperty Name="Description" ColumnName="Description" />
              </MappingFragment>
            </EntityTypeMapping>
          </EntitySetMapping>
          <EntitySetMapping Name="Ethnicities">
            <EntityTypeMapping TypeName="BuddyFinance.Model.Ethnicity">
              <MappingFragment StoreEntitySet="Ethnicity">
                <ScalarProperty Name="Id" ColumnName="Id" />
                <ScalarProperty Name="Description" ColumnName="Description" />
              </MappingFragment>
            </EntityTypeMapping>
          </EntitySetMapping>
          <EntitySetMapping Name="FicaCompliances">
            <EntityTypeMapping TypeName="BuddyFinance.Model.FicaCompliance">
              <MappingFragment StoreEntitySet="FicaCompliance">
                <ScalarProperty Name="ProfileId" ColumnName="ProfileId" />
                <ScalarProperty Name="FicaStatusId" ColumnName="FicaStatusId" />
                <ScalarProperty Name="VerificationDate" ColumnName="VerificationDate" />
              </MappingFragment>
            </EntityTypeMapping>
          </EntitySetMapping>
          <EntitySetMapping Name="FicaComplianceDocuments">
            <EntityTypeMapping TypeName="BuddyFinance.Model.FicaComplianceDocument">
              <MappingFragment StoreEntitySet="FicaComplianceDocuments">
                <ScalarProperty Name="Id" ColumnName="Id" />
                <ScalarProperty Name="FicaComplianceId" ColumnName="FicaComplianceId" />
                <ScalarProperty Name="DocumentTypeId" ColumnName="DocumentTypeId" />
                <ScalarProperty Name="FileId" ColumnName="FileId" />
              </MappingFragment>
            </EntityTypeMapping>
          </EntitySetMapping>
          <EntitySetMapping Name="FicaStatus1">
            <EntityTypeMapping TypeName="BuddyFinance.Model.FicaStatus">
              <MappingFragment StoreEntitySet="FicaStatus">
                <ScalarProperty Name="Id" ColumnName="Id" />
                <ScalarProperty Name="Description" ColumnName="Description" />
              </MappingFragment>
            </EntityTypeMapping>
          </EntitySetMapping>
          <EntitySetMapping Name="FileDatas">
            <EntityTypeMapping TypeName="BuddyFinance.Model.FileData">
              <MappingFragment StoreEntitySet="FileData">
                <ScalarProperty Name="Id" ColumnName="Id" />
                <ScalarProperty Name="FileName" ColumnName="FileName" />
                <ScalarProperty Name="Contents" ColumnName="Contents" />
                <ScalarProperty Name="Size" ColumnName="Size" />
                <ScalarProperty Name="ContentType" ColumnName="ContentType" />
                <ScalarProperty Name="FileUrl" ColumnName="FileUrl" />
              </MappingFragment>
            </EntityTypeMapping>
          </EntitySetMapping>
          <EntitySetMapping Name="Genders">
            <EntityTypeMapping TypeName="BuddyFinance.Model.Gender">
              <MappingFragment StoreEntitySet="Gender">
                <ScalarProperty Name="Id" ColumnName="Id" />
                <ScalarProperty Name="Description" ColumnName="Description" />
              </MappingFragment>
            </EntityTypeMapping>
          </EntitySetMapping>
          <EntitySetMapping Name="GlobalSetups">
            <EntityTypeMapping TypeName="BuddyFinance.Model.GlobalSetup">
              <MappingFragment StoreEntitySet="GlobalSetup">
                <ScalarProperty Name="Id" ColumnName="Id" />
                <ScalarProperty Name="InterestType" ColumnName="InterestType" />
                <ScalarProperty Name="ExpenseFactor" ColumnName="ExpenseFactor" />
                <ScalarProperty Name="ServiceFee" ColumnName="ServiceFee" />
                <ScalarProperty Name="TransUnionSecurityCode" ColumnName="TransUnionSecurityCode" />
                <ScalarProperty Name="TransUnionSubscriberCode" ColumnName="TransUnionSubscriberCode" />
              </MappingFragment>
            </EntityTypeMapping>
          </EntitySetMapping>
          <EntitySetMapping Name="IdentificationTypes">
            <EntityTypeMapping TypeName="BuddyFinance.Model.IdentificationType">
              <MappingFragment StoreEntitySet="IdentificationType">
                <ScalarProperty Name="Id" ColumnName="Id" />
                <ScalarProperty Name="Description" ColumnName="Description" />
              </MappingFragment>
            </EntityTypeMapping>
          </EntitySetMapping>
          <EntitySetMapping Name="LoanEarningBrackets">
            <EntityTypeMapping TypeName="BuddyFinance.Model.LoanEarningBracket">
              <MappingFragment StoreEntitySet="LoanEarningBracket">
                <ScalarProperty Name="Id" ColumnName="Id" />
                <ScalarProperty Name="MinAmount" ColumnName="MinAmount" />
                <ScalarProperty Name="MaxAmount" ColumnName="MaxAmount" />
                <ScalarProperty Name="QualifyingAmount" ColumnName="QualifyingAmount" />
              </MappingFragment>
            </EntityTypeMapping>
          </EntitySetMapping>
          <EntitySetMapping Name="LoanPayouts">
            <EntityTypeMapping TypeName="BuddyFinance.Model.LoanPayout">
              <MappingFragment StoreEntitySet="LoanPayout">
                <ScalarProperty Name="LoanId" ColumnName="LoanId" />
                <ScalarProperty Name="PayoutDate" ColumnName="PayoutDate" />
                <ScalarProperty Name="PayoutAmount" ColumnName="PayoutAmount" />
              </MappingFragment>
            </EntityTypeMapping>
          </EntitySetMapping>
          <EntitySetMapping Name="LoanRepayments">
            <EntityTypeMapping TypeName="BuddyFinance.Model.LoanRepayment">
              <MappingFragment StoreEntitySet="LoanRepayment">
                <ScalarProperty Name="Id" ColumnName="Id" />
                <ScalarProperty Name="LoanId" ColumnName="LoanId" />
                <ScalarProperty Name="PaymentAmount" ColumnName="PaymentAmount" />
                <ScalarProperty Name="PaymentDate" ColumnName="PaymentDate" />
                <ScalarProperty Name="PaymentMethod" ColumnName="PaymentMethod" />
                <ScalarProperty Name="LoanScheduleId" ColumnName="LoanScheduleId" />
                <ScalarProperty Name="LoanRepaymentStatusId" ColumnName="LoanRepaymentStatusId" />
              </MappingFragment>
            </EntityTypeMapping>
          </EntitySetMapping>
          <EntitySetMapping Name="LoanRepaymentStatus1">
            <EntityTypeMapping TypeName="BuddyFinance.Model.LoanRepaymentStatus">
              <MappingFragment StoreEntitySet="LoanRepaymentStatus">
                <ScalarProperty Name="Id" ColumnName="Id" />
                <ScalarProperty Name="Description" ColumnName="Description" />
              </MappingFragment>
            </EntityTypeMapping>
          </EntitySetMapping>
          <EntitySetMapping Name="LoanRequestScores">
            <EntityTypeMapping TypeName="BuddyFinance.Model.LoanRequestScore">
              <MappingFragment StoreEntitySet="LoanRequestScore">
                <ScalarProperty Name="Id" ColumnName="Id" />
              </MappingFragment>
            </EntityTypeMapping>
          </EntitySetMapping>
          <EntitySetMapping Name="LoanRequestStatus1">
            <EntityTypeMapping TypeName="BuddyFinance.Model.LoanRequestStatus">
              <MappingFragment StoreEntitySet="LoanRequestStatus">
                <ScalarProperty Name="Id" ColumnName="Id" />
                <ScalarProperty Name="Description" ColumnName="Description" />
              </MappingFragment>
            </EntityTypeMapping>
          </EntitySetMapping>
          <EntitySetMapping Name="LoanSchedules">
            <EntityTypeMapping TypeName="BuddyFinance.Model.LoanSchedule">
              <MappingFragment StoreEntitySet="LoanSchedule">
                <ScalarProperty Name="Id" ColumnName="Id" />
                <ScalarProperty Name="Description" ColumnName="Description" />
                <ScalarProperty Name="Amount" ColumnName="Amount" />
                <ScalarProperty Name="ExpectedPayDate" ColumnName="ExpectedPayDate" />
                <ScalarProperty Name="StatusId" ColumnName="StatusId" />
                <ScalarProperty Name="LoanId" ColumnName="LoanId" />
              </MappingFragment>
            </EntityTypeMapping>
          </EntitySetMapping>
          <EntitySetMapping Name="LoanScheduleFees">
            <EntityTypeMapping TypeName="BuddyFinance.Model.LoanScheduleFee">
              <MappingFragment StoreEntitySet="LoanScheduleFee">
                <ScalarProperty Name="LoanScheduleId" ColumnName="LoanScheduleId" />
                <ScalarProperty Name="BillDate" ColumnName="BillDate" />
                <ScalarProperty Name="TransactionFeeId" ColumnName="TransactionFeeId" />
              </MappingFragment>
            </EntityTypeMapping>
          </EntitySetMapping>
          <EntitySetMapping Name="LoanScheduleStatus1">
            <EntityTypeMapping TypeName="BuddyFinance.Model.LoanScheduleStatus">
              <MappingFragment StoreEntitySet="LoanScheduleStatus">
                <ScalarProperty Name="Id" ColumnName="Id" />
                <ScalarProperty Name="Description" ColumnName="Description" />
              </MappingFragment>
            </EntityTypeMapping>
          </EntitySetMapping>
          <EntitySetMapping Name="LoanStatus1">
            <EntityTypeMapping TypeName="BuddyFinance.Model.LoanStatus">
              <MappingFragment StoreEntitySet="LoanStatus">
                <ScalarProperty Name="Id" ColumnName="Id" />
                <ScalarProperty Name="Description" ColumnName="Description" />
              </MappingFragment>
            </EntityTypeMapping>
          </EntitySetMapping>
          <EntitySetMapping Name="LoanTermBrackets">
            <EntityTypeMapping TypeName="BuddyFinance.Model.LoanTermBracket">
              <MappingFragment StoreEntitySet="LoanTermBracket">
                <ScalarProperty Name="Id" ColumnName="Id" />
                <ScalarProperty Name="MinAmount" ColumnName="MinAmount" />
                <ScalarProperty Name="MaxAmount" ColumnName="MaxAmount" />
                <ScalarProperty Name="Duration" ColumnName="Duration" />
              </MappingFragment>
            </EntityTypeMapping>
          </EntitySetMapping>
          <EntitySetMapping Name="ManualDeductions">
            <EntityTypeMapping TypeName="BuddyFinance.Model.ManualDeduction">
              <MappingFragment StoreEntitySet="ManualDeduction">
                <ScalarProperty Name="Id" ColumnName="Id" />
                <ScalarProperty Name="Amount" ColumnName="Amount" />
                <ScalarProperty Name="Description" ColumnName="Description" />
                <ScalarProperty Name="DeductionDate" ColumnName="DeductionDate" />
                <ScalarProperty Name="ProfileId" ColumnName="ProfileId" />
                <ScalarProperty Name="UserId" ColumnName="UserId" />
              </MappingFragment>
            </EntityTypeMapping>
          </EntitySetMapping>
          <EntitySetMapping Name="NextOfKins">
            <EntityTypeMapping TypeName="BuddyFinance.Model.NextOfKin">
              <MappingFragment StoreEntitySet="NextOfKin">
                <ScalarProperty Name="ProfileId" ColumnName="ProfileId" />
                <ScalarProperty Name="Name" ColumnName="Name" />
                <ScalarProperty Name="RelationshipType" ColumnName="RelationshipType" />
                <ScalarProperty Name="ContactNumber" ColumnName="ContactNumber" />
                <ScalarProperty Name="Income" ColumnName="Income" />
              </MappingFragment>
            </EntityTypeMapping>
          </EntitySetMapping>
          <EntitySetMapping Name="Notifications">
            <EntityTypeMapping TypeName="BuddyFinance.Model.Notification">
              <MappingFragment StoreEntitySet="Notification">
                <ScalarProperty Name="Id" ColumnName="Id" />
                <ScalarProperty Name="Recipient" ColumnName="Recipient" />
                <ScalarProperty Name="Message" ColumnName="Message" />
                <ScalarProperty Name="Status" ColumnName="Status" />
                <ScalarProperty Name="NotificationTypeId" ColumnName="NotificationTypeId" />
                <ScalarProperty Name="DateSent" ColumnName="DateSent" />
              </MappingFragment>
            </EntityTypeMapping>
          </EntitySetMapping>
          <EntitySetMapping Name="NotificationTypes">
            <EntityTypeMapping TypeName="BuddyFinance.Model.NotificationType">
              <MappingFragment StoreEntitySet="NotificationType">
                <ScalarProperty Name="Id" ColumnName="Id" />
                <ScalarProperty Name="Description" ColumnName="Description" />
              </MappingFragment>
            </EntityTypeMapping>
          </EntitySetMapping>
          <EntitySetMapping Name="OfferStatus1">
            <EntityTypeMapping TypeName="BuddyFinance.Model.OfferStatus">
              <MappingFragment StoreEntitySet="OfferStatus">
                <ScalarProperty Name="Id" ColumnName="Id" />
                <ScalarProperty Name="Description" ColumnName="Description" />
              </MappingFragment>
            </EntityTypeMapping>
          </EntitySetMapping>
          <EntitySetMapping Name="PreLoanRequests">
            <EntityTypeMapping TypeName="BuddyFinance.Model.PreLoanRequest">
              <MappingFragment StoreEntitySet="PreLoanRequest">
                <ScalarProperty Name="Id" ColumnName="Id" />
                <ScalarProperty Name="RequestedDate" ColumnName="RequestedDate" />
                <ScalarProperty Name="BorrowerId" ColumnName="BorrowerId" />
                <ScalarProperty Name="Amount" ColumnName="Amount" />
                <ScalarProperty Name="Term" ColumnName="Term" />
                <ScalarProperty Name="TermTypeId" ColumnName="TermTypeId" />
                <ScalarProperty Name="FirstPaymentDate" ColumnName="FirstPaymentDate" />
                <ScalarProperty Name="ReferenceNumber" ColumnName="ReferenceNumber" />
                <ScalarProperty Name="LoanRequestStatusId" ColumnName="LoanRequestStatusId" />
              </MappingFragment>
            </EntityTypeMapping>
          </EntitySetMapping>
          <EntitySetMapping Name="ProfileApprovals">
            <EntityTypeMapping TypeName="BuddyFinance.Model.ProfileApproval">
              <MappingFragment StoreEntitySet="ProfileApproval">
                <ScalarProperty Name="ProfileId" ColumnName="ProfileId" />
                <ScalarProperty Name="ProfileStatusId" ColumnName="ProfileStatusId" />
                <ScalarProperty Name="RejectReason" ColumnName="RejectReason" />
                <ScalarProperty Name="ReviewDate" ColumnName="ReviewDate" />
                <ScalarProperty Name="ReviewerId" ColumnName="ReviewerId" />
              </MappingFragment>
            </EntityTypeMapping>
          </EntitySetMapping>
          <EntitySetMapping Name="ProfileCreditRatingScores">
            <EntityTypeMapping TypeName="BuddyFinance.Model.ProfileCreditRatingScore">
              <MappingFragment StoreEntitySet="ProfileCreditRatingScore">
                <ScalarProperty Name="Id" ColumnName="Id" />
                <ScalarProperty Name="ProfileId" ColumnName="ProfileId" />
                <ScalarProperty Name="BorrowerId" ColumnName="BorrowerId" />
                <ScalarProperty Name="LoanRequestOfferId" ColumnName="LoanRequestOfferId" />
                <ScalarProperty Name="CreditBureauScore" ColumnName="CreditBureauScore" />
                <ScalarProperty Name="DerivedScore" ColumnName="DerivedScore" />
                <ScalarProperty Name="CreditBureauRobotScoreId" ColumnName="CreditBureauRobotScoreId" />
                <ScalarProperty Name="DerivedRobotScoreId" ColumnName="DerivedRobotScoreId" />
                <ScalarProperty Name="ScoreDate" ColumnName="ScoreDate" />
                <ScalarProperty Name="Firstname" ColumnName="Firstname" />
                <ScalarProperty Name="Lastname" ColumnName="Lastname" />
              </MappingFragment>
            </EntityTypeMapping>
          </EntitySetMapping>
          <EntitySetMapping Name="ProfileDocuments">
            <EntityTypeMapping TypeName="BuddyFinance.Model.ProfileDocument">
              <MappingFragment StoreEntitySet="ProfileDocument">
                <ScalarProperty Name="Id" ColumnName="Id" />
                <ScalarProperty Name="FileId" ColumnName="FileId" />
                <ScalarProperty Name="UploadedDate" ColumnName="UploadedDate" />
                <ScalarProperty Name="DocumentTypeId" ColumnName="DocumentTypeId" />
                <ScalarProperty Name="ProfileId" ColumnName="ProfileId" />
                <ScalarProperty Name="IsDeleted" ColumnName="IsDeleted" />
              </MappingFragment>
            </EntityTypeMapping>
          </EntitySetMapping>
          <EntitySetMapping Name="ProfileStatus1">
            <EntityTypeMapping TypeName="BuddyFinance.Model.ProfileStatus">
              <MappingFragment StoreEntitySet="ProfileStatus">
                <ScalarProperty Name="Id" ColumnName="Id" />
                <ScalarProperty Name="Description" ColumnName="Description" />
              </MappingFragment>
            </EntityTypeMapping>
          </EntitySetMapping>
          <EntitySetMapping Name="ProfileSuspensions">
            <EntityTypeMapping TypeName="BuddyFinance.Model.ProfileSuspension">
              <MappingFragment StoreEntitySet="ProfileSuspension">
                <ScalarProperty Name="ProfileId" ColumnName="ProfileId" />
                <ScalarProperty Name="StartDate" ColumnName="StartDate" />
                <ScalarProperty Name="EndDate" ColumnName="EndDate" />
                <ScalarProperty Name="Reason" ColumnName="Reason" />
                <ScalarProperty Name="ReviewerId" ColumnName="ReviewerId" />
              </MappingFragment>
            </EntityTypeMapping>
          </EntitySetMapping>
          <EntitySetMapping Name="ProfileTypes">
            <EntityTypeMapping TypeName="BuddyFinance.Model.ProfileType">
              <MappingFragment StoreEntitySet="ProfileType">
                <ScalarProperty Name="Id" ColumnName="Id" />
                <ScalarProperty Name="Description" ColumnName="Description" />
              </MappingFragment>
            </EntityTypeMapping>
          </EntitySetMapping>
          <EntitySetMapping Name="Provinces">
            <EntityTypeMapping TypeName="BuddyFinance.Model.Province">
              <MappingFragment StoreEntitySet="Province">
                <ScalarProperty Name="Id" ColumnName="Id" />
                <ScalarProperty Name="Description" ColumnName="Description" />
              </MappingFragment>
            </EntityTypeMapping>
          </EntitySetMapping>
          <EntitySetMapping Name="RequestLogs">
            <EntityTypeMapping TypeName="BuddyFinance.Model.RequestLog">
              <MappingFragment StoreEntitySet="RequestLog">
                <ScalarProperty Name="Id" ColumnName="Id" />
                <ScalarProperty Name="RequestType" ColumnName="RequestType" />
                <ScalarProperty Name="Timestamp" ColumnName="Timestamp" />
                <ScalarProperty Name="RequestXML" ColumnName="RequestXML" />
                <ScalarProperty Name="ResponseCode" ColumnName="ResponseCode" />
                <ScalarProperty Name="ResponseMessage" ColumnName="ResponseMessage" />
                <ScalarProperty Name="ResponseXML" ColumnName="ResponseXML" />
              </MappingFragment>
            </EntityTypeMapping>
          </EntitySetMapping>
          <EntitySetMapping Name="RobotScores">
            <EntityTypeMapping TypeName="BuddyFinance.Model.RobotScore">
              <MappingFragment StoreEntitySet="RobotScore">
                <ScalarProperty Name="Id" ColumnName="Id" />
                <ScalarProperty Name="MinScore" ColumnName="MinScore" />
                <ScalarProperty Name="MaxScore" ColumnName="MaxScore" />
                <ScalarProperty Name="RobotColor" ColumnName="RobotColor" />
                <ScalarProperty Name="Description" ColumnName="Description" />
              </MappingFragment>
            </EntityTypeMapping>
          </EntitySetMapping>
          <EntitySetMapping Name="SourceOfFunds">
            <EntityTypeMapping TypeName="BuddyFinance.Model.SourceOfFund">
              <MappingFragment StoreEntitySet="SourceOfFunds">
                <ScalarProperty Name="Id" ColumnName="Id" />
                <ScalarProperty Name="Description" ColumnName="Description" />
              </MappingFragment>
            </EntityTypeMapping>
          </EntitySetMapping>
          <EntitySetMapping Name="SourceOfIncomes">
            <EntityTypeMapping TypeName="BuddyFinance.Model.SourceOfIncome">
              <MappingFragment StoreEntitySet="SourceOfIncome">
                <ScalarProperty Name="Id" ColumnName="Id" />
                <ScalarProperty Name="Description" ColumnName="Description" />
              </MappingFragment>
            </EntityTypeMapping>
          </EntitySetMapping>
          <EntitySetMapping Name="TaxIdentificationTypes">
            <EntityTypeMapping TypeName="BuddyFinance.Model.TaxIdentificationType">
              <MappingFragment StoreEntitySet="TaxIdentificationType">
                <ScalarProperty Name="Id" ColumnName="Id" />
                <ScalarProperty Name="Description" ColumnName="Description" />
              </MappingFragment>
            </EntityTypeMapping>
          </EntitySetMapping>
          <EntitySetMapping Name="TaxInformations">
            <EntityTypeMapping TypeName="BuddyFinance.Model.TaxInformation">
              <MappingFragment StoreEntitySet="TaxInformation">
                <ScalarProperty Name="ProfileId" ColumnName="ProfileId" />
                <ScalarProperty Name="TaxIdentificationTypeId" ColumnName="TaxIdentificationTypeId" />
                <ScalarProperty Name="TaxNumber" ColumnName="TaxNumber" />
                <ScalarProperty Name="TaxCountryId" ColumnName="TaxCountryId" />
              </MappingFragment>
            </EntityTypeMapping>
          </EntitySetMapping>
          <EntitySetMapping Name="TermTypes">
            <EntityTypeMapping TypeName="BuddyFinance.Model.TermType">
              <MappingFragment StoreEntitySet="TermType">
                <ScalarProperty Name="Id" ColumnName="Id" />
                <ScalarProperty Name="Description" ColumnName="Description" />
              </MappingFragment>
            </EntityTypeMapping>
          </EntitySetMapping>
          <EntitySetMapping Name="Transactions">
            <EntityTypeMapping TypeName="BuddyFinance.Model.Transaction">
              <MappingFragment StoreEntitySet="Transaction">
                <ScalarProperty Name="ProfileTypeId" ColumnName="ProfileTypeId" />
                <ScalarProperty Name="Id" ColumnName="Id" />
                <ScalarProperty Name="ProfileId" ColumnName="ProfileId" />
                <ScalarProperty Name="TransactionDate" ColumnName="TransactionDate" />
                <ScalarProperty Name="Description" ColumnName="Description" />
                <ScalarProperty Name="Reference" ColumnName="Reference" />
                <ScalarProperty Name="TransactionTypeId" ColumnName="TransactionTypeId" />
                <ScalarProperty Name="Amount" ColumnName="Amount" />
                <ScalarProperty Name="TransactionStatusId" ColumnName="TransactionStatusId" />
                <ScalarProperty Name="LoanId" ColumnName="LoanId" />
                <ScalarProperty Name="LoanRequestId" ColumnName="LoanRequestId" />
                <ScalarProperty Name="LoanRepaymentId" ColumnName="LoanRepaymentId" />
              </MappingFragment>
            </EntityTypeMapping>
          </EntitySetMapping>
          <EntitySetMapping Name="TransactionFees">
            <EntityTypeMapping TypeName="BuddyFinance.Model.TransactionFee">
              <MappingFragment StoreEntitySet="TransactionFee">
                <ScalarProperty Name="Id" ColumnName="Id" />
                <ScalarProperty Name="TransactionId" ColumnName="TransactionId" />
                <ScalarProperty Name="FeeTypeId" ColumnName="FeeTypeId" />
                <ScalarProperty Name="FeeAmount" ColumnName="FeeAmount" />
              </MappingFragment>
            </EntityTypeMapping>
          </EntitySetMapping>
          <EntitySetMapping Name="TransactionStatus1">
            <EntityTypeMapping TypeName="BuddyFinance.Model.TransactionStatus">
              <MappingFragment StoreEntitySet="TransactionStatus">
                <ScalarProperty Name="Id" ColumnName="Id" />
                <ScalarProperty Name="Description" ColumnName="Description" />
              </MappingFragment>
            </EntityTypeMapping>
          </EntitySetMapping>
          <EntitySetMapping Name="TransactionTypes">
            <EntityTypeMapping TypeName="BuddyFinance.Model.TransactionType">
              <MappingFragment StoreEntitySet="TransactionType">
                <ScalarProperty Name="Id" ColumnName="Id" />
                <ScalarProperty Name="Description" ColumnName="Description" />
              </MappingFragment>
            </EntityTypeMapping>
          </EntitySetMapping>
          <EntitySetMapping Name="Users">
            <EntityTypeMapping TypeName="BuddyFinance.Model.User">
              <MappingFragment StoreEntitySet="User">
                <ScalarProperty Name="Id" ColumnName="Id" />
                <ScalarProperty Name="UserName" ColumnName="UserName" />
                <ScalarProperty Name="Name" ColumnName="Name" />
                <ScalarProperty Name="Surname" ColumnName="Surname" />
                <ScalarProperty Name="MobileNumber" ColumnName="MobileNumber" />
                <ScalarProperty Name="Password" ColumnName="Password" />
                <ScalarProperty Name="PasswordHash" ColumnName="PasswordHash" />
                <ScalarProperty Name="SignUpDate" ColumnName="SignUpDate" />
                <ScalarProperty Name="LastLoginDate" ColumnName="LastLoginDate" />
                <ScalarProperty Name="MustChangePassword" ColumnName="MustChangePassword" />
                <ScalarProperty Name="ProfileId" ColumnName="ProfileId" />
                <ScalarProperty Name="RoleId" ColumnName="RoleId" />
                <ScalarProperty Name="IsActive" ColumnName="IsActive" />
                <ScalarProperty Name="AccountVerified" ColumnName="AccountVerified" />
              </MappingFragment>
            </EntityTypeMapping>
          </EntitySetMapping>
          <EntitySetMapping Name="UserRoles">
            <EntityTypeMapping TypeName="BuddyFinance.Model.UserRole">
              <MappingFragment StoreEntitySet="UserRole">
                <ScalarProperty Name="Id" ColumnName="Id" />
                <ScalarProperty Name="Name" ColumnName="Name" />
              </MappingFragment>
            </EntityTypeMapping>
          </EntitySetMapping>
          <FunctionImportMapping FunctionImportName="ProfileTransactions" FunctionName="BuddyFinance.Model.Store.ProfileTransactions">
            <ResultMapping>
              <ComplexTypeMapping TypeName="BuddyFinance.Model.ProfileTransactions_Result">
                <ScalarProperty Name="Id" ColumnName="Id" />
                <ScalarProperty Name="ProfileId" ColumnName="ProfileId" />
                <ScalarProperty Name="TransactionDate" ColumnName="TransactionDate" />
                <ScalarProperty Name="Description" ColumnName="Description" />
                <ScalarProperty Name="Reference" ColumnName="Reference" />
                <ScalarProperty Name="Type" ColumnName="Type" />
                <ScalarProperty Name="StatusType" ColumnName="StatusType" />
                <ScalarProperty Name="Amount" ColumnName="Amount" />
                <ScalarProperty Name="FeeTypeDescription" ColumnName="FeeTypeDescription" />
                <ScalarProperty Name="FeeAmount" ColumnName="FeeAmount" />
              </ComplexTypeMapping>
            </ResultMapping>
          </FunctionImportMapping>
          <EntitySetMapping Name="Loans">
            <EntityTypeMapping TypeName="BuddyFinance.Model.Loan">
              <MappingFragment StoreEntitySet="Loan">
                <ScalarProperty Name="LenderId" ColumnName="LenderId" />
                <ScalarProperty Name="BorrowerId" ColumnName="BorrowerId" />
                <ScalarProperty Name="RepayCompletedDate" ColumnName="RepayCompletedDate" />
                <ScalarProperty Name="Comment" ColumnName="Comment" />
                <ScalarProperty Name="TotalPayment" ColumnName="TotalPayment" />
                <ScalarProperty Name="MonthlyInstallmentAmount" ColumnName="MonthlyInstallmentAmount" />
                <ScalarProperty Name="DateAccepted" ColumnName="DateAccepted" />
                <ScalarProperty Name="InitialPaymentAmount" ColumnName="InitialPaymentAmount" />
                <ScalarProperty Name="CreatedDate" ColumnName="CreatedDate" />
                <ScalarProperty Name="LoanStatusId" ColumnName="LoanStatusId" />
                <ScalarProperty Name="TermTypeId" ColumnName="TermTypeId" />
                <ScalarProperty Name="LoanDuration" ColumnName="LoanDuration" />
                <ScalarProperty Name="FirstRepaymentDate" ColumnName="FirstRepaymentDate" />
                <ScalarProperty Name="LoanAmount" ColumnName="LoanAmount" />
                <ScalarProperty Name="LoanOfferId" ColumnName="LoanOfferId" />
                <ScalarProperty Name="LoanRequestId" ColumnName="LoanRequestId" />
                <ScalarProperty Name="Id" ColumnName="Id" />
              </MappingFragment>
            </EntityTypeMapping>
          </EntitySetMapping>
          <EntitySetMapping Name="LoanRequestOffers">
            <EntityTypeMapping TypeName="BuddyFinance.Model.LoanRequestOffer">
              <MappingFragment StoreEntitySet="LoanRequestOffer">
                <ScalarProperty Name="IOU_Accepted" ColumnName="IOU_Accepted" />
                <ScalarProperty Name="IsActive" ColumnName="IsActive" />
                <ScalarProperty Name="LoanRequestId" ColumnName="LoanRequestId" />
                <ScalarProperty Name="LoanOfferId" ColumnName="LoanOfferId" />
                <ScalarProperty Name="OfferStausId" ColumnName="OfferStausId" />
                <ScalarProperty Name="Comments" ColumnName="Comments" />
                <ScalarProperty Name="RequestDate" ColumnName="RequestDate" />
                <ScalarProperty Name="Id" ColumnName="Id" />
              </MappingFragment>
            </EntityTypeMapping>
          </EntitySetMapping>
          <EntitySetMapping Name="FeeTypes">
            <EntityTypeMapping TypeName="BuddyFinance.Model.FeeType">
              <MappingFragment StoreEntitySet="FeeType">
                <ScalarProperty Name="AmountForPercentUse" ColumnName="AmountForPercentUse" />
                <ScalarProperty Name="VatPercentage" ColumnName="VatPercentage" />
                <ScalarProperty Name="Percentage" ColumnName="Percentage" />
                <ScalarProperty Name="Amount" ColumnName="Amount" />
                <ScalarProperty Name="Basis" ColumnName="Basis" />
                <ScalarProperty Name="Description" ColumnName="Description" />
                <ScalarProperty Name="Id" ColumnName="Id" />
              </MappingFragment>
            </EntityTypeMapping>
          </EntitySetMapping>
          <EntitySetMapping Name="LoanOffers">
            <EntityTypeMapping TypeName="BuddyFinance.Model.LoanOffer">
              <MappingFragment StoreEntitySet="LoanOffer">
                <ScalarProperty Name="IsDeleted" ColumnName="IsDeleted" />
                <ScalarProperty Name="ExpiryDate" ColumnName="ExpiryDate" />
                <ScalarProperty Name="DateCreated" ColumnName="DateCreated" />
                <ScalarProperty Name="IsActive" ColumnName="IsActive" />
                <ScalarProperty Name="TermTypeId" ColumnName="TermTypeId" />
                <ScalarProperty Name="Term" ColumnName="Term" />
                <ScalarProperty Name="InterestRate" ColumnName="InterestRate" />
                <ScalarProperty Name="Balance" ColumnName="Balance" />
                <ScalarProperty Name="Amount" ColumnName="Amount" />
                <ScalarProperty Name="LenderId" ColumnName="LenderId" />
                <ScalarProperty Name="Id" ColumnName="Id" />
              </MappingFragment>
            </EntityTypeMapping>
          </EntitySetMapping>
          <EntitySetMapping Name="LoanRequests">
            <EntityTypeMapping TypeName="BuddyFinance.Model.LoanRequest">
              <MappingFragment StoreEntitySet="LoanRequest">
                <ScalarProperty Name="LoanRequestStatusId" ColumnName="LoanRequestStatusId" />
                <ScalarProperty Name="ReferenceNumber" ColumnName="ReferenceNumber" />
                <ScalarProperty Name="FirstPaymentDate" ColumnName="FirstPaymentDate" />
                <ScalarProperty Name="TermTypeId" ColumnName="TermTypeId" />
                <ScalarProperty Name="Term" ColumnName="Term" />
                <ScalarProperty Name="Amount" ColumnName="Amount" />
                <ScalarProperty Name="BorrowerId" ColumnName="BorrowerId" />
                <ScalarProperty Name="RequestedDate" ColumnName="RequestedDate" />
                <ScalarProperty Name="Id" ColumnName="Id" />
              </MappingFragment>
            </EntityTypeMapping>
          </EntitySetMapping>
          <EntitySetMapping Name="Borrowers">
            <EntityTypeMapping TypeName="BuddyFinance.Model.Borrower">
              <MappingFragment StoreEntitySet="Borrower">
                <ScalarProperty Name="StatusId" ColumnName="StatusId" />
                <ScalarProperty Name="ProfileTypeId" ColumnName="ProfileTypeId" />
                <ScalarProperty Name="BorrowerNumber" ColumnName="BorrowerNumber" />
                <ScalarProperty Name="Id" ColumnName="Id" />
              </MappingFragment>
            </EntityTypeMapping>
          </EntitySetMapping>
          <EntitySetMapping Name="Lenders">
            <EntityTypeMapping TypeName="BuddyFinance.Model.Lender">
              <MappingFragment StoreEntitySet="Lender">
                <ScalarProperty Name="StatusId" ColumnName="StatusId" />
                <ScalarProperty Name="ProfileTypeId" ColumnName="ProfileTypeId" />
                <ScalarProperty Name="LenderNumber" ColumnName="LenderNumber" />
                <ScalarProperty Name="Id" ColumnName="Id" />
              </MappingFragment>
            </EntityTypeMapping>
          </EntitySetMapping>
          <EntitySetMapping Name="Profiles">
            <EntityTypeMapping TypeName="BuddyFinance.Model.Profile">
              <MappingFragment StoreEntitySet="Profile">
                <ScalarProperty Name="BorrowServiceAccount" ColumnName="BorrowServiceAccount" />
                <ScalarProperty Name="LendServiceAccount" ColumnName="LendServiceAccount" />
                <ScalarProperty Name="LastBillDate" ColumnName="LastBillDate" />
                <ScalarProperty Name="BillingDate" ColumnName="BillingDate" />
                <ScalarProperty Name="StatusId" ColumnName="StatusId" />
                <ScalarProperty Name="EmploymentStatusId" ColumnName="EmploymentStatusId" />
                <ScalarProperty Name="OtherSourceOfIncome" ColumnName="OtherSourceOfIncome" />
                <ScalarProperty Name="SourceOfIncomeId" ColumnName="SourceOfIncomeId" />
                <ScalarProperty Name="TaxRegistered" ColumnName="TaxRegistered" />
                <ScalarProperty Name="CashWithdrawal" ColumnName="CashWithdrawal" />
                <ScalarProperty Name="CashDeposit" ColumnName="CashDeposit" />
                <ScalarProperty Name="AvailableFunds" ColumnName="AvailableFunds" />
                <ScalarProperty Name="IdentificationNumber" ColumnName="IdentificationNumber" />
                <ScalarProperty Name="IdentificationTypeId" ColumnName="IdentificationTypeId" />
                <ScalarProperty Name="EthnicityId" ColumnName="EthnicityId" />
                <ScalarProperty Name="CountryOfBirthId" ColumnName="CountryOfBirthId" />
                <ScalarProperty Name="GenderId" ColumnName="GenderId" />
                <ScalarProperty Name="DateOfBirth" ColumnName="DateOfBirth" />
                <ScalarProperty Name="ContactNumber" ColumnName="ContactNumber" />
                <ScalarProperty Name="EmailAddress" ColumnName="EmailAddress" />
                <ScalarProperty Name="Surname" ColumnName="Surname" />
                <ScalarProperty Name="Name" ColumnName="Name" />
                <ScalarProperty Name="Title" ColumnName="Title" />
                <ScalarProperty Name="ProfileNumber" ColumnName="ProfileNumber" />
                <ScalarProperty Name="Id" ColumnName="Id" />
              </MappingFragment>
            </EntityTypeMapping>
          </EntitySetMapping>
          <EntitySetMapping Name="ProfileAddresses">
            <EntityTypeMapping TypeName="BuddyFinance.Model.ProfileAddress">
              <MappingFragment StoreEntitySet="ProfileAddress">
                <ScalarProperty Name="IsDeleted" ColumnName="IsDeleted" />
                <ScalarProperty Name="CountryId" ColumnName="CountryId" />
                <ScalarProperty Name="ProvinceId" ColumnName="ProvinceId" />
                <ScalarProperty Name="PostalCode" ColumnName="PostalCode" />
                <ScalarProperty Name="City" ColumnName="City" />
                <ScalarProperty Name="Line2" ColumnName="Line2" />
                <ScalarProperty Name="Line1" ColumnName="Line1" />
                <ScalarProperty Name="AddressTypeId" ColumnName="AddressTypeId" />
                <ScalarProperty Name="ProfileId" ColumnName="ProfileId" />
                <ScalarProperty Name="Id" ColumnName="Id" />
              </MappingFragment>
            </EntityTypeMapping>
          </EntitySetMapping>
        </EntityContainerMapping>
      </Mapping>
    </edmx:Mappings>
  </edmx:Runtime>
  <!-- EF Designer content (DO NOT EDIT MANUALLY BELOW HERE) -->
  <Designer xmlns="http://schemas.microsoft.com/ado/2009/11/edmx">
    <Connection>
      <DesignerInfoPropertySet>
        <DesignerProperty Name="MetadataArtifactProcessing" Value="EmbedInOutputAssembly" />
      </DesignerInfoPropertySet>
    </Connection>
    <Options>
      <DesignerInfoPropertySet>
        <DesignerProperty Name="ValidateOnBuild" Value="true" />
        <DesignerProperty Name="EnablePluralization" Value="true" />
        <DesignerProperty Name="IncludeForeignKeysInModel" Value="true" />
        <DesignerProperty Name="UseLegacyProvider" Value="false" />
        <DesignerProperty Name="CodeGenerationStrategy" Value="None" />
      </DesignerInfoPropertySet>
    </Options>
    <!-- Diagram content (shape and connector positions) -->
    <Diagrams></Diagrams>
  </Designer>
</edmx:Edmx>