<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="https://community.appian.com/cfs-file/__key/system/syndication/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/"><channel><title>Query Entity</title><link>https://community.appian.com/discussions/f/general/8375/query-entity</link><description>How to implement NVL() in Appian? Can any one help me how to implement below query using queryEntity(). select * from REQUEST where XYZ is null and PQR is null and NVL(NEW_CD, OLD_CD) IN (1,2,3); Thanks! OriginalPostID-233682</description><dc:language>en-US</dc:language><generator>Telligent Community 12</generator><item><title>RE: Query Entity</title><link>https://community.appian.com/thread/36672?ContentTypeID=1</link><pubDate>Thu, 08 Sep 2016 22:55:33 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:64e196af-e23f-4aa0-bfba-ff6dced81aab</guid><dc:creator>Dan Lluhi</dc:creator><description>I think you can accomplish this by using logicalExpressions. You can use logicalExpressions to combine filters, so for example you could make a logicalExpression that checks if NEW_CD IN (1,2,3) OR (NEW_CD is null AND OLD_CD in (1,2,3)) .Check out this link: &lt;a href="https://forum.appian.com/suite/help/16.2/System_Functions.html#a!queryLogicalExpression.28.29"&gt;forum.appian.com/.../System_Functions.html&lt;/a&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Query Entity</title><link>https://community.appian.com/thread/36670?ContentTypeID=1</link><pubDate>Thu, 08 Sep 2016 22:46:14 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:b9ef65d2-4468-44c1-a740-af04246c8072</guid><dc:creator>anilkumark</dc:creator><description>Yes, view is the best option. But we don&amp;#39;t have time. Trying from Appian side to resolve this issue. How to get the records from REQUEST CDt variable where NEW_CD IN (1,2,3)?&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Query Entity</title><link>https://community.appian.com/thread/36669?ContentTypeID=1</link><pubDate>Thu, 08 Sep 2016 22:43:42 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:46c1908b-f9eb-4cb2-8c29-1ab26cb844d5</guid><dc:creator>Dan Lluhi</dc:creator><description>You could also create a database view for your REQUEST table, creating a new column for NVL(NEW_CD, OLD_CD). Then through your Appian queryEntity, have a filter to check where this new column is IN (1,2,3).&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Query Entity</title><link>https://community.appian.com/thread/36668?ContentTypeID=1</link><pubDate>Thu, 08 Sep 2016 22:38:37 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:27d053cf-0164-4d3a-a5d5-e0bc1b7b8f08</guid><dc:creator>Jacob Cohen - Project Leader - Macedon Technologies</dc:creator><description>In other words, you would need to do some processing on the Appian side in addition to the database side.&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Query Entity</title><link>https://community.appian.com/thread/36667?ContentTypeID=1</link><pubDate>Thu, 08 Sep 2016 22:38:13 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:8109c3d4-e194-4b04-911e-8b24102e4edb</guid><dc:creator>Jacob Cohen - Project Leader - Macedon Technologies</dc:creator><description>You would need to query for both columns. Then replace the null values of the one column with the results of the other.&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Query Entity</title><link>https://community.appian.com/thread/36666?ContentTypeID=1</link><pubDate>Thu, 08 Sep 2016 22:33:11 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:d9e3c799-4105-47ff-9064-51d9548d464e</guid><dc:creator>anilkumark</dc:creator><description>But here, I am not not fetching NEW_CD and OLD_CD. Based on the NVL condition I want to fetch the records. How APN_replaceNull helps?&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Query Entity</title><link>https://community.appian.com/thread/36663?ContentTypeID=1</link><pubDate>Thu, 08 Sep 2016 22:09:37 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:e3af5754-53f5-4aa5-8aed-d6de215e5daa</guid><dc:creator>Jacob Cohen - Project Leader - Macedon Technologies</dc:creator><description>You cannot do this directly with query entity, but you could apply over the result with a APN_replaceNull from Appian Common Objects.&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>