on 09-18-2019 2:02 PM
Hi experts,
I am trying to query all the employees in the system to pass the data to some custom BO. My query is as follow:
var queryByEmployeeBID = Employee.QueryByIdentification;
var queryByEmployeeBIDParameter = queryByEmployeeBID.CreateSelectionParams();
queryByEmployeeBIDParameter.Add( queryByEmployeeBPD.IdentificationBusinessPartnerID, "I", "GE", "0");
var employeeQueryResult = queryByEmployeeBID.Execute(queryByEmployeeBIDParameter);<br>
is it the correct way? if not can someone give me a better idea?
Thanks,
Mousa
Hi,
If you want all employees, then you can execute the query without any selection.
var queryByEmployeeBID = Employee.QueryByIdentification;
var employeeQueryResult = queryByEmployeeBID.Execute()
Thanks,
Ajith.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You can even go shorter!
var allEmployees = Employee.QueryByIdentification.Execute();
User | Count |
---|---|
78 | |
10 | |
9 | |
7 | |
6 | |
6 | |
5 | |
5 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.