<?xml version="1.0" encoding="utf-8"?>
<Schema Namespace="NikaiDSRModel.Store" Alias="Self" Provider="System.Data.SqlClient" ProviderManifestToken="2008" xmlns:store="http://schemas.microsoft.com/ado/2007/12/edm/EntityStoreSchemaGenerator" xmlns="http://schemas.microsoft.com/ado/2009/02/edm/ssdl">
  <EntityContainer Name="NikaiDSRModelStoreContainer">
    <EntitySet Name="Absent" EntityType="NikaiDSRModel.Store.Absent" store:Type="Tables" Schema="dbo" />
    <EntitySet Name="Contact" EntityType="NikaiDSRModel.Store.Contact" store:Type="Tables" Schema="dbo" />
    <EntitySet Name="Country" EntityType="NikaiDSRModel.Store.Country" store:Type="Tables" Schema="dbo" />
    <EntitySet Name="Customer" EntityType="NikaiDSRModel.Store.Customer" store:Type="Tables" Schema="dbo" />
    <EntitySet Name="DSR" EntityType="NikaiDSRModel.Store.DSR" store:Type="Tables" Schema="dbo" />
    <EntitySet Name="DSR_Header" EntityType="NikaiDSRModel.Store.DSR_Header" store:Type="Tables" Schema="dbo" />
    <EntitySet Name="Holiday" EntityType="NikaiDSRModel.Store.Holiday" store:Type="Tables" Schema="dbo" />
    <EntitySet Name="Location" EntityType="NikaiDSRModel.Store.Location" store:Type="Tables" Schema="dbo" />
    <EntitySet Name="Manager_Executive" EntityType="NikaiDSRModel.Store.Manager_Executive" store:Type="Tables" Schema="dbo" />
    <EntitySet Name="Menu" EntityType="NikaiDSRModel.Store.Menu" store:Type="Tables" Schema="dbo" />
    <EntitySet Name="MenuAccess" EntityType="NikaiDSRModel.Store.MenuAccess" store:Type="Tables" Schema="dbo" />
    <EntitySet Name="MenuRolePages" EntityType="NikaiDSRModel.Store.MenuRolePages" store:Type="Tables" Schema="dbo" />
    <EntitySet Name="Parameter" EntityType="NikaiDSRModel.Store.Parameter" store:Type="Tables" Schema="dbo" />
    <EntitySet Name="ParameterDet" EntityType="NikaiDSRModel.Store.ParameterDet" store:Type="Tables" Schema="dbo" />
    <EntitySet Name="Region" EntityType="NikaiDSRModel.Store.Region" store:Type="Tables" Schema="dbo" />
    <EntitySet Name="Role" EntityType="NikaiDSRModel.Store.Role" store:Type="Tables" Schema="dbo" />
    <EntitySet Name="RoleRights" EntityType="NikaiDSRModel.Store.RoleRights" store:Type="Tables" Schema="dbo" />
    <EntitySet Name="Site_User" EntityType="NikaiDSRModel.Store.Site_User" store:Type="Tables" Schema="dbo" />
    <EntitySet Name="sysdiagrams" EntityType="NikaiDSRModel.Store.sysdiagrams" store:Type="Tables" Schema="dbo" />
    <EntitySet Name="Target" EntityType="NikaiDSRModel.Store.Target" store:Type="Tables" Schema="dbo" />
    <EntitySet Name="User_Language" EntityType="NikaiDSRModel.Store.User_Language" store:Type="Tables" Schema="dbo" />
    <EntitySet Name="ActiveContactCustomerLocationView" EntityType="NikaiDSRModel.Store.ActiveContactCustomerLocationView" store:Type="Views" store:Schema="dbo" store:Name="ActiveContactCustomerLocationView">
      <DefiningQuery>SELECT 
      [ActiveContactCustomerLocationView].[Contact_Id] AS [Contact_Id], 
      [ActiveContactCustomerLocationView].[Contact_Name] AS [Contact_Name], 
      [ActiveContactCustomerLocationView].[Department] AS [Department], 
      [ActiveContactCustomerLocationView].[Contact_Status] AS [Contact_Status], 
      [ActiveContactCustomerLocationView].[Customer_Id] AS [Customer_Id], 
      [ActiveContactCustomerLocationView].[Customer_Name] AS [Customer_Name], 
      [ActiveContactCustomerLocationView].[Key_Account] AS [Key_Account], 
      [ActiveContactCustomerLocationView].[Customer_Status] AS [Customer_Status], 
      [ActiveContactCustomerLocationView].[Location_Id] AS [Location_Id], 
      [ActiveContactCustomerLocationView].[Location_Name] AS [Location_Name], 
      [ActiveContactCustomerLocationView].[Site_User_Id] AS [Site_User_Id], 
      [ActiveContactCustomerLocationView].[Customer_Name_BL] AS [Customer_Name_BL], 
      [ActiveContactCustomerLocationView].[Contact_Name_BL] AS [Contact_Name_BL], 
      [ActiveContactCustomerLocationView].[Updated_By] AS [Updated_By], 
      [ActiveContactCustomerLocationView].[Updated_Date] AS [Updated_Date], 
      [ActiveContactCustomerLocationView].[Customer_Code] AS [Customer_Code], 
      [ActiveContactCustomerLocationView].[Business_Type] AS [Business_Type], 
      [ActiveContactCustomerLocationView].[Customer_Type] AS [Customer_Type], 
      [ActiveContactCustomerLocationView].[Customer_Group] AS [Customer_Group], 
      [ActiveContactCustomerLocationView].[Department_BL] AS [Department_BL], 
      [ActiveContactCustomerLocationView].[Mobile] AS [Mobile]
      FROM [dbo].[ActiveContactCustomerLocationView] AS [ActiveContactCustomerLocationView]</DefiningQuery>
    </EntitySet>
    <EntitySet Name="ActiveCustomerLocationRegionCountryView" EntityType="NikaiDSRModel.Store.ActiveCustomerLocationRegionCountryView" store:Type="Views" store:Schema="dbo" store:Name="ActiveCustomerLocationRegionCountryView">
      <DefiningQuery>SELECT 
      [ActiveCustomerLocationRegionCountryView].[Customer_Id] AS [Customer_Id], 
      [ActiveCustomerLocationRegionCountryView].[Customer_Name] AS [Customer_Name], 
      [ActiveCustomerLocationRegionCountryView].[Key_Account] AS [Key_Account], 
      [ActiveCustomerLocationRegionCountryView].[Customer_Status] AS [Customer_Status], 
      [ActiveCustomerLocationRegionCountryView].[Location_Id] AS [Location_Id], 
      [ActiveCustomerLocationRegionCountryView].[Location_Name] AS [Location_Name], 
      [ActiveCustomerLocationRegionCountryView].[Customer_Name_BL] AS [Customer_Name_BL], 
      [ActiveCustomerLocationRegionCountryView].[Updated_By] AS [Updated_By], 
      [ActiveCustomerLocationRegionCountryView].[Updated_Date] AS [Updated_Date], 
      [ActiveCustomerLocationRegionCountryView].[Customer_Code] AS [Customer_Code], 
      [ActiveCustomerLocationRegionCountryView].[Business_Type] AS [Business_Type], 
      [ActiveCustomerLocationRegionCountryView].[Customer_Type] AS [Customer_Type], 
      [ActiveCustomerLocationRegionCountryView].[Customer_Group] AS [Customer_Group], 
      [ActiveCustomerLocationRegionCountryView].[Country_Name] AS [Country_Name], 
      [ActiveCustomerLocationRegionCountryView].[Region_Name] AS [Region_Name]
      FROM [dbo].[ActiveCustomerLocationRegionCountryView] AS [ActiveCustomerLocationRegionCountryView]</DefiningQuery>
    </EntitySet>
    <EntitySet Name="DsrContactCustomerLocationView" EntityType="NikaiDSRModel.Store.DsrContactCustomerLocationView" store:Type="Views" store:Schema="dbo" store:Name="DsrContactCustomerLocationView">
      <DefiningQuery>SELECT 
      [DsrContactCustomerLocationView].[Site_User_Id] AS [Site_User_Id], 
      [DsrContactCustomerLocationView].[DSR_Id] AS [DSR_Id], 
      [DsrContactCustomerLocationView].[Contact_Id] AS [Contact_Id], 
      [DsrContactCustomerLocationView].[Contact_Name] AS [Contact_Name], 
      [DsrContactCustomerLocationView].[Date] AS [Date], 
      [DsrContactCustomerLocationView].[Customer_Id] AS [Customer_Id], 
      [DsrContactCustomerLocationView].[Contact_Status] AS [Contact_Status], 
      [DsrContactCustomerLocationView].[Customer_Name] AS [Customer_Name], 
      [DsrContactCustomerLocationView].[Location_Id] AS [Location_Id], 
      [DsrContactCustomerLocationView].[Customer_Status] AS [Customer_Status], 
      [DsrContactCustomerLocationView].[Location_Name] AS [Location_Name], 
      [DsrContactCustomerLocationView].[Customer_Name_BL] AS [Customer_Name_BL], 
      [DsrContactCustomerLocationView].[Contact_Name_BL] AS [Contact_Name_BL], 
      [DsrContactCustomerLocationView].[Updated_By] AS [Updated_By], 
      [DsrContactCustomerLocationView].[Updated_Date] AS [Updated_Date], 
      [DsrContactCustomerLocationView].[Location_Name_BL] AS [Location_Name_BL]
      FROM [dbo].[DsrContactCustomerLocationView] AS [DsrContactCustomerLocationView]</DefiningQuery>
    </EntitySet>
    <EntitySet Name="DSRReportView" EntityType="NikaiDSRModel.Store.DSRReportView" store:Type="Views" store:Schema="dbo" store:Name="DSRReportView">
      <DefiningQuery>SELECT 
      [DSRReportView].[Site_User_Id] AS [Site_User_Id], 
      [DSRReportView].[Date] AS [Date], 
      [DSRReportView].[Customer_Id] AS [Customer_Id], 
      [DSRReportView].[Customer_Code] AS [Customer_Code], 
      [DSRReportView].[Customer_Name] AS [Customer_Name], 
      [DSRReportView].[Customer_Name_BL] AS [Customer_Name_BL], 
      [DSRReportView].[Contact_Id] AS [Contact_Id], 
      [DSRReportView].[Contact_Name] AS [Contact_Name], 
      [DSRReportView].[Contact_Name_BL] AS [Contact_Name_BL], 
      [DSRReportView].[Department_BL] AS [Department_BL], 
      [DSRReportView].[Department] AS [Department], 
      [DSRReportView].[Mobile] AS [Mobile], 
      [DSRReportView].[Status_Contact] AS [Status_Contact], 
      [DSRReportView].[Objective] AS [Objective], 
      [DSRReportView].[Time_In] AS [Time_In], 
      [DSRReportView].[Time_Out] AS [Time_Out], 
      [DSRReportView].[Time_Spent] AS [Time_Spent], 
      [DSRReportView].[Time_w_Merchandiser] AS [Time_w_Merchandiser], 
      [DSRReportView].[Collection] AS [Collection], 
      [DSRReportView].[Secondary_Sales] AS [Secondary_Sales], 
      [DSRReportView].[Sales_LPO_Received] AS [Sales_LPO_Received], 
      [DSRReportView].[Discount] AS [Discount], 
      [DSRReportView].[Sales_Return] AS [Sales_Return], 
      [DSRReportView].[Remarks] AS [Remarks], 
      [DSRReportView].[Status_Customer] AS [Status_Customer]
      FROM [dbo].[DSRReportView] AS [DSRReportView]</DefiningQuery>
    </EntitySet>
    <EntitySet Name="UserRoleLocationRegionCountryView" EntityType="NikaiDSRModel.Store.UserRoleLocationRegionCountryView" store:Type="Views" store:Schema="dbo" store:Name="UserRoleLocationRegionCountryView">
      <DefiningQuery>SELECT 
      [UserRoleLocationRegionCountryView].[Site_User_Id] AS [Site_User_Id], 
      [UserRoleLocationRegionCountryView].[Name] AS [Name], 
      [UserRoleLocationRegionCountryView].[Email] AS [Email], 
      [UserRoleLocationRegionCountryView].[Status] AS [Status], 
      [UserRoleLocationRegionCountryView].[Role_Id] AS [Role_Id], 
      [UserRoleLocationRegionCountryView].[Role_Name] AS [Role_Name], 
      [UserRoleLocationRegionCountryView].[Location_Id] AS [Location_Id], 
      [UserRoleLocationRegionCountryView].[Location_Name] AS [Location_Name], 
      [UserRoleLocationRegionCountryView].[Region_Id] AS [Region_Id], 
      [UserRoleLocationRegionCountryView].[Region_Name] AS [Region_Name], 
      [UserRoleLocationRegionCountryView].[Country_Id] AS [Country_Id], 
      [UserRoleLocationRegionCountryView].[Country_Name] AS [Country_Name]
      FROM [dbo].[UserRoleLocationRegionCountryView] AS [UserRoleLocationRegionCountryView]</DefiningQuery>
    </EntitySet>
    <AssociationSet Name="FK_Absent_Site_User" Association="NikaiDSRModel.Store.FK_Absent_Site_User">
      <End Role="Site_User" EntitySet="Site_User" />
      <End Role="Absent" EntitySet="Absent" />
    </AssociationSet>
    <AssociationSet Name="FK_Contact_Customer" Association="NikaiDSRModel.Store.FK_Contact_Customer">
      <End Role="Customer" EntitySet="Customer" />
      <End Role="Contact" EntitySet="Contact" />
    </AssociationSet>
    <AssociationSet Name="FK_Customer_Location" Association="NikaiDSRModel.Store.FK_Customer_Location">
      <End Role="Location" EntitySet="Location" />
      <End Role="Customer" EntitySet="Customer" />
    </AssociationSet>
    <AssociationSet Name="FK_Customer_ParameterDet" Association="NikaiDSRModel.Store.FK_Customer_ParameterDet">
      <End Role="ParameterDet" EntitySet="ParameterDet" />
      <End Role="Customer" EntitySet="Customer" />
    </AssociationSet>
    <AssociationSet Name="FK_Customer_ParameterDet1" Association="NikaiDSRModel.Store.FK_Customer_ParameterDet1">
      <End Role="ParameterDet" EntitySet="ParameterDet" />
      <End Role="Customer" EntitySet="Customer" />
    </AssociationSet>
    <AssociationSet Name="FK_Customer_ParameterDet2" Association="NikaiDSRModel.Store.FK_Customer_ParameterDet2">
      <End Role="ParameterDet" EntitySet="ParameterDet" />
      <End Role="Customer" EntitySet="Customer" />
    </AssociationSet>
    <AssociationSet Name="FK_Customer_ParameterDet3" Association="NikaiDSRModel.Store.FK_Customer_ParameterDet3">
      <End Role="ParameterDet" EntitySet="ParameterDet" />
      <End Role="Customer" EntitySet="Customer" />
    </AssociationSet>
    <AssociationSet Name="FK_Customer_Site_User" Association="NikaiDSRModel.Store.FK_Customer_Site_User">
      <End Role="Site_User" EntitySet="Site_User" />
      <End Role="Customer" EntitySet="Customer" />
    </AssociationSet>
    <AssociationSet Name="FK_DSR_Contact" Association="NikaiDSRModel.Store.FK_DSR_Contact">
      <End Role="Contact" EntitySet="Contact" />
      <End Role="DSR" EntitySet="DSR" />
    </AssociationSet>
    <AssociationSet Name="FK_DSR_DSR_Header" Association="NikaiDSRModel.Store.FK_DSR_DSR_Header">
      <End Role="Site_User" EntitySet="Site_User" />
      <End Role="DSR" EntitySet="DSR" />
    </AssociationSet>
    <AssociationSet Name="FK_Holiday_Country" Association="NikaiDSRModel.Store.FK_Holiday_Country">
      <End Role="Country" EntitySet="Country" />
      <End Role="Holiday" EntitySet="Holiday" />
    </AssociationSet>
    <AssociationSet Name="FK_Holiday_ParameterDet" Association="NikaiDSRModel.Store.FK_Holiday_ParameterDet">
      <End Role="ParameterDet" EntitySet="ParameterDet" />
      <End Role="Holiday" EntitySet="Holiday" />
    </AssociationSet>
    <AssociationSet Name="FK_Location_Region" Association="NikaiDSRModel.Store.FK_Location_Region">
      <End Role="Region" EntitySet="Region" />
      <End Role="Location" EntitySet="Location" />
    </AssociationSet>
    <AssociationSet Name="FK_Manager_Executive_Site_User" Association="NikaiDSRModel.Store.FK_Manager_Executive_Site_User">
      <End Role="Site_User" EntitySet="Site_User" />
      <End Role="Manager_Executive" EntitySet="Manager_Executive" />
    </AssociationSet>
    <AssociationSet Name="FK_Menu_ParameterDet" Association="NikaiDSRModel.Store.FK_Menu_ParameterDet">
      <End Role="ParameterDet" EntitySet="ParameterDet" />
      <End Role="Menu" EntitySet="Menu" />
    </AssociationSet>
    <AssociationSet Name="FK_MenuAccess_Menu" Association="NikaiDSRModel.Store.FK_MenuAccess_Menu">
      <End Role="Menu" EntitySet="Menu" />
      <End Role="MenuAccess" EntitySet="MenuAccess" />
    </AssociationSet>
    <AssociationSet Name="FK_MenuAccess_ParameterDet" Association="NikaiDSRModel.Store.FK_MenuAccess_ParameterDet">
      <End Role="ParameterDet" EntitySet="ParameterDet" />
      <End Role="MenuAccess" EntitySet="MenuAccess" />
    </AssociationSet>
    <AssociationSet Name="FK_MenuRolePages_Menu" Association="NikaiDSRModel.Store.FK_MenuRolePages_Menu">
      <End Role="Menu" EntitySet="Menu" />
      <End Role="MenuRolePages" EntitySet="MenuRolePages" />
    </AssociationSet>
    <AssociationSet Name="FK_MenuRolePages_ParameterDet" Association="NikaiDSRModel.Store.FK_MenuRolePages_ParameterDet">
      <End Role="Role" EntitySet="Role" />
      <End Role="MenuRolePages" EntitySet="MenuRolePages" />
    </AssociationSet>
    <AssociationSet Name="FK_ParameterDet_Parameter" Association="NikaiDSRModel.Store.FK_ParameterDet_Parameter">
      <End Role="Parameter" EntitySet="Parameter" />
      <End Role="ParameterDet" EntitySet="ParameterDet" />
    </AssociationSet>
    <AssociationSet Name="FK_Region_Country" Association="NikaiDSRModel.Store.FK_Region_Country">
      <End Role="Country" EntitySet="Country" />
      <End Role="Region" EntitySet="Region" />
    </AssociationSet>
    <AssociationSet Name="FK_RoleRights_Menu" Association="NikaiDSRModel.Store.FK_RoleRights_Menu">
      <End Role="Menu" EntitySet="Menu" />
      <End Role="RoleRights" EntitySet="RoleRights" />
    </AssociationSet>
    <AssociationSet Name="FK_RoleRights_ParameterDet" Association="NikaiDSRModel.Store.FK_RoleRights_ParameterDet">
      <End Role="Role" EntitySet="Role" />
      <End Role="RoleRights" EntitySet="RoleRights" />
    </AssociationSet>
    <AssociationSet Name="FK_RoleRights_ParameterDet1" Association="NikaiDSRModel.Store.FK_RoleRights_ParameterDet1">
      <End Role="ParameterDet" EntitySet="ParameterDet" />
      <End Role="RoleRights" EntitySet="RoleRights" />
    </AssociationSet>
    <AssociationSet Name="FK_Site_User_Location" Association="NikaiDSRModel.Store.FK_Site_User_Location">
      <End Role="Location" EntitySet="Location" />
      <End Role="Site_User" EntitySet="Site_User" />
    </AssociationSet>
    <AssociationSet Name="FK_Site_User_Role" Association="NikaiDSRModel.Store.FK_Site_User_Role">
      <End Role="Role" EntitySet="Role" />
      <End Role="Site_User" EntitySet="Site_User" />
    </AssociationSet>
    <AssociationSet Name="FK_Target_Site_User" Association="NikaiDSRModel.Store.FK_Target_Site_User">
      <End Role="Site_User" EntitySet="Site_User" />
      <End Role="Target" EntitySet="Target" />
    </AssociationSet>
    <AssociationSet Name="FK_User_Language_ParameterDet" Association="NikaiDSRModel.Store.FK_User_Language_ParameterDet">
      <End Role="ParameterDet" EntitySet="ParameterDet" />
      <End Role="User_Language" EntitySet="User_Language" />
    </AssociationSet>
    <AssociationSet Name="FK_User_Language_Site_User" Association="NikaiDSRModel.Store.FK_User_Language_Site_User">
      <End Role="Site_User" EntitySet="Site_User" />
      <End Role="User_Language" EntitySet="User_Language" />
    </AssociationSet>
  </EntityContainer>
  <EntityType Name="Absent">
    <Key>
      <PropertyRef Name="Absent_Id" />
    </Key>
    <Property Name="Absent_Id" Type="int" Nullable="false" StoreGeneratedPattern="Identity" />
    <Property Name="Date" Type="date" Nullable="false" />
    <Property Name="Site_User_Id" Type="int" Nullable="false" />
  </EntityType>
  <EntityType Name="Contact">
    <Key>
      <PropertyRef Name="Contact_Id" />
    </Key>
    <Property Name="Contact_Id" Type="int" Nullable="false" StoreGeneratedPattern="Identity" />
    <Property Name="Contact_Name" Type="nvarchar" MaxLength="50" />
    <Property Name="Contact_Name_BL" Type="nvarchar" MaxLength="50" />
    <Property Name="Customer_Id" Type="int" Nullable="false" />
    <Property Name="Department" Type="nvarchar" MaxLength="50" />
    <Property Name="Department_BL" Type="nvarchar" MaxLength="50" />
    <Property Name="Mobile" Type="nvarchar" MaxLength="50" />
    <Property Name="Status" Type="bit" Nullable="false" />
  </EntityType>
  <EntityType Name="Country">
    <Key>
      <PropertyRef Name="Country_Id" />
    </Key>
    <Property Name="Country_Id" Type="int" Nullable="false" StoreGeneratedPattern="Identity" />
    <Property Name="Country_Name" Type="nvarchar" Nullable="false" MaxLength="50" />
  </EntityType>
  <EntityType Name="Customer">
    <Key>
      <PropertyRef Name="Customer_Id" />
    </Key>
    <Property Name="Customer_Id" Type="int" Nullable="false" StoreGeneratedPattern="Identity" />
    <Property Name="Customer_Code" Type="nvarchar" MaxLength="50" />
    <Property Name="Customer_Name" Type="nvarchar" MaxLength="50" />
    <Property Name="Customer_Name_BL" Type="nvarchar" MaxLength="50" />
    <Property Name="Business_Type" Type="int" />
    <Property Name="Customer_Type" Type="int" />
    <Property Name="Customer_Group" Type="int" />
    <Property Name="Location_Id" Type="int" />
    <Property Name="Key_Account" Type="bit" />
    <Property Name="Status" Type="bit" Nullable="false" />
    <Property Name="Updated_By" Type="int" Nullable="false" />
    <Property Name="Updated_Date" Type="date" Nullable="false" />
    <Property Name="Sales_Channel" Type="int" />
  </EntityType>
  <EntityType Name="DSR">
    <Key>
      <PropertyRef Name="DSR_Id" />
    </Key>
    <Property Name="DSR_Id" Type="int" Nullable="false" StoreGeneratedPattern="Identity" />
    <Property Name="Site_User_Id" Type="int" Nullable="false" />
    <Property Name="Date" Type="date" Nullable="false" />
    <Property Name="Contact_Id" Type="int" Nullable="false" />
    <Property Name="Objective" Type="nvarchar" MaxLength="50" />
    <Property Name="Time_In" Type="time" />
    <Property Name="Time_Out" Type="time" />
    <Property Name="Time_Spent" Type="int" />
    <Property Name="Time_w_Merchandiser" Type="int" />
    <Property Name="Collection" Type="int" />
    <Property Name="Secondary_Sales" Type="int" />
    <Property Name="Sales_LPO_Received" Type="int" />
    <Property Name="Discount" Type="int" />
    <Property Name="Sales_Return" Type="int" />
    <Property Name="Remarks" Type="nvarchar" MaxLength="50" />
  </EntityType>
  <EntityType Name="DSR_Header">
    <Key>
      <PropertyRef Name="DSR_Head_Id" />
    </Key>
    <Property Name="DSR_Head_Id" Type="int" Nullable="false" StoreGeneratedPattern="Identity" />
    <Property Name="Date" Type="date" Nullable="false" />
    <Property Name="Shift" Type="nvarchar" MaxLength="50" />
    <Property Name="Morning_Time_In" Type="time" />
    <Property Name="Morning_Time_Out" Type="time" />
    <Property Name="Evening_Time_In" Type="time" />
    <Property Name="Evening_Time_Out" Type="time" />
    <Property Name="Comments" Type="nvarchar" MaxLength="50" />
    <Property Name="Site_User_Id" Type="int" Nullable="false" />
  </EntityType>
  <EntityType Name="Holiday">
    <Key>
      <PropertyRef Name="Holiday_Id" />
    </Key>
    <Property Name="Holiday_Id" Type="int" Nullable="false" StoreGeneratedPattern="Identity" />
    <Property Name="Date" Type="date" Nullable="false" />
    <Property Name="Country_Id" Type="int" Nullable="false" />
    <Property Name="Holiday_Type" Type="int" Nullable="false" />
  </EntityType>
  <EntityType Name="Location">
    <Key>
      <PropertyRef Name="Location_Id" />
    </Key>
    <Property Name="Location_Id" Type="int" Nullable="false" StoreGeneratedPattern="Identity" />
    <Property Name="Location_Name" Type="nvarchar" MaxLength="50" />
    <Property Name="Location_Name_BL" Type="nvarchar" MaxLength="50" />
    <Property Name="Region_Id" Type="int" Nullable="false" />
  </EntityType>
  <EntityType Name="Manager_Executive">
    <Key>
      <PropertyRef Name="Manager_Exec_Id" />
    </Key>
    <Property Name="Manager_Exec_Id" Type="int" Nullable="false" StoreGeneratedPattern="Identity" />
    <Property Name="Executive_Id" Type="int" Nullable="false" />
    <Property Name="Manager_Id" Type="int" Nullable="false" />
  </EntityType>
  <EntityType Name="Menu">
    <Key>
      <PropertyRef Name="MenuId" />
    </Key>
    <Property Name="MenuId" Type="int" Nullable="false" />
    <Property Name="MenuName" Type="nvarchar" Nullable="false" MaxLength="100" />
    <Property Name="MenuParentId" Type="int" />
    <Property Name="MenuStatus" Type="int" Nullable="false" />
    <Property Name="MenuOrder" Type="int" Nullable="false" />
  </EntityType>
  <EntityType Name="MenuAccess">
    <Key>
      <PropertyRef Name="MenuAccessId" />
    </Key>
    <Property Name="MenuAccessId" Type="int" Nullable="false" StoreGeneratedPattern="Identity" />
    <Property Name="MenuId" Type="int" Nullable="false" />
    <Property Name="AccessType" Type="int" Nullable="false" />
  </EntityType>
  <EntityType Name="MenuRolePages">
    <Key>
      <PropertyRef Name="MenuRoleId" />
    </Key>
    <Property Name="MenuRoleId" Type="int" Nullable="false" StoreGeneratedPattern="Identity" />
    <Property Name="MenuId" Type="int" Nullable="false" />
    <Property Name="RoleId" Type="int" Nullable="false" />
    <Property Name="PageUrl" Type="varchar" Nullable="false" MaxLength="200" />
  </EntityType>
  <EntityType Name="Parameter">
    <Key>
      <PropertyRef Name="ParameterId" />
    </Key>
    <Property Name="ParameterId" Type="int" Nullable="false" />
    <Property Name="ParameterText" Type="varchar" Nullable="false" MaxLength="100" />
  </EntityType>
  <EntityType Name="ParameterDet">
    <Key>
      <PropertyRef Name="ParameterDetId" />
    </Key>
    <Property Name="ParameterDetId" Type="int" Nullable="false" StoreGeneratedPattern="Identity" />
    <Property Name="ParameterId" Type="int" Nullable="false" />
    <Property Name="ParameterValue" Type="int" Nullable="false" />
    <Property Name="Code" Type="varchar" MaxLength="25" />
    <Property Name="Description" Type="varchar" Nullable="false" MaxLength="100" />
    <Property Name="Description_BL" Type="varchar" MaxLength="100" />
    <Property Name="SortOrder" Type="int" Nullable="false" />
  </EntityType>
  <EntityType Name="Region">
    <Key>
      <PropertyRef Name="Region_Id" />
    </Key>
    <Property Name="Region_Id" Type="int" Nullable="false" StoreGeneratedPattern="Identity" />
    <Property Name="Region_Name" Type="nvarchar" Nullable="false" MaxLength="50" />
    <Property Name="Country_Id" Type="int" Nullable="false" />
  </EntityType>
  <EntityType Name="Role">
    <Key>
      <PropertyRef Name="Role_Id" />
    </Key>
    <Property Name="Role_Id" Type="int" Nullable="false" StoreGeneratedPattern="Identity" />
    <Property Name="Role_Name" Type="nvarchar" Nullable="false" MaxLength="50" />
  </EntityType>
  <EntityType Name="RoleRights">
    <Key>
      <PropertyRef Name="RightsId" />
    </Key>
    <Property Name="RightsId" Type="int" Nullable="false" StoreGeneratedPattern="Identity" />
    <Property Name="RoleId" Type="int" Nullable="false" />
    <Property Name="MenuId" Type="int" Nullable="false" />
    <Property Name="AccessType" Type="int" Nullable="false" />
  </EntityType>
  <EntityType Name="Site_User">
    <Key>
      <PropertyRef Name="Site_User_Id" />
    </Key>
    <Property Name="Site_User_Id" Type="int" Nullable="false" StoreGeneratedPattern="Identity" />
    <Property Name="Role_Id" Type="int" Nullable="false" />
    <Property Name="Location_Id" Type="int" Nullable="false" />
    <Property Name="Name" Type="nvarchar" Nullable="false" MaxLength="50" />
    <Property Name="Login_Name" Type="nvarchar" MaxLength="50" />
    <Property Name="Password" Type="nvarchar" Nullable="false" MaxLength="50" />
    <Property Name="Email" Type="nvarchar" MaxLength="50" />
    <Property Name="Status" Type="bit" Nullable="false" />
    <Property Name="Employee_Code" Type="nvarchar" MaxLength="50" />
  </EntityType>
  <EntityType Name="sysdiagrams">
    <Key>
      <PropertyRef Name="diagram_id" />
    </Key>
    <Property Name="name" Type="nvarchar" Nullable="false" MaxLength="128" />
    <Property Name="principal_id" Type="int" Nullable="false" />
    <Property Name="diagram_id" Type="int" Nullable="false" StoreGeneratedPattern="Identity" />
    <Property Name="version" Type="int" />
    <Property Name="definition" Type="varbinary(max)" />
  </EntityType>
  <EntityType Name="Target">
    <Key>
      <PropertyRef Name="Target_Id" />
    </Key>
    <Property Name="Target_Id" Type="int" Nullable="false" StoreGeneratedPattern="Identity" />
    <Property Name="Month" Type="int" Nullable="false" />
    <Property Name="Year" Type="int" Nullable="false" />
    <Property Name="Site_User_Id" Type="int" Nullable="false" />
    <Property Name="Sales" Type="int" />
    <Property Name="Collection" Type="int" />
    <Property Name="Secondary_Sales" Type="int" />
  </EntityType>
  <EntityType Name="User_Language">
    <Key>
      <PropertyRef Name="User_Language_Id" />
    </Key>
    <Property Name="User_Language_Id" Type="int" Nullable="false" StoreGeneratedPattern="Identity" />
    <Property Name="Site_User_Id" Type="int" Nullable="false" />
    <Property Name="Language_Id" Type="int" Nullable="false" />
  </EntityType>
  <!--Errors Found During Generation:
      warning 6002: The table/view 'NikaiDSR.dbo.ActiveContactCustomerLocationView' does not have a primary key defined. The key has been inferred and the definition was created as a read-only table/view.
      -->
  <EntityType Name="ActiveContactCustomerLocationView">
    <Key>
      <PropertyRef Name="Customer_Id" />
      <PropertyRef Name="Customer_Status" />
      <PropertyRef Name="Location_Id" />
      <PropertyRef Name="Site_User_Id" />
      <PropertyRef Name="Updated_By" />
      <PropertyRef Name="Updated_Date" />
    </Key>
    <Property Name="Contact_Id" Type="int" />
    <Property Name="Contact_Name" Type="nvarchar" MaxLength="50" />
    <Property Name="Department" Type="nvarchar" MaxLength="50" />
    <Property Name="Contact_Status" Type="bit" />
    <Property Name="Customer_Id" Type="int" Nullable="false" />
    <Property Name="Customer_Name" Type="nvarchar" MaxLength="50" />
    <Property Name="Key_Account" Type="bit" />
    <Property Name="Customer_Status" Type="bit" Nullable="false" />
    <Property Name="Location_Id" Type="int" Nullable="false" />
    <Property Name="Location_Name" Type="nvarchar" MaxLength="50" />
    <Property Name="Site_User_Id" Type="int" Nullable="false" />
    <Property Name="Customer_Name_BL" Type="nvarchar" MaxLength="50" />
    <Property Name="Contact_Name_BL" Type="nvarchar" MaxLength="50" />
    <Property Name="Updated_By" Type="int" Nullable="false" />
    <Property Name="Updated_Date" Type="date" Nullable="false" />
    <Property Name="Customer_Code" Type="nvarchar" MaxLength="50" />
    <Property Name="Business_Type" Type="int" />
    <Property Name="Customer_Type" Type="int" />
    <Property Name="Customer_Group" Type="int" />
    <Property Name="Department_BL" Type="nvarchar" MaxLength="50" />
    <Property Name="Mobile" Type="nvarchar" MaxLength="50" />
  </EntityType>
  <!--Errors Found During Generation:
      warning 6002: The table/view 'NikaiDSR.dbo.ActiveCustomerLocationRegionCountryView' does not have a primary key defined. The key has been inferred and the definition was created as a read-only table/view.
      -->
  <EntityType Name="ActiveCustomerLocationRegionCountryView">
    <Key>
      <PropertyRef Name="Customer_Id" />
      <PropertyRef Name="Customer_Status" />
      <PropertyRef Name="Location_Id" />
      <PropertyRef Name="Updated_By" />
      <PropertyRef Name="Updated_Date" />
      <PropertyRef Name="Country_Name" />
      <PropertyRef Name="Region_Name" />
    </Key>
    <Property Name="Customer_Id" Type="int" Nullable="false" />
    <Property Name="Customer_Name" Type="nvarchar" MaxLength="50" />
    <Property Name="Key_Account" Type="bit" />
    <Property Name="Customer_Status" Type="bit" Nullable="false" />
    <Property Name="Location_Id" Type="int" Nullable="false" />
    <Property Name="Location_Name" Type="nvarchar" MaxLength="50" />
    <Property Name="Customer_Name_BL" Type="nvarchar" MaxLength="50" />
    <Property Name="Updated_By" Type="int" Nullable="false" />
    <Property Name="Updated_Date" Type="date" Nullable="false" />
    <Property Name="Customer_Code" Type="nvarchar" MaxLength="50" />
    <Property Name="Business_Type" Type="int" />
    <Property Name="Customer_Type" Type="int" />
    <Property Name="Customer_Group" Type="int" />
    <Property Name="Country_Name" Type="nvarchar" Nullable="false" MaxLength="50" />
    <Property Name="Region_Name" Type="nvarchar" Nullable="false" MaxLength="50" />
  </EntityType>
  <!--Errors Found During Generation:
      warning 6002: The table/view 'NikaiDSR.dbo.DsrContactCustomerLocationView' does not have a primary key defined. The key has been inferred and the definition was created as a read-only table/view.
      -->
  <EntityType Name="DsrContactCustomerLocationView">
    <Key>
      <PropertyRef Name="Site_User_Id" />
      <PropertyRef Name="DSR_Id" />
      <PropertyRef Name="Contact_Id" />
      <PropertyRef Name="Date" />
      <PropertyRef Name="Customer_Id" />
      <PropertyRef Name="Contact_Status" />
      <PropertyRef Name="Customer_Status" />
      <PropertyRef Name="Updated_By" />
      <PropertyRef Name="Updated_Date" />
    </Key>
    <Property Name="Site_User_Id" Type="int" Nullable="false" />
    <Property Name="DSR_Id" Type="int" Nullable="false" />
    <Property Name="Contact_Id" Type="int" Nullable="false" />
    <Property Name="Contact_Name" Type="nvarchar" MaxLength="50" />
    <Property Name="Date" Type="date" Nullable="false" />
    <Property Name="Customer_Id" Type="int" Nullable="false" />
    <Property Name="Contact_Status" Type="bit" Nullable="false" />
    <Property Name="Customer_Name" Type="nvarchar" MaxLength="50" />
    <Property Name="Location_Id" Type="int" />
    <Property Name="Customer_Status" Type="bit" Nullable="false" />
    <Property Name="Location_Name" Type="nvarchar" MaxLength="50" />
    <Property Name="Customer_Name_BL" Type="nvarchar" MaxLength="50" />
    <Property Name="Contact_Name_BL" Type="nvarchar" MaxLength="50" />
    <Property Name="Updated_By" Type="int" Nullable="false" />
    <Property Name="Updated_Date" Type="date" Nullable="false" />
    <Property Name="Location_Name_BL" Type="nvarchar" MaxLength="50" />
  </EntityType>
  <!--Errors Found During Generation:
      warning 6002: The table/view 'NikaiDSR.dbo.DSRReportView' does not have a primary key defined. The key has been inferred and the definition was created as a read-only table/view.
      -->
  <EntityType Name="DSRReportView">
    <Key>
      <PropertyRef Name="Site_User_Id" />
      <PropertyRef Name="Date" />
      <PropertyRef Name="Customer_Id" />
      <PropertyRef Name="Contact_Id" />
      <PropertyRef Name="Status_Contact" />
      <PropertyRef Name="Status_Customer" />
    </Key>
    <Property Name="Site_User_Id" Type="int" Nullable="false" />
    <Property Name="Date" Type="date" Nullable="false" />
    <Property Name="Customer_Id" Type="int" Nullable="false" />
    <Property Name="Customer_Code" Type="nvarchar" MaxLength="50" />
    <Property Name="Customer_Name" Type="nvarchar" MaxLength="50" />
    <Property Name="Customer_Name_BL" Type="nvarchar" MaxLength="50" />
    <Property Name="Contact_Id" Type="int" Nullable="false" />
    <Property Name="Contact_Name" Type="nvarchar" MaxLength="50" />
    <Property Name="Contact_Name_BL" Type="nvarchar" MaxLength="50" />
    <Property Name="Department_BL" Type="nvarchar" MaxLength="50" />
    <Property Name="Department" Type="nvarchar" MaxLength="50" />
    <Property Name="Mobile" Type="nvarchar" MaxLength="50" />
    <Property Name="Status_Contact" Type="bit" Nullable="false" />
    <Property Name="Objective" Type="nvarchar" MaxLength="50" />
    <Property Name="Time_In" Type="time" />
    <Property Name="Time_Out" Type="time" />
    <Property Name="Time_Spent" Type="int" />
    <Property Name="Time_w_Merchandiser" Type="int" />
    <Property Name="Collection" Type="int" />
    <Property Name="Secondary_Sales" Type="int" />
    <Property Name="Sales_LPO_Received" Type="int" />
    <Property Name="Discount" Type="int" />
    <Property Name="Sales_Return" Type="int" />
    <Property Name="Remarks" Type="nvarchar" MaxLength="50" />
    <Property Name="Status_Customer" Type="bit" Nullable="false" />
  </EntityType>
  <!--Errors Found During Generation:
      warning 6002: The table/view 'NikaiDSR.dbo.UserRoleLocationRegionCountryView' does not have a primary key defined. The key has been inferred and the definition was created as a read-only table/view.
      -->
  <EntityType Name="UserRoleLocationRegionCountryView">
    <Key>
      <PropertyRef Name="Site_User_Id" />
      <PropertyRef Name="Name" />
      <PropertyRef Name="Status" />
      <PropertyRef Name="Role_Id" />
      <PropertyRef Name="Role_Name" />
      <PropertyRef Name="Location_Id" />
      <PropertyRef Name="Location_Name" />
      <PropertyRef Name="Region_Id" />
      <PropertyRef Name="Region_Name" />
      <PropertyRef Name="Country_Id" />
      <PropertyRef Name="Country_Name" />
    </Key>
    <Property Name="Site_User_Id" Type="int" Nullable="false" />
    <Property Name="Name" Type="nvarchar" Nullable="false" MaxLength="50" />
    <Property Name="Email" Type="nvarchar" MaxLength="50" />
    <Property Name="Status" Type="bit" Nullable="false" />
    <Property Name="Role_Id" Type="int" Nullable="false" />
    <Property Name="Role_Name" Type="nvarchar" Nullable="false" MaxLength="50" />
    <Property Name="Location_Id" Type="int" Nullable="false" />
    <Property Name="Location_Name" Type="nvarchar" Nullable="false" MaxLength="50" />
    <Property Name="Region_Id" Type="int" Nullable="false" />
    <Property Name="Region_Name" Type="nvarchar" Nullable="false" MaxLength="50" />
    <Property Name="Country_Id" Type="int" Nullable="false" />
    <Property Name="Country_Name" Type="nvarchar" Nullable="false" MaxLength="50" />
  </EntityType>
  <Association Name="FK_Absent_Site_User">
    <End Role="Site_User" Type="NikaiDSRModel.Store.Site_User" Multiplicity="1" />
    <End Role="Absent" Type="NikaiDSRModel.Store.Absent" Multiplicity="*" />
    <ReferentialConstraint>
      <Principal Role="Site_User">
        <PropertyRef Name="Site_User_Id" />
      </Principal>
      <Dependent Role="Absent">
        <PropertyRef Name="Site_User_Id" />
      </Dependent>
    </ReferentialConstraint>
  </Association>
  <Association Name="FK_Contact_Customer">
    <End Role="Customer" Type="NikaiDSRModel.Store.Customer" Multiplicity="1" />
    <End Role="Contact" Type="NikaiDSRModel.Store.Contact" Multiplicity="*" />
    <ReferentialConstraint>
      <Principal Role="Customer">
        <PropertyRef Name="Customer_Id" />
      </Principal>
      <Dependent Role="Contact">
        <PropertyRef Name="Customer_Id" />
      </Dependent>
    </ReferentialConstraint>
  </Association>
  <Association Name="FK_Customer_Location">
    <End Role="Location" Type="NikaiDSRModel.Store.Location" Multiplicity="0..1" />
    <End Role="Customer" Type="NikaiDSRModel.Store.Customer" Multiplicity="*" />
    <ReferentialConstraint>
      <Principal Role="Location">
        <PropertyRef Name="Location_Id" />
      </Principal>
      <Dependent Role="Customer">
        <PropertyRef Name="Location_Id" />
      </Dependent>
    </ReferentialConstraint>
  </Association>
  <Association Name="FK_Customer_ParameterDet">
    <End Role="ParameterDet" Type="NikaiDSRModel.Store.ParameterDet" Multiplicity="0..1" />
    <End Role="Customer" Type="NikaiDSRModel.Store.Customer" Multiplicity="*" />
    <ReferentialConstraint>
      <Principal Role="ParameterDet">
        <PropertyRef Name="ParameterDetId" />
      </Principal>
      <Dependent Role="Customer">
        <PropertyRef Name="Business_Type" />
      </Dependent>
    </ReferentialConstraint>
  </Association>
  <Association Name="FK_Customer_ParameterDet1">
    <End Role="ParameterDet" Type="NikaiDSRModel.Store.ParameterDet" Multiplicity="0..1" />
    <End Role="Customer" Type="NikaiDSRModel.Store.Customer" Multiplicity="*" />
    <ReferentialConstraint>
      <Principal Role="ParameterDet">
        <PropertyRef Name="ParameterDetId" />
      </Principal>
      <Dependent Role="Customer">
        <PropertyRef Name="Customer_Group" />
      </Dependent>
    </ReferentialConstraint>
  </Association>
  <Association Name="FK_Customer_ParameterDet2">
    <End Role="ParameterDet" Type="NikaiDSRModel.Store.ParameterDet" Multiplicity="0..1" />
    <End Role="Customer" Type="NikaiDSRModel.Store.Customer" Multiplicity="*" />
    <ReferentialConstraint>
      <Principal Role="ParameterDet">
        <PropertyRef Name="ParameterDetId" />
      </Principal>
      <Dependent Role="Customer">
        <PropertyRef Name="Customer_Type" />
      </Dependent>
    </ReferentialConstraint>
  </Association>
  <Association Name="FK_Customer_ParameterDet3">
    <End Role="ParameterDet" Type="NikaiDSRModel.Store.ParameterDet" Multiplicity="0..1" />
    <End Role="Customer" Type="NikaiDSRModel.Store.Customer" Multiplicity="*" />
    <ReferentialConstraint>
      <Principal Role="ParameterDet">
        <PropertyRef Name="ParameterDetId" />
      </Principal>
      <Dependent Role="Customer">
        <PropertyRef Name="Sales_Channel" />
      </Dependent>
    </ReferentialConstraint>
  </Association>
  <Association Name="FK_Customer_Site_User">
    <End Role="Site_User" Type="NikaiDSRModel.Store.Site_User" Multiplicity="1" />
    <End Role="Customer" Type="NikaiDSRModel.Store.Customer" Multiplicity="*" />
    <ReferentialConstraint>
      <Principal Role="Site_User">
        <PropertyRef Name="Site_User_Id" />
      </Principal>
      <Dependent Role="Customer">
        <PropertyRef Name="Updated_By" />
      </Dependent>
    </ReferentialConstraint>
  </Association>
  <Association Name="FK_DSR_Contact">
    <End Role="Contact" Type="NikaiDSRModel.Store.Contact" Multiplicity="1" />
    <End Role="DSR" Type="NikaiDSRModel.Store.DSR" Multiplicity="*" />
    <ReferentialConstraint>
      <Principal Role="Contact">
        <PropertyRef Name="Contact_Id" />
      </Principal>
      <Dependent Role="DSR">
        <PropertyRef Name="Contact_Id" />
      </Dependent>
    </ReferentialConstraint>
  </Association>
  <Association Name="FK_DSR_DSR_Header">
    <End Role="Site_User" Type="NikaiDSRModel.Store.Site_User" Multiplicity="1" />
    <End Role="DSR" Type="NikaiDSRModel.Store.DSR" Multiplicity="*" />
    <ReferentialConstraint>
      <Principal Role="Site_User">
        <PropertyRef Name="Site_User_Id" />
      </Principal>
      <Dependent Role="DSR">
        <PropertyRef Name="Site_User_Id" />
      </Dependent>
    </ReferentialConstraint>
  </Association>
  <Association Name="FK_Holiday_Country">
    <End Role="Country" Type="NikaiDSRModel.Store.Country" Multiplicity="1" />
    <End Role="Holiday" Type="NikaiDSRModel.Store.Holiday" Multiplicity="*" />
    <ReferentialConstraint>
      <Principal Role="Country">
        <PropertyRef Name="Country_Id" />
      </Principal>
      <Dependent Role="Holiday">
        <PropertyRef Name="Country_Id" />
      </Dependent>
    </ReferentialConstraint>
  </Association>
  <Association Name="FK_Holiday_ParameterDet">
    <End Role="ParameterDet" Type="NikaiDSRModel.Store.ParameterDet" Multiplicity="1" />
    <End Role="Holiday" Type="NikaiDSRModel.Store.Holiday" Multiplicity="*" />
    <ReferentialConstraint>
      <Principal Role="ParameterDet">
        <PropertyRef Name="ParameterDetId" />
      </Principal>
      <Dependent Role="Holiday">
        <PropertyRef Name="Holiday_Type" />
      </Dependent>
    </ReferentialConstraint>
  </Association>
  <Association Name="FK_Location_Region">
    <End Role="Region" Type="NikaiDSRModel.Store.Region" Multiplicity="1" />
    <End Role="Location" Type="NikaiDSRModel.Store.Location" Multiplicity="*" />
    <ReferentialConstraint>
      <Principal Role="Region">
        <PropertyRef Name="Region_Id" />
      </Principal>
      <Dependent Role="Location">
        <PropertyRef Name="Region_Id" />
      </Dependent>
    </ReferentialConstraint>
  </Association>
  <Association Name="FK_Manager_Executive_Site_User">
    <End Role="Site_User" Type="NikaiDSRModel.Store.Site_User" Multiplicity="1" />
    <End Role="Manager_Executive" Type="NikaiDSRModel.Store.Manager_Executive" Multiplicity="*" />
    <ReferentialConstraint>
      <Principal Role="Site_User">
        <PropertyRef Name="Site_User_Id" />
      </Principal>
      <Dependent Role="Manager_Executive">
        <PropertyRef Name="Manager_Id" />
      </Dependent>
    </ReferentialConstraint>
  </Association>
  <Association Name="FK_Menu_ParameterDet">
    <End Role="ParameterDet" Type="NikaiDSRModel.Store.ParameterDet" Multiplicity="1" />
    <End Role="Menu" Type="NikaiDSRModel.Store.Menu" Multiplicity="*" />
    <ReferentialConstraint>
      <Principal Role="ParameterDet">
        <PropertyRef Name="ParameterDetId" />
      </Principal>
      <Dependent Role="Menu">
        <PropertyRef Name="MenuStatus" />
      </Dependent>
    </ReferentialConstraint>
  </Association>
  <Association Name="FK_MenuAccess_Menu">
    <End Role="Menu" Type="NikaiDSRModel.Store.Menu" Multiplicity="1" />
    <End Role="MenuAccess" Type="NikaiDSRModel.Store.MenuAccess" Multiplicity="*" />
    <ReferentialConstraint>
      <Principal Role="Menu">
        <PropertyRef Name="MenuId" />
      </Principal>
      <Dependent Role="MenuAccess">
        <PropertyRef Name="MenuId" />
      </Dependent>
    </ReferentialConstraint>
  </Association>
  <Association Name="FK_MenuAccess_ParameterDet">
    <End Role="ParameterDet" Type="NikaiDSRModel.Store.ParameterDet" Multiplicity="1" />
    <End Role="MenuAccess" Type="NikaiDSRModel.Store.MenuAccess" Multiplicity="*" />
    <ReferentialConstraint>
      <Principal Role="ParameterDet">
        <PropertyRef Name="ParameterDetId" />
      </Principal>
      <Dependent Role="MenuAccess">
        <PropertyRef Name="AccessType" />
      </Dependent>
    </ReferentialConstraint>
  </Association>
  <Association Name="FK_MenuRolePages_Menu">
    <End Role="Menu" Type="NikaiDSRModel.Store.Menu" Multiplicity="1" />
    <End Role="MenuRolePages" Type="NikaiDSRModel.Store.MenuRolePages" Multiplicity="*" />
    <ReferentialConstraint>
      <Principal Role="Menu">
        <PropertyRef Name="MenuId" />
      </Principal>
      <Dependent Role="MenuRolePages">
        <PropertyRef Name="MenuId" />
      </Dependent>
    </ReferentialConstraint>
  </Association>
  <Association Name="FK_MenuRolePages_ParameterDet">
    <End Role="Role" Type="NikaiDSRModel.Store.Role" Multiplicity="1" />
    <End Role="MenuRolePages" Type="NikaiDSRModel.Store.MenuRolePages" Multiplicity="*" />
    <ReferentialConstraint>
      <Principal Role="Role">
        <PropertyRef Name="Role_Id" />
      </Principal>
      <Dependent Role="MenuRolePages">
        <PropertyRef Name="RoleId" />
      </Dependent>
    </ReferentialConstraint>
  </Association>
  <Association Name="FK_ParameterDet_Parameter">
    <End Role="Parameter" Type="NikaiDSRModel.Store.Parameter" Multiplicity="1" />
    <End Role="ParameterDet" Type="NikaiDSRModel.Store.ParameterDet" Multiplicity="*" />
    <ReferentialConstraint>
      <Principal Role="Parameter">
        <PropertyRef Name="ParameterId" />
      </Principal>
      <Dependent Role="ParameterDet">
        <PropertyRef Name="ParameterId" />
      </Dependent>
    </ReferentialConstraint>
  </Association>
  <Association Name="FK_Region_Country">
    <End Role="Country" Type="NikaiDSRModel.Store.Country" Multiplicity="1" />
    <End Role="Region" Type="NikaiDSRModel.Store.Region" Multiplicity="*" />
    <ReferentialConstraint>
      <Principal Role="Country">
        <PropertyRef Name="Country_Id" />
      </Principal>
      <Dependent Role="Region">
        <PropertyRef Name="Country_Id" />
      </Dependent>
    </ReferentialConstraint>
  </Association>
  <Association Name="FK_RoleRights_Menu">
    <End Role="Menu" Type="NikaiDSRModel.Store.Menu" Multiplicity="1" />
    <End Role="RoleRights" Type="NikaiDSRModel.Store.RoleRights" Multiplicity="*" />
    <ReferentialConstraint>
      <Principal Role="Menu">
        <PropertyRef Name="MenuId" />
      </Principal>
      <Dependent Role="RoleRights">
        <PropertyRef Name="MenuId" />
      </Dependent>
    </ReferentialConstraint>
  </Association>
  <Association Name="FK_RoleRights_ParameterDet">
    <End Role="Role" Type="NikaiDSRModel.Store.Role" Multiplicity="1" />
    <End Role="RoleRights" Type="NikaiDSRModel.Store.RoleRights" Multiplicity="*" />
    <ReferentialConstraint>
      <Principal Role="Role">
        <PropertyRef Name="Role_Id" />
      </Principal>
      <Dependent Role="RoleRights">
        <PropertyRef Name="RoleId" />
      </Dependent>
    </ReferentialConstraint>
  </Association>
  <Association Name="FK_RoleRights_ParameterDet1">
    <End Role="ParameterDet" Type="NikaiDSRModel.Store.ParameterDet" Multiplicity="1" />
    <End Role="RoleRights" Type="NikaiDSRModel.Store.RoleRights" Multiplicity="*" />
    <ReferentialConstraint>
      <Principal Role="ParameterDet">
        <PropertyRef Name="ParameterDetId" />
      </Principal>
      <Dependent Role="RoleRights">
        <PropertyRef Name="AccessType" />
      </Dependent>
    </ReferentialConstraint>
  </Association>
  <Association Name="FK_Site_User_Location">
    <End Role="Location" Type="NikaiDSRModel.Store.Location" Multiplicity="1" />
    <End Role="Site_User" Type="NikaiDSRModel.Store.Site_User" Multiplicity="*" />
    <ReferentialConstraint>
      <Principal Role="Location">
        <PropertyRef Name="Location_Id" />
      </Principal>
      <Dependent Role="Site_User">
        <PropertyRef Name="Location_Id" />
      </Dependent>
    </ReferentialConstraint>
  </Association>
  <Association Name="FK_Site_User_Role">
    <End Role="Role" Type="NikaiDSRModel.Store.Role" Multiplicity="1" />
    <End Role="Site_User" Type="NikaiDSRModel.Store.Site_User" Multiplicity="*" />
    <ReferentialConstraint>
      <Principal Role="Role">
        <PropertyRef Name="Role_Id" />
      </Principal>
      <Dependent Role="Site_User">
        <PropertyRef Name="Role_Id" />
      </Dependent>
    </ReferentialConstraint>
  </Association>
  <Association Name="FK_Target_Site_User">
    <End Role="Site_User" Type="NikaiDSRModel.Store.Site_User" Multiplicity="1" />
    <End Role="Target" Type="NikaiDSRModel.Store.Target" Multiplicity="*" />
    <ReferentialConstraint>
      <Principal Role="Site_User">
        <PropertyRef Name="Site_User_Id" />
      </Principal>
      <Dependent Role="Target">
        <PropertyRef Name="Site_User_Id" />
      </Dependent>
    </ReferentialConstraint>
  </Association>
  <Association Name="FK_User_Language_ParameterDet">
    <End Role="ParameterDet" Type="NikaiDSRModel.Store.ParameterDet" Multiplicity="1" />
    <End Role="User_Language" Type="NikaiDSRModel.Store.User_Language" Multiplicity="*" />
    <ReferentialConstraint>
      <Principal Role="ParameterDet">
        <PropertyRef Name="ParameterDetId" />
      </Principal>
      <Dependent Role="User_Language">
        <PropertyRef Name="Language_Id" />
      </Dependent>
    </ReferentialConstraint>
  </Association>
  <Association Name="FK_User_Language_Site_User">
    <End Role="Site_User" Type="NikaiDSRModel.Store.Site_User" Multiplicity="1" />
    <End Role="User_Language" Type="NikaiDSRModel.Store.User_Language" Multiplicity="*" />
    <ReferentialConstraint>
      <Principal Role="Site_User">
        <PropertyRef Name="Site_User_Id" />
      </Principal>
      <Dependent Role="User_Language">
        <PropertyRef Name="Site_User_Id" />
      </Dependent>
    </ReferentialConstraint>
  </Association>
  <Function Name="ActiveCustomerLocationRegionCountry" Aggregate="false" BuiltIn="false" NiladicFunction="false" IsComposable="false" ParameterTypeSemantics="AllowImplicitConversion" Schema="dbo">
    <Parameter Name="User_Id" Type="int" Mode="In" />
  </Function>
  <Function Name="ChangePassword" Aggregate="false" BuiltIn="false" NiladicFunction="false" IsComposable="false" ParameterTypeSemantics="AllowImplicitConversion" Schema="dbo">
    <Parameter Name="User_Id" Type="int" Mode="In" />
    <Parameter Name="Password" Type="nvarchar" Mode="In" />
  </Function>
  <Function Name="fn_diagramobjects" ReturnType="int" Aggregate="false" BuiltIn="false" NiladicFunction="false" IsComposable="true" ParameterTypeSemantics="AllowImplicitConversion" Schema="dbo" />
  <Function Name="GetAbsent" Aggregate="false" BuiltIn="false" NiladicFunction="false" IsComposable="false" ParameterTypeSemantics="AllowImplicitConversion" Schema="dbo">
    <Parameter Name="Absent_Id" Type="int" Mode="In" />
    <Parameter Name="Date" Type="datetime" Mode="In" />
    <Parameter Name="Site_User_Id" Type="int" Mode="In" />
  </Function>
  <Function Name="GetActiveContactCustomerLocation" Aggregate="false" BuiltIn="false" NiladicFunction="false" IsComposable="false" ParameterTypeSemantics="AllowImplicitConversion" Schema="dbo">
    <Parameter Name="User_Id" Type="int" Mode="In" />
  </Function>
  <Function Name="GetActiveCustomerLocationRegionCountry" Aggregate="false" BuiltIn="false" NiladicFunction="false" IsComposable="false" ParameterTypeSemantics="AllowImplicitConversion" Schema="dbo">
    <Parameter Name="User_Id" Type="int" Mode="In" />
  </Function>
  <Function Name="GetActiveDsrContactCustomerLocation" Aggregate="false" BuiltIn="false" NiladicFunction="false" IsComposable="false" ParameterTypeSemantics="AllowImplicitConversion" Schema="dbo">
    <Parameter Name="User_Id" Type="int" Mode="In" />
    <Parameter Name="Date" Type="date" Mode="In" />
  </Function>
  <Function Name="GetAttendance" Aggregate="false" BuiltIn="false" NiladicFunction="false" IsComposable="false" ParameterTypeSemantics="AllowImplicitConversion" Schema="dbo">
    <Parameter Name="DatePeriod" Type="int" Mode="In" />
    <Parameter Name="SpecificDate" Type="date" Mode="In" />
    <Parameter Name="User_Id" Type="int" Mode="In" />
  </Function>
  <Function Name="GetAttendanceAndDSR" Aggregate="false" BuiltIn="false" NiladicFunction="false" IsComposable="false" ParameterTypeSemantics="AllowImplicitConversion" Schema="dbo">
    <Parameter Name="DatePeriod" Type="int" Mode="In" />
    <Parameter Name="SpecificDate" Type="date" Mode="In" />
    <Parameter Name="User_Id" Type="int" Mode="In" />
    <Parameter Name="Search_User_Id" Type="int" Mode="In" />
  </Function>
  <Function Name="GetContact" Aggregate="false" BuiltIn="false" NiladicFunction="false" IsComposable="false" ParameterTypeSemantics="AllowImplicitConversion" Schema="dbo">
    <Parameter Name="Contact_Id" Type="int" Mode="In" />
    <Parameter Name="Contact_Name" Type="nvarchar" Mode="In" />
    <Parameter Name="Contact_Name_BL" Type="nvarchar" Mode="In" />
    <Parameter Name="Customer_Id" Type="int" Mode="In" />
    <Parameter Name="Department" Type="nvarchar" Mode="In" />
    <Parameter Name="Department_BL" Type="nvarchar" Mode="In" />
    <Parameter Name="Mobile" Type="int" Mode="In" />
    <Parameter Name="Status" Type="int" Mode="In" />
  </Function>
  <Function Name="GetContactWithCustName" Aggregate="false" BuiltIn="false" NiladicFunction="false" IsComposable="false" ParameterTypeSemantics="AllowImplicitConversion" Schema="dbo">
    <Parameter Name="Contact_Id" Type="int" Mode="In" />
    <Parameter Name="Contact_Name" Type="nvarchar" Mode="In" />
    <Parameter Name="Customer_Name" Type="nvarchar" Mode="In" />
    <Parameter Name="Contact_Name_BL" Type="nvarchar" Mode="In" />
    <Parameter Name="Customer_Id" Type="int" Mode="In" />
    <Parameter Name="Department" Type="nvarchar" Mode="In" />
    <Parameter Name="Department_BL" Type="nvarchar" Mode="In" />
    <Parameter Name="Mobile" Type="nvarchar" Mode="In" />
    <Parameter Name="Status" Type="int" Mode="In" />
  </Function>
  <Function Name="GetCountry" Aggregate="false" BuiltIn="false" NiladicFunction="false" IsComposable="false" ParameterTypeSemantics="AllowImplicitConversion" Schema="dbo">
    <Parameter Name="Country_Id" Type="int" Mode="In" />
    <Parameter Name="Country_Name" Type="nvarchar" Mode="In" />
  </Function>
  <Function Name="GetCustomer" Aggregate="false" BuiltIn="false" NiladicFunction="false" IsComposable="false" ParameterTypeSemantics="AllowImplicitConversion" Schema="dbo">
    <Parameter Name="Customer_Id" Type="int" Mode="In" />
    <Parameter Name="Customer_Code" Type="nvarchar" Mode="In" />
    <Parameter Name="Customer_Name" Type="nvarchar" Mode="In" />
    <Parameter Name="Customer_Name_BL" Type="nvarchar" Mode="In" />
    <Parameter Name="Business_Type" Type="int" Mode="In" />
    <Parameter Name="Customer_Type" Type="int" Mode="In" />
    <Parameter Name="Customer_Group" Type="int" Mode="In" />
    <Parameter Name="Location_Id" Type="int" Mode="In" />
    <Parameter Name="Key_Account" Type="bit" Mode="In" />
    <Parameter Name="Status" Type="bit" Mode="In" />
    <Parameter Name="Sales_Channel" Type="int" Mode="In" />
  </Function>
  <Function Name="GetDSR" Aggregate="false" BuiltIn="false" NiladicFunction="false" IsComposable="false" ParameterTypeSemantics="AllowImplicitConversion" Schema="dbo">
    <Parameter Name="DSR_Id" Type="int" Mode="In" />
    <Parameter Name="Site_User_Id" Type="int" Mode="In" />
    <Parameter Name="Date" Type="date" Mode="In" />
    <Parameter Name="Contact_Id" Type="int" Mode="In" />
    <Parameter Name="Objective" Type="int" Mode="In" />
    <Parameter Name="Time_In" Type="time" Mode="In" />
    <Parameter Name="Time_Out" Type="time" Mode="In" />
    <Parameter Name="Time_Spent" Type="int" Mode="In" />
    <Parameter Name="Time_w_Merchandiser" Type="int" Mode="In" />
    <Parameter Name="Collection" Type="int" Mode="In" />
    <Parameter Name="Secondary_Sales" Type="int" Mode="In" />
    <Parameter Name="Sales_LPO_Received" Type="int" Mode="In" />
    <Parameter Name="Discount" Type="int" Mode="In" />
    <Parameter Name="Sales_Return" Type="int" Mode="In" />
    <Parameter Name="Remarks" Type="nvarchar" Mode="In" />
  </Function>
  <Function Name="GetDSRHeader" Aggregate="false" BuiltIn="false" NiladicFunction="false" IsComposable="false" ParameterTypeSemantics="AllowImplicitConversion" Schema="dbo">
    <Parameter Name="DSR_Head_Id" Type="int" Mode="In" />
    <Parameter Name="Date" Type="date" Mode="In" />
    <Parameter Name="Shift" Type="nvarchar" Mode="In" />
    <Parameter Name="Morning_Time_In" Type="time" Mode="In" />
    <Parameter Name="Morning_Time_Out" Type="time" Mode="In" />
    <Parameter Name="Evening_Time_In" Type="time" Mode="In" />
    <Parameter Name="Evening_Time_Out" Type="time" Mode="In" />
    <Parameter Name="Comments" Type="nvarchar" Mode="In" />
    <Parameter Name="Site_User_Id" Type="int" Mode="In" />
  </Function>
  <Function Name="GetExecutiveReport" Aggregate="false" BuiltIn="false" NiladicFunction="false" IsComposable="false" ParameterTypeSemantics="AllowImplicitConversion" Schema="dbo">
    <Parameter Name="Month" Type="int" Mode="In" />
    <Parameter Name="Year" Type="int" Mode="In" />
    <Parameter Name="Executive_Id" Type="int" Mode="In" />
  </Function>
  <Function Name="GetExecutiveTargetsActuals" Aggregate="false" BuiltIn="false" NiladicFunction="false" IsComposable="false" ParameterTypeSemantics="AllowImplicitConversion" Schema="dbo">
    <Parameter Name="Month" Type="int" Mode="In" />
    <Parameter Name="Year" Type="int" Mode="In" />
    <Parameter Name="Executive_Id" Type="int" Mode="In" />
  </Function>
  <Function Name="GetHoliday" Aggregate="false" BuiltIn="false" NiladicFunction="false" IsComposable="false" ParameterTypeSemantics="AllowImplicitConversion" Schema="dbo">
    <Parameter Name="Holiday_Id" Type="int" Mode="In" />
    <Parameter Name="Date" Type="datetime" Mode="In" />
    <Parameter Name="Country_Id" Type="int" Mode="In" />
    <Parameter Name="Holiday_Type" Type="int" Mode="In" />
  </Function>
  <Function Name="GetLocation" Aggregate="false" BuiltIn="false" NiladicFunction="false" IsComposable="false" ParameterTypeSemantics="AllowImplicitConversion" Schema="dbo">
    <Parameter Name="Location_Id" Type="int" Mode="In" />
    <Parameter Name="Location_Name" Type="nvarchar" Mode="In" />
    <Parameter Name="Region_Id" Type="int" Mode="In" />
  </Function>
  <Function Name="GetManagerExecutive" Aggregate="false" BuiltIn="false" NiladicFunction="false" IsComposable="false" ParameterTypeSemantics="AllowImplicitConversion" Schema="dbo">
    <Parameter Name="Manager_Id" Type="int" Mode="In" />
    <Parameter Name="Executive_Id" Type="int" Mode="In" />
  </Function>
  <Function Name="GetManagerReport" Aggregate="false" BuiltIn="false" NiladicFunction="false" IsComposable="false" ParameterTypeSemantics="AllowImplicitConversion" Schema="dbo">
    <Parameter Name="FromDate" Type="date" Mode="In" />
    <Parameter Name="ToDate" Type="date" Mode="In" />
    <Parameter Name="Country_Id" Type="int" Mode="In" />
    <Parameter Name="Region_Id" Type="int" Mode="In" />
    <Parameter Name="Location_Id" Type="int" Mode="In" />
    <Parameter Name="KeyAccounts" Type="bit" Mode="In" />
    <Parameter Name="Manager_Id" Type="int" Mode="In" />
    <Parameter Name="Search_Executive_Id" Type="int" Mode="In" />
    <Parameter Name="Report_ExecutiveWise" Type="bit" Mode="In" />
  </Function>
  <Function Name="GetParameter" Aggregate="false" BuiltIn="false" NiladicFunction="false" IsComposable="false" ParameterTypeSemantics="AllowImplicitConversion" Schema="dbo">
    <Parameter Name="ParameterId" Type="int" Mode="In" />
    <Parameter Name="ParameterDetId" Type="int" Mode="In" />
    <Parameter Name="ParameterValue" Type="int" Mode="In" />
  </Function>
  <Function Name="GetParameterDetId" ReturnType="int" Aggregate="false" BuiltIn="false" NiladicFunction="false" IsComposable="true" ParameterTypeSemantics="AllowImplicitConversion" Schema="dbo">
    <Parameter Name="ParameterId" Type="int" Mode="In" />
    <Parameter Name="ParameterValue" Type="int" Mode="In" />
  </Function>
  <Function Name="GetRegion" Aggregate="false" BuiltIn="false" NiladicFunction="false" IsComposable="false" ParameterTypeSemantics="AllowImplicitConversion" Schema="dbo">
    <Parameter Name="Region_Id" Type="int" Mode="In" />
    <Parameter Name="Region_Name" Type="nvarchar" Mode="In" />
    <Parameter Name="Country_Id" Type="int" Mode="In" />
  </Function>
  <Function Name="GetReporteesForUserCreation" Aggregate="false" BuiltIn="false" NiladicFunction="false" IsComposable="false" ParameterTypeSemantics="AllowImplicitConversion" Schema="dbo">
    <Parameter Name="Role_Id" Type="int" Mode="In" />
    <Parameter Name="Location_Id" Type="int" Mode="In" />
  </Function>
  <Function Name="GetRole" Aggregate="false" BuiltIn="false" NiladicFunction="false" IsComposable="false" ParameterTypeSemantics="AllowImplicitConversion" Schema="dbo">
    <Parameter Name="Role_Id" Type="int" Mode="In" />
    <Parameter Name="Role_Name" Type="nvarchar" Mode="In" />
  </Function>
  <Function Name="GetRoleRights" Aggregate="false" BuiltIn="false" NiladicFunction="false" IsComposable="false" ParameterTypeSemantics="AllowImplicitConversion" Schema="dbo">
    <Parameter Name="RoleId" Type="int" Mode="In" />
  </Function>
  <Function Name="GetSiteUser" Aggregate="false" BuiltIn="false" NiladicFunction="false" IsComposable="false" ParameterTypeSemantics="AllowImplicitConversion" Schema="dbo">
    <Parameter Name="Site_User_Id" Type="int" Mode="In" />
    <Parameter Name="Role_Id" Type="int" Mode="In" />
    <Parameter Name="Location_Id" Type="int" Mode="In" />
    <Parameter Name="Login_Name" Type="nvarchar" Mode="In" />
    <Parameter Name="Email" Type="nvarchar" Mode="In" />
  </Function>
  <Function Name="GetTarget" Aggregate="false" BuiltIn="false" NiladicFunction="false" IsComposable="false" ParameterTypeSemantics="AllowImplicitConversion" Schema="dbo">
    <Parameter Name="User_Id" Type="int" Mode="In" />
    <Parameter Name="Target_Id" Type="int" Mode="In" />
    <Parameter Name="Month" Type="int" Mode="In" />
    <Parameter Name="Year" Type="int" Mode="In" />
    <Parameter Name="Sales" Type="int" Mode="In" />
    <Parameter Name="Collection" Type="int" Mode="In" />
    <Parameter Name="Secondary_Sales" Type="int" Mode="In" />
  </Function>
  <Function Name="GetUser" Aggregate="false" BuiltIn="false" NiladicFunction="false" IsComposable="false" ParameterTypeSemantics="AllowImplicitConversion" Schema="dbo">
    <Parameter Name="UserId" Type="int" Mode="In" />
    <Parameter Name="UserName" Type="nvarchar" Mode="In" />
    <Parameter Name="Password" Type="nvarchar" Mode="In" />
  </Function>
  <Function Name="GetUserRoleLocationRegionCountry" Aggregate="false" BuiltIn="false" NiladicFunction="false" IsComposable="false" ParameterTypeSemantics="AllowImplicitConversion" Schema="dbo">
    <Parameter Name="User_Id" Type="int" Mode="In" />
    <Parameter Name="UserName" Type="nvarchar" Mode="In" />
    <Parameter Name="Email" Type="nvarchar" Mode="In" />
    <Parameter Name="Status" Type="bit" Mode="In" />
    <Parameter Name="RoleId" Type="int" Mode="In" />
    <Parameter Name="RoleName" Type="nvarchar" Mode="In" />
    <Parameter Name="LocationId" Type="int" Mode="In" />
    <Parameter Name="LocationName" Type="nvarchar" Mode="In" />
    <Parameter Name="RegionId" Type="int" Mode="In" />
    <Parameter Name="RegionName" Type="nvarchar" Mode="In" />
    <Parameter Name="CountryId" Type="int" Mode="In" />
    <Parameter Name="CountryName" Type="nvarchar" Mode="In" />
  </Function>
  <Function Name="InsertLocation" Aggregate="false" BuiltIn="false" NiladicFunction="false" IsComposable="false" ParameterTypeSemantics="AllowImplicitConversion" Schema="dbo">
    <Parameter Name="Location_Name" Type="nvarchar" Mode="In" />
    <Parameter Name="Region_Id" Type="int" Mode="In" />
  </Function>
  <Function Name="InsertRegion" Aggregate="false" BuiltIn="false" NiladicFunction="false" IsComposable="false" ParameterTypeSemantics="AllowImplicitConversion" Schema="dbo">
    <Parameter Name="Region_Name" Type="nvarchar" Mode="In" />
    <Parameter Name="Country_Id" Type="int" Mode="In" />
  </Function>
  <Function Name="InsertUpdateAbsent" Aggregate="false" BuiltIn="false" NiladicFunction="false" IsComposable="false" ParameterTypeSemantics="AllowImplicitConversion" Schema="dbo">
    <Parameter Name="Absent_Id" Type="int" Mode="In" />
    <Parameter Name="Date" Type="datetime" Mode="In" />
    <Parameter Name="Site_User_Id" Type="int" Mode="In" />
  </Function>
  <Function Name="InsertUpdateContact" Aggregate="false" BuiltIn="false" NiladicFunction="false" IsComposable="false" ParameterTypeSemantics="AllowImplicitConversion" Schema="dbo">
    <Parameter Name="Contact_Id" Type="int" Mode="In" />
    <Parameter Name="Contact_Name" Type="nvarchar" Mode="In" />
    <Parameter Name="Contact_Name_BL" Type="nvarchar" Mode="In" />
    <Parameter Name="Customer_Id" Type="int" Mode="In" />
    <Parameter Name="Department" Type="nvarchar" Mode="In" />
    <Parameter Name="Department_BL" Type="nvarchar" Mode="In" />
    <Parameter Name="Mobile" Type="nvarchar" Mode="In" />
    <Parameter Name="Status" Type="bit" Mode="In" />
    <Parameter Name="Cont_Id" Type="int" Mode="InOut" />
  </Function>
  <Function Name="InsertUpdateCountry" Aggregate="false" BuiltIn="false" NiladicFunction="false" IsComposable="false" ParameterTypeSemantics="AllowImplicitConversion" Schema="dbo">
    <Parameter Name="Country_Id" Type="int" Mode="In" />
    <Parameter Name="Country_Name" Type="nvarchar" Mode="In" />
  </Function>
  <Function Name="InsertUpdateCustomer" Aggregate="false" BuiltIn="false" NiladicFunction="false" IsComposable="false" ParameterTypeSemantics="AllowImplicitConversion" Schema="dbo">
    <Parameter Name="Customer_Id" Type="int" Mode="In" />
    <Parameter Name="Customer_Code" Type="nvarchar" Mode="In" />
    <Parameter Name="Customer_Name" Type="nvarchar" Mode="In" />
    <Parameter Name="Customer_Name_BL" Type="nvarchar" Mode="In" />
    <Parameter Name="Business_Type" Type="int" Mode="In" />
    <Parameter Name="Customer_Type" Type="int" Mode="In" />
    <Parameter Name="Customer_Group" Type="int" Mode="In" />
    <Parameter Name="Location_Id" Type="int" Mode="In" />
    <Parameter Name="Key_Account" Type="bit" Mode="In" />
    <Parameter Name="Status" Type="bit" Mode="In" />
    <Parameter Name="Updated_By" Type="int" Mode="In" />
    <Parameter Name="Sales_Channel" Type="int" Mode="In" />
    <Parameter Name="CustId" Type="int" Mode="InOut" />
  </Function>
  <Function Name="InsertUpdateDSR" Aggregate="false" BuiltIn="false" NiladicFunction="false" IsComposable="false" ParameterTypeSemantics="AllowImplicitConversion" Schema="dbo">
    <Parameter Name="DSR_Id" Type="int" Mode="In" />
    <Parameter Name="Site_User_Id" Type="int" Mode="In" />
    <Parameter Name="Date" Type="date" Mode="In" />
    <Parameter Name="Contact_Id" Type="int" Mode="In" />
    <Parameter Name="Objective" Type="int" Mode="In" />
    <Parameter Name="Time_In" Type="time" Mode="In" />
    <Parameter Name="Time_Out" Type="time" Mode="In" />
    <Parameter Name="Time_Spent" Type="int" Mode="In" />
    <Parameter Name="Time_w_Merchandiser" Type="int" Mode="In" />
    <Parameter Name="Collection" Type="int" Mode="In" />
    <Parameter Name="Secondary_Sales" Type="int" Mode="In" />
    <Parameter Name="Sales_LPO_Received" Type="int" Mode="In" />
    <Parameter Name="Discount" Type="int" Mode="In" />
    <Parameter Name="Sales_Return" Type="int" Mode="In" />
    <Parameter Name="Remarks" Type="nvarchar" Mode="In" />
  </Function>
  <Function Name="InsertUpdateDSRHeader" Aggregate="false" BuiltIn="false" NiladicFunction="false" IsComposable="false" ParameterTypeSemantics="AllowImplicitConversion" Schema="dbo">
    <Parameter Name="DSR_Head_Id" Type="int" Mode="In" />
    <Parameter Name="Date" Type="date" Mode="In" />
    <Parameter Name="Shift" Type="nvarchar" Mode="In" />
    <Parameter Name="Morning_Time_In" Type="time" Mode="In" />
    <Parameter Name="Morning_Time_Out" Type="time" Mode="In" />
    <Parameter Name="Evening_Time_In" Type="time" Mode="In" />
    <Parameter Name="Evening_Time_Out" Type="time" Mode="In" />
    <Parameter Name="Comments" Type="nvarchar" Mode="In" />
    <Parameter Name="Site_User_Id" Type="int" Mode="In" />
  </Function>
  <Function Name="InsertUpdateHoliday" Aggregate="false" BuiltIn="false" NiladicFunction="false" IsComposable="false" ParameterTypeSemantics="AllowImplicitConversion" Schema="dbo">
    <Parameter Name="Holiday_Id" Type="int" Mode="In" />
    <Parameter Name="Date" Type="datetime" Mode="In" />
    <Parameter Name="Country_Id" Type="int" Mode="In" />
    <Parameter Name="Holiday_Type" Type="int" Mode="In" />
  </Function>
  <Function Name="InsertUpdateLinkedExecutive" Aggregate="false" BuiltIn="false" NiladicFunction="false" IsComposable="false" ParameterTypeSemantics="AllowImplicitConversion" Schema="dbo">
    <Parameter Name="User_Id" Type="int" Mode="In" />
    <Parameter Name="LinkedUsers" Type="nvarchar" Mode="In" />
  </Function>
  <Function Name="InsertUpdateManagerExecutive" Aggregate="false" BuiltIn="false" NiladicFunction="false" IsComposable="false" ParameterTypeSemantics="AllowImplicitConversion" Schema="dbo">
    <Parameter Name="Manager_Exec_Id" Type="int" Mode="In" />
    <Parameter Name="Manager_Id" Type="int" Mode="In" />
    <Parameter Name="Executive_Id" Type="int" Mode="In" />
  </Function>
  <Function Name="InsertUpdateRole" Aggregate="false" BuiltIn="false" NiladicFunction="false" IsComposable="false" ParameterTypeSemantics="AllowImplicitConversion" Schema="dbo">
    <Parameter Name="Role_Id" Type="int" Mode="In" />
    <Parameter Name="Role_Name" Type="int" Mode="In" />
  </Function>
  <Function Name="InsertUpdateSiteUser" Aggregate="false" BuiltIn="false" NiladicFunction="false" IsComposable="false" ParameterTypeSemantics="AllowImplicitConversion" Schema="dbo">
    <Parameter Name="Site_User_Id" Type="int" Mode="In" />
    <Parameter Name="Role_Id" Type="int" Mode="In" />
    <Parameter Name="Location_Id" Type="int" Mode="In" />
    <Parameter Name="Name" Type="nvarchar" Mode="In" />
    <Parameter Name="Login_Name" Type="nvarchar" Mode="In" />
    <Parameter Name="Passsword" Type="nvarchar" Mode="In" />
    <Parameter Name="Email" Type="nvarchar" Mode="In" />
    <Parameter Name="Status" Type="bit" Mode="In" />
    <Parameter Name="Employee_Code" Type="nvarchar" Mode="In" />
  </Function>
  <Function Name="InsertUpdateTarget" Aggregate="false" BuiltIn="false" NiladicFunction="false" IsComposable="false" ParameterTypeSemantics="AllowImplicitConversion" Schema="dbo">
    <Parameter Name="Target_Id" Type="int" Mode="In" />
    <Parameter Name="Month" Type="int" Mode="In" />
    <Parameter Name="Year" Type="int" Mode="In" />
    <Parameter Name="Sales" Type="int" Mode="In" />
    <Parameter Name="Collection" Type="int" Mode="In" />
    <Parameter Name="Secondary_Sales" Type="int" Mode="In" />
    <Parameter Name="Site_User_Id" Type="int" Mode="In" />
  </Function>
  <Function Name="InsertUpdateUser" Aggregate="false" BuiltIn="false" NiladicFunction="false" IsComposable="false" ParameterTypeSemantics="AllowImplicitConversion" Schema="dbo">
    <Parameter Name="User_Id" Type="int" Mode="In" />
    <Parameter Name="Name" Type="nvarchar" Mode="In" />
    <Parameter Name="Password" Type="nvarchar" Mode="In" />
    <Parameter Name="Email" Type="nvarchar" Mode="In" />
    <Parameter Name="Role_Id" Type="int" Mode="In" />
    <Parameter Name="Location_Id" Type="int" Mode="In" />
    <Parameter Name="Employee_Code" Type="nvarchar" Mode="In" />
    <Parameter Name="Status" Type="bit" Mode="In" />
    <Parameter Name="LinkedUsers" Type="nvarchar" Mode="In" />
    <Parameter Name="Language_Id" Type="int" Mode="In" />
  </Function>
  <Function Name="InsertVisit" Aggregate="false" BuiltIn="false" NiladicFunction="false" IsComposable="false" ParameterTypeSemantics="AllowImplicitConversion" Schema="dbo">
    <Parameter Name="Customer_Id" Type="int" Mode="In" />
    <Parameter Name="Customer_Name" Type="nvarchar" Mode="In" />
    <Parameter Name="Customer_Name_BL" Type="nvarchar" Mode="In" />
    <Parameter Name="Location_Id" Type="int" Mode="In" />
    <Parameter Name="Contact_Id" Type="int" Mode="In" />
    <Parameter Name="Contact_Name" Type="nvarchar" Mode="In" />
    <Parameter Name="Contact_Name_BL" Type="nvarchar" Mode="In" />
    <Parameter Name="Department" Type="nvarchar" Mode="In" />
    <Parameter Name="Department_BL" Type="nvarchar" Mode="In" />
    <Parameter Name="Mobile" Type="nvarchar" Mode="In" />
    <Parameter Name="Site_User_Id" Type="int" Mode="In" />
    <Parameter Name="Date" Type="date" Mode="In" />
    <Parameter Name="Objective" Type="int" Mode="In" />
    <Parameter Name="Time_In" Type="time" Mode="In" />
    <Parameter Name="Time_Out" Type="time" Mode="In" />
    <Parameter Name="Time_w_Merchandiser" Type="int" Mode="In" />
    <Parameter Name="Collection" Type="int" Mode="In" />
    <Parameter Name="Secondary_Sales" Type="int" Mode="In" />
    <Parameter Name="Sales_LPO_Received" Type="int" Mode="In" />
    <Parameter Name="Discount" Type="int" Mode="In" />
    <Parameter Name="Sales_Return" Type="int" Mode="In" />
    <Parameter Name="Remarks" Type="nvarchar" Mode="In" />
    <Parameter Name="Updated_By" Type="int" Mode="In" />
  </Function>
  <Function Name="sp_alterdiagram" Aggregate="false" BuiltIn="false" NiladicFunction="false" IsComposable="false" ParameterTypeSemantics="AllowImplicitConversion" Schema="dbo">
    <Parameter Name="diagramname" Type="nvarchar" Mode="In" />
    <Parameter Name="owner_id" Type="int" Mode="In" />
    <Parameter Name="version" Type="int" Mode="In" />
    <Parameter Name="definition" Type="varbinary(max)" Mode="In" />
  </Function>
  <Function Name="sp_creatediagram" Aggregate="false" BuiltIn="false" NiladicFunction="false" IsComposable="false" ParameterTypeSemantics="AllowImplicitConversion" Schema="dbo">
    <Parameter Name="diagramname" Type="nvarchar" Mode="In" />
    <Parameter Name="owner_id" Type="int" Mode="In" />
    <Parameter Name="version" Type="int" Mode="In" />
    <Parameter Name="definition" Type="varbinary(max)" Mode="In" />
  </Function>
  <Function Name="sp_dropdiagram" Aggregate="false" BuiltIn="false" NiladicFunction="false" IsComposable="false" ParameterTypeSemantics="AllowImplicitConversion" Schema="dbo">
    <Parameter Name="diagramname" Type="nvarchar" Mode="In" />
    <Parameter Name="owner_id" Type="int" Mode="In" />
  </Function>
  <Function Name="sp_helpdiagramdefinition" Aggregate="false" BuiltIn="false" NiladicFunction="false" IsComposable="false" ParameterTypeSemantics="AllowImplicitConversion" Schema="dbo">
    <Parameter Name="diagramname" Type="nvarchar" Mode="In" />
    <Parameter Name="owner_id" Type="int" Mode="In" />
  </Function>
  <Function Name="sp_helpdiagrams" Aggregate="false" BuiltIn="false" NiladicFunction="false" IsComposable="false" ParameterTypeSemantics="AllowImplicitConversion" Schema="dbo">
    <Parameter Name="diagramname" Type="nvarchar" Mode="In" />
    <Parameter Name="owner_id" Type="int" Mode="In" />
  </Function>
  <Function Name="sp_renamediagram" Aggregate="false" BuiltIn="false" NiladicFunction="false" IsComposable="false" ParameterTypeSemantics="AllowImplicitConversion" Schema="dbo">
    <Parameter Name="diagramname" Type="nvarchar" Mode="In" />
    <Parameter Name="owner_id" Type="int" Mode="In" />
    <Parameter Name="new_diagramname" Type="nvarchar" Mode="In" />
  </Function>
  <Function Name="sp_upgraddiagrams" Aggregate="false" BuiltIn="false" NiladicFunction="false" IsComposable="false" ParameterTypeSemantics="AllowImplicitConversion" Schema="dbo" />
  <Function Name="UpdateLocation" Aggregate="false" BuiltIn="false" NiladicFunction="false" IsComposable="false" ParameterTypeSemantics="AllowImplicitConversion" Schema="dbo">
    <Parameter Name="Location_Id" Type="int" Mode="In" />
    <Parameter Name="Location_Name" Type="nvarchar" Mode="In" />
    <Parameter Name="Region_Id" Type="int" Mode="In" />
  </Function>
  <Function Name="UpdateRegion" Aggregate="false" BuiltIn="false" NiladicFunction="false" IsComposable="false" ParameterTypeSemantics="AllowImplicitConversion" Schema="dbo">
    <Parameter Name="Region_Id" Type="int" Mode="In" />
    <Parameter Name="Region_Name" Type="nvarchar" Mode="In" />
    <Parameter Name="Country_Id" Type="int" Mode="In" />
  </Function>
  <Function Name="UpdateVisit" Aggregate="false" BuiltIn="false" NiladicFunction="false" IsComposable="false" ParameterTypeSemantics="AllowImplicitConversion" Schema="dbo">
    <Parameter Name="DSR_Id" Type="int" Mode="In" />
    <Parameter Name="Customer_Id" Type="int" Mode="In" />
    <Parameter Name="Customer_Name" Type="nvarchar" Mode="In" />
    <Parameter Name="Customer_Name_BL" Type="nvarchar" Mode="In" />
    <Parameter Name="Location_Id" Type="int" Mode="In" />
    <Parameter Name="Contact_Id" Type="int" Mode="In" />
    <Parameter Name="Contact_Name" Type="nvarchar" Mode="In" />
    <Parameter Name="Contact_Name_BL" Type="nvarchar" Mode="In" />
    <Parameter Name="Department" Type="nvarchar" Mode="In" />
    <Parameter Name="Department_BL" Type="nvarchar" Mode="In" />
    <Parameter Name="Mobile" Type="nvarchar" Mode="In" />
    <Parameter Name="Site_User_Id" Type="int" Mode="In" />
    <Parameter Name="Date" Type="date" Mode="In" />
    <Parameter Name="Objective" Type="int" Mode="In" />
    <Parameter Name="Time_In" Type="time" Mode="In" />
    <Parameter Name="Time_Out" Type="time" Mode="In" />
    <Parameter Name="Time_w_Merchandiser" Type="int" Mode="In" />
    <Parameter Name="Collection" Type="int" Mode="In" />
    <Parameter Name="Secondary_Sales" Type="int" Mode="In" />
    <Parameter Name="Sales_LPO_Received" Type="int" Mode="In" />
    <Parameter Name="Discount" Type="int" Mode="In" />
    <Parameter Name="Sales_Return" Type="int" Mode="In" />
    <Parameter Name="Remarks" Type="nvarchar" Mode="In" />
    <Parameter Name="Updated_By" Type="int" Mode="In" />
  </Function>
</Schema>