Fetch Data from General Data Source

This code fetches data from Product Extension with the name Cars where attribute2 is bigger than 100. For a big dataset use batchedMode. You can fetch data from multiple data sources (P, PX, C, CX, etc.).

<filter id="pxCarsFilter"> <and> <criterion fieldName="name" operator="equals" value="Cars"/> <criterion fieldName="attribute2" operator="greaterThan" value="100"/> </and> </filter> ..... <route> <from uri="timer://fetchData?repeatCount=1"/> <to uri="pfx-api:fetch?filter=pxCarsFilter&objectType=PX"/> </route>

 

The same example but with a SQL-like query:

<route> <from uri="timer://fetchDataByQuery?repeatCount=1"/> <to uri="pfx-api:fetch?sql=select sku,name,attribute2 where name='Cars' and attribute2>100 order by sku&objectType=PX"/> <log message="${body}"/> </route>

IntegrationManager version 5.8.0