on 2023 Nov 24 8:55 AM
Hi Community,
I'm working on scenario where i need to pick Delta changes only from PerAddressDEFLT entity for past records , I have created query but its not giving result based on date defined. If anyone know the cause or faced this issue earlier please help.
Below query is build in Cloud Integration in Success Factors adapter:
$select=homeAddressNavDEFLT/addressType,homeAddressNavDEFLT/startDate,homeAddressNavDEFLT/personIdExternal,homeAddressNavDEFLT/address1,homeAddressNavDEFLT/address2,homeAddressNavDEFLT/country,homeAddressNavDEFLT/city,homeAddressNavDEFLT/customString1,homeAddressNavDEFLT/lastModifiedDateTime,homeAddressNavDEFLT/zipCode,homeAddressNavDEFLT/stateNav/externalCode&$expand=homeAddressNavDEFLT,homeAddressNavDEFLT/stateNav&$filter=homeAddressNavDEFLT/lastModifiedDateTime ge datetimeoffset'2023-11-23T00:00:00.000' and personIdExternal eq '12345' &fromDate=1900-01-01&toDate=9999-12-31
The result should be record whose lastModifiedDateTime is greater than or equal to date 2023-11-23T00:00:00.000
Below is result :
<PerPerson>
<PerPerson>
<homeAddressNavDEFLT>
<PerAddressDEFLT>
<country>CAN</country>
<zipCode>X0E 0Y0</zipCode>
<stateNav>
<PicklistOption>
<externalCode>NT</externalCode>
</PicklistOption>
</stateNav>
<lastModifiedDateTime>2023-11-21T12:01:27.000</lastModifiedDateTime>
<customString1>105</customString1>
<address2>Test</address2>
<city>Behchoko</city>
<addressType>Mal</addressType>
<personIdExternal>12345</personIdExternal>
<address1>Box 370</address1>
<startDate>2023-11-21T00:00:00.000</startDate>
</PerAddressDEFLT>
<PerAddressDEFLT>
<country>CAN</country>
<zipCode>X0E 0Y0</zipCode>
<stateNav>
<PicklistOption>
<externalCode>NT</externalCode>
</PicklistOption>
</stateNav>
<lastModifiedDateTime>2023-11-21T12:01:27.000</lastModifiedDateTime>
<customString1>105</customString1>
<address2>Test</address2>
<city>Behchoko</city>
<addressType>Mal</addressType>
<personIdExternal>12345</personIdExternal>
<address1>Box 370</address1>
<startDate>2023-10-01T00:00:00.000</startDate>
</PerAddressDEFLT>
<PerAddressDEFLT>
<country>CAN</country>
<zipCode>L1V 7H9</zipCode>
<stateNav>
<PicklistOption>
<externalCode>ON</externalCode>
</PicklistOption>
</stateNav>
<lastModifiedDateTime>2023-11-22T07:40:56.000</lastModifiedDateTime>
<customString1>50</customString1>
<address2/>
<city>Pickering</city>
<addressType>home</addressType>
<personIdExternal>12345</personIdExternal>
<address1>1503 Hummingbird Court</address1>
<startDate>2022-10-01T00:00:00.000</startDate>
</PerAddressDEFLT>
<PerAddressDEFLT>
<country>CAN</country>
<zipCode>L1V 7H9</zipCode>
<stateNav>
<PicklistOption>
<externalCode>ON</externalCode>
</PicklistOption>
</stateNav>
<lastModifiedDateTime>2023-11-21T13:47:23.000</lastModifiedDateTime>
<customString1/>
<address2/>
<city>Pickering</city>
<addressType>home</addressType>
<personIdExternal>12345</personIdExternal>
<address1>Test_1503 Hummingbird Court</address1>
<startDate>2023-09-01T00:00:00.000</startDate>
</PerAddressDEFLT>
<PerAddressDEFLT>
<country>CAN</country>
<zipCode>L1V 7H9</zipCode>
<stateNav>
<PicklistOption>
<externalCode>ON</externalCode>
</PicklistOption>
</stateNav>
<lastModifiedDateTime>2023-11-22T10:11:25.000</lastModifiedDateTime>
<customString1/>
<address2>Test2</address2>
<city>Pickering</city>
<addressType>home</addressType>
<personIdExternal>12345</personIdExternal>
<address1>Lates_Test_1503 Hummingbird Court</address1>
<startDate>2023-10-01T00:00:00.000</startDate>
</PerAddressDEFLT>
<PerAddressDEFLT>
<country>CAN</country>
<zipCode>L1V 7H9</zipCode>
<stateNav>
<PicklistOption>
<externalCode>ON</externalCode>
</PicklistOption>
</stateNav>
<lastModifiedDateTime>2023-11-22T10:11:25.000</lastModifiedDateTime>
<customString1/>
<address2>Test1</address2>
<city>Pickering</city>
<addressType>home</addressType>
<personIdExternal>12345</personIdExternal>
<address1>Lates_Test_1503 Hummingbird Court</address1>
<startDate>2023-11-21T00:00:00.000</startDate>
</PerAddressDEFLT>
<PerAddressDEFLT>
<country>CAN</country>
<zipCode>L1V 7H9</zipCode>
<stateNav>
<PicklistOption>
<externalCode>ON</externalCode>
</PicklistOption>
</stateNav>
<lastModifiedDateTime>2023-11-23T13:13:56.000</lastModifiedDateTime>
<customString1/>
<address2>Eagle's Eye</address2>
<city>Pickering</city>
<addressType>home</addressType>
<personIdExternal>12345</personIdExternal>
<address1>Lates_Test_1503 Hummingbird Court</address1>
<startDate>2023-09-15T00:00:00.000</startDate>
</PerAddressDEFLT>
</homeAddressNavDEFLT>
</PerPerson>
</PerPerson>
Expected result:
<PerPerson>
<PerPerson>
<homeAddressNavDEFLT>
<PerAddressDEFLT>
<country>CAN</country>
<zipCode>L1V 7H9</zipCode>
<stateNav>
<PicklistOption>
<externalCode>ON</externalCode>
</PicklistOption>
</stateNav>
<lastModifiedDateTime>2023-11-23T13:13:56.000</lastModifiedDateTime>
<customString1/>
<address2>Eagle's Eye</address2>
<city>Pickering</city>
<addressType>home</addressType>
<personIdExternal>12345</personIdExternal>
<address1>Lates_Test_1503 Hummingbird Court</address1>
<startDate>2023-09-15T00:00:00.000</startDate>
</PerAddressDEFLT>
</homeAddressNavDEFLT>
</PerPerson>
</PerPerson>
Similar query is working for EmpJob entity , not sure if it supports for homeAddressNavDEFLT.
Thanks in advance.
Nikhil
Help others by sharing your knowledge.
AnswerRequest clarification before answering.
Hi ,
Able to achieve this by applying filter in Groovy with below condition , and passing this as property in adapter.
if(flag.equals("Delta"))
{
filter = "(lastModifiedDateTime ge '"+value+"' )"
}
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I'm either guessing it could be the format (I commonly format a date as follows for an odata call: employmentNav/startDate ge
datetime'1900-01-01T00:00:00Z') or it could be due to the amount of records in address info.
Address info (on each effective date) has a certain amount of entries, so if there are in fact as many entries on a specific effective date, the API may get the impression that it all belongs together.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
53 | |
8 | |
6 | |
6 | |
5 | |
5 | |
4 | |
4 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.