<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic WHERE Syntax Error - Query preparation failed. (Power BI Report Builder) in Report Server</title>
    <link>https://community.fabric.microsoft.com/t5/Report-Server/WHERE-Syntax-Error-Query-preparation-failed-Power-BI-Report/m-p/3061419#M28718</link>
    <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;In Report Builder this statement works fine using ORDER BY :&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;EVALUATE SUMMARIZECOLUMNS('ReferenceList'[Index],'ReferenceList'[Year], 'ReferenceList'[ClientType], 'ReferenceList'[Location], 'ReferenceList'[Project], 'ReferenceList'[Sector]) ORDER BY 'ReferenceList'[Location] ASC&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;BUT when i try to filter on Location = 'Europe ' using the WHERE statement it produces an syntax error&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;EVALUATE SUMMARIZECOLUMNS('ReferenceList'[Index],'ReferenceList'[Year], 'ReferenceList'[ClientType], 'ReferenceList'[Location], 'ReferenceList'[Project], 'ReferenceList'[Sector]) WHERE 'ReferenceList'[Location] = 'Europe'&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;TITLE: Power BI Report Builder&lt;BR /&gt;------------------------------&lt;/P&gt;&lt;P&gt;Query preparation failed.&lt;/P&gt;&lt;P&gt;------------------------------&lt;BR /&gt;ADDITIONAL INFORMATION:&lt;/P&gt;&lt;P&gt;Query (1, 180) The syntax for '&amp;lt;ccon&amp;gt;WHERE&amp;lt;/ccon&amp;gt;' is incorrect. (&amp;lt;ccon&amp;gt;EVALUATE SUMMARIZECOLUMNS('ReferenceList'[Index],'ReferenceList'[Year], 'ReferenceList'[ClientType], 'ReferenceList'[Location], 'ReferenceList'[Project], 'ReferenceList'[Sector]) WHERE 'ReferenceList'[Location] = 'Europe'&amp;lt;/ccon&amp;gt;). (Microsoft Analysis Services)&lt;/P&gt;&lt;P&gt;------------------------------&lt;BR /&gt;BUTTONS:&lt;/P&gt;&lt;P&gt;OK&lt;BR /&gt;------------------------------&lt;/P&gt;&lt;P&gt;Help is appreciated&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;</description>
    <pubDate>Sat, 04 Feb 2023 09:40:46 GMT</pubDate>
    <dc:creator>Swalker</dc:creator>
    <dc:date>2023-02-04T09:40:46Z</dc:date>
    <item>
      <title>WHERE Syntax Error - Query preparation failed. (Power BI Report Builder)</title>
      <link>https://community.fabric.microsoft.com/t5/Report-Server/WHERE-Syntax-Error-Query-preparation-failed-Power-BI-Report/m-p/3061419#M28718</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;In Report Builder this statement works fine using ORDER BY :&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;EVALUATE SUMMARIZECOLUMNS('ReferenceList'[Index],'ReferenceList'[Year], 'ReferenceList'[ClientType], 'ReferenceList'[Location], 'ReferenceList'[Project], 'ReferenceList'[Sector]) ORDER BY 'ReferenceList'[Location] ASC&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;BUT when i try to filter on Location = 'Europe ' using the WHERE statement it produces an syntax error&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;EVALUATE SUMMARIZECOLUMNS('ReferenceList'[Index],'ReferenceList'[Year], 'ReferenceList'[ClientType], 'ReferenceList'[Location], 'ReferenceList'[Project], 'ReferenceList'[Sector]) WHERE 'ReferenceList'[Location] = 'Europe'&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;TITLE: Power BI Report Builder&lt;BR /&gt;------------------------------&lt;/P&gt;&lt;P&gt;Query preparation failed.&lt;/P&gt;&lt;P&gt;------------------------------&lt;BR /&gt;ADDITIONAL INFORMATION:&lt;/P&gt;&lt;P&gt;Query (1, 180) The syntax for '&amp;lt;ccon&amp;gt;WHERE&amp;lt;/ccon&amp;gt;' is incorrect. (&amp;lt;ccon&amp;gt;EVALUATE SUMMARIZECOLUMNS('ReferenceList'[Index],'ReferenceList'[Year], 'ReferenceList'[ClientType], 'ReferenceList'[Location], 'ReferenceList'[Project], 'ReferenceList'[Sector]) WHERE 'ReferenceList'[Location] = 'Europe'&amp;lt;/ccon&amp;gt;). (Microsoft Analysis Services)&lt;/P&gt;&lt;P&gt;------------------------------&lt;BR /&gt;BUTTONS:&lt;/P&gt;&lt;P&gt;OK&lt;BR /&gt;------------------------------&lt;/P&gt;&lt;P&gt;Help is appreciated&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;</description>
      <pubDate>Sat, 04 Feb 2023 09:40:46 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/Report-Server/WHERE-Syntax-Error-Query-preparation-failed-Power-BI-Report/m-p/3061419#M28718</guid>
      <dc:creator>Swalker</dc:creator>
      <dc:date>2023-02-04T09:40:46Z</dc:date>
    </item>
    <item>
      <title>Re: WHERE Syntax Error - Query preparation failed. (Power BI Report Builder)</title>
      <link>https://community.fabric.microsoft.com/t5/Report-Server/WHERE-Syntax-Error-Query-preparation-failed-Power-BI-Report/m-p/3062442#M28724</link>
      <description>&lt;P&gt;ORDERBY is a valid DAX query keyword whereas WHERE is not (it's a SQL keyword).&lt;/P&gt;&lt;P&gt;use filter or calculatetable to apply filter according to your needs.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;A href="https://dax.guide/orderby/" target="_blank"&gt;ORDERBY - DAX Guide&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sun, 05 Feb 2023 19:27:25 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/Report-Server/WHERE-Syntax-Error-Query-preparation-failed-Power-BI-Report/m-p/3062442#M28724</guid>
      <dc:creator>R1k91</dc:creator>
      <dc:date>2023-02-05T19:27:25Z</dc:date>
    </item>
    <item>
      <title>Re: WHERE Syntax Error - Query preparation failed. (Power BI Report Builder)</title>
      <link>https://community.fabric.microsoft.com/t5/Report-Server/WHERE-Syntax-Error-Query-preparation-failed-Power-BI-Report/m-p/3063113#M28725</link>
      <description>&lt;P&gt;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="500205" data-lia-user-login="R1k91" class="lia-mention lia-mention-user"&gt;R1k91&lt;/a&gt;&amp;nbsp;is correct, there is no WHERE keyword in DAX&lt;BR /&gt;&lt;BR /&gt;But, you can also include filters in the SUMMARIZECOLUMNS see&amp;nbsp;&lt;A href="https://learn.microsoft.com/en-us/dax/summarizecolumns-function-dax" target="_blank"&gt;SUMMARIZECOLUMNS function (DAX) - DAX | Microsoft Learn&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;EVALUATE SUMMARIZECOLUMNS('ReferenceList'[Index],'ReferenceList'[Year], 'ReferenceList'[ClientType], 'ReferenceList'[Location], 'ReferenceList'[Project], 'ReferenceList'[Sector], 'ReferenceList'[Location] = "Europe") &lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 06 Feb 2023 07:00:12 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/Report-Server/WHERE-Syntax-Error-Query-preparation-failed-Power-BI-Report/m-p/3063113#M28725</guid>
      <dc:creator>d_gosbell</dc:creator>
      <dc:date>2023-02-06T07:00:12Z</dc:date>
    </item>
  </channel>
</rss>

