<?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 Logic</title><link>https://community.appian.com/discussions/f/rules/12933/query-entity-logic</link><description>Hi, 
 
 I will be having two columns in my table minValue,Maxvalue.when i pass an input to the table it should return the lookup value in the attached screen shot. 
 Lets say if i pass a value 0.25, the value 0.25 is in between 0 and 0.5 in attached screen</description><dc:language>en-US</dc:language><generator>Telligent Community 12</generator><item><title>RE: Query Entity Logic</title><link>https://community.appian.com/thread/58181?ContentTypeID=1</link><pubDate>Fri, 20 Jul 2018 10:20:35 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:09e32a8d-4ad2-40fe-a8fc-34990ac263f6</guid><dc:creator>karthikk640</dc:creator><description>Thank you very much ashwini, This works :-)&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Query Entity Logic</title><link>https://community.appian.com/thread/58180?ContentTypeID=1</link><pubDate>Fri, 20 Jul 2018 10:15:57 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:8c0dbb15-7888-4b20-8217-841185166313</guid><dc:creator>ashwinia0001</dc:creator><description>Hi Karthik,&lt;br /&gt;
&lt;br /&gt;
Please find the below code&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
a!queryEntity(&lt;br /&gt;
entity:cons!ENTITY,&lt;br /&gt;
query:a!query(&lt;br /&gt;
logicalExpression:a!queryLogicalExpression(&lt;br /&gt;
operator:&amp;quot;AND&amp;quot;,&lt;br /&gt;
filters:{&lt;br /&gt;
a!queryFilter(&lt;br /&gt;
field:&amp;quot;minValue&amp;quot;,&lt;br /&gt;
operator:&amp;quot;&amp;lt;=&amp;quot;,&lt;br /&gt;
value:ri!num&lt;br /&gt;
),&lt;br /&gt;
&lt;br /&gt;
a!queryFilter(&lt;br /&gt;
field:&amp;quot;maxValue&amp;quot;,&lt;br /&gt;
operator:&amp;quot;&amp;gt;=&amp;quot;,&lt;br /&gt;
value:ri!num&lt;br /&gt;
)&lt;br /&gt;
&lt;br /&gt;
}),&lt;br /&gt;
&lt;br /&gt;
pagingInfo: a!pagingInfo(1,1)&lt;br /&gt;
)&lt;br /&gt;
).data&lt;br /&gt;
&lt;br /&gt;
this might met your requirement.&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Query Entity Logic</title><link>https://community.appian.com/thread/58134?ContentTypeID=1</link><pubDate>Thu, 19 Jul 2018 10:26:53 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:b7bcd672-951c-4f40-8bd6-e4fb7038aceb</guid><dc:creator>santoshd378</dc:creator><description>&lt;p&gt;Hi Karthik,&lt;/p&gt;
&lt;p&gt;Please find the below code,&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="text"&gt;a!queryEntity(
  entity: cons!ENTITY,
  query: a!query(
    selection: a!querySelection(
      columns: {
        a!queryColumn(
          field: &amp;quot;lookup_value&amp;quot;
        )
      }
    ),
    filter: a!queryFilter(
      field: &amp;quot;min_value&amp;quot;,
      operator: &amp;quot;between&amp;quot;,
      value: ri!Value
    ),
    pagingInfo: a!pagingInfo(
      startIndex: 1,
      batchSize: 1
    )
  )
)&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;Here the ri variable should be of type Number(Decimal), and it should be an array.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>