PERFORMANCE ISSUE WHILE CREATING ORDER
The performance between creating an Order via WF or via GUI should be the same and the where clauses should behave equally. Created a simple WF with single step to create Order.
When creating the order via the workflow, the actual time is spent after the order is created by executing the Named search ¿[COM Dynamic Pre-defined Search]: [Scenario Test Flag] = "N". While creating the order from UI, the Named search ¿[COM Dynamic Pre-defined Search]: [Scenario Test Flag] = "N" is triggered, but it doesn¿t query for all the records therefore you can see a reasonable time. When triggered form WF its querying for entire records where TEST_ORDER_FLG = 'N', hence taking time.