project QadFinancials > class BEmployee > business logic query EmployeeForDomain

Description

Will return all employees with the same code within the same domain as the selected company.


Parameters


iiCompanyIdintegerCompany id
icEmployeeCodecharacter
icSkipRowidcharacter
iiDomainIdinteger


query condition


  each Employee where
Employee.Company_Id = iiCompanyId AND
Employee.EmployeeCode = icEmployeeCode AND
rowid(Employee) <> to-rowid(icSkipRowid)

      first Company (inner-join) where
Company.Company_Id = iiCompanyId AND
Company.Company_ID = Employee.Company_ID AND
Company.Domain_ID = iiDomainId


query resultset tqEmployeeForDomain


field namedata typedb fielddescription
tiCompany_IDintegerEmployee.Company_IDLink to Company
tiDomain_IDintegerCompany.Domain_IDDomain
tiEmployee_IDintegerEmployee.Employee_IDRecord ID
tcEmployeeCodecharacterEmployee.EmployeeCodeEmployee Code. A code that identifies an employee. The code cannot match any other employee in the current entity or any other entities in the current domain.
If you leave the Employee Code field blank, the system automatically generates a number for the record based on the sequence defined in Employee Autonumber Create.


Internal usage


QadFinancials
method BAutoNumber.GetAutoNumber
method BCompany.ValidateComponent
method BEmployee.PreValidateComponent